Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

关于在apollo服务端如何知晓客户端配置是否下发成功? #4978

Closed
zihan524 opened this issue Sep 22, 2023 · 4 comments
Closed
Labels

Comments

@zihan524
Copy link

目前在apollo服务端下发配置后,可能由于某些原因如网络等异常,导致配置虽然提交了,但客户端未成功更新,虽然客户端也会定期从apollo服务端拉取配置,但apollo服务端能否直观的看到与客户端应用配置是否一致?

@dosubot
Copy link

dosubot bot commented Sep 22, 2023

🤖

您好,关于您的问题,我在Apollo的仓库中找到了一些相关的信息。

  1. 对于Apollo服务端如何知晓客户端配置是否下发成功的问题,我没有在仓库中找到直接的答案。但是,Apollo客户端会维持与服务器的长连接,以便尽快接收到配置更新。作为备用机制,客户端还会定期从Apollo服务器拉取最新的配置。默认的拉取频率是每5分钟一次,但是可以通过在运行时指定系统属性apollo.refreshInterval(以分钟为单位)来覆盖这个设置。这意味着即使在网络异常的情况下,客户端也会尝试定期拉取配置更新。这一信息可以在这里找到。

  2. 对于Apollo服务端能否直观的看到与客户端应用配置是否一致的问题,我在仓库中找到了一个类似的已解决问题。在这个问题中,有人建议使用在线插件进行文本比较,以便一眼看出配置是否一致。这可能对您有所帮助。

希望这些信息对您有所帮助。如果您有更多的问题或需要进一步的澄清,请随时告诉我。

Sources


This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

If you want to continue the conversation, start your reply with @dosu-bot.

@nobodyiam
Copy link
Member

see the audit logic

private void auditReleases(String appId, String cluster, String dataCenter, String clientIp,
List<Release> releases) {
if (Strings.isNullOrEmpty(clientIp)) {
//no need to audit instance config when there is no ip
return;
}
for (Release release : releases) {
instanceConfigAuditUtil.audit(appId, cluster, dataCenter, clientIp, release.getAppId(),
release.getClusterName(),
release.getNamespaceName(), release.getReleaseKey());
}
}

@stale
Copy link

stale bot commented Oct 24, 2023

This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Oct 24, 2023
Copy link

stale bot commented Nov 1, 2023

This issue has been automatically closed because it has not had activity in the last 7 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions.

@stale stale bot closed this as completed Nov 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants