Commit 59553cc6 by Jason Song

adjust cat log

parent 14856db7
...@@ -131,6 +131,11 @@ public class RemoteConfigRepository extends AbstractConfigRepository { ...@@ -131,6 +131,11 @@ public class RemoteConfigRepository extends AbstractConfigRepository {
this.fireRepositoryChange(m_namespace, this.getConfig()); this.fireRepositoryChange(m_namespace, this.getConfig());
} }
if (current != null) {
Cat.logEvent(String.format("Apollo.Client.Configs.%s", current.getNamespaceName()),
current.getReleaseKey());
}
transaction.setStatus(Message.SUCCESS); transaction.setStatus(Message.SUCCESS);
} catch (Throwable ex) { } catch (Throwable ex) {
transaction.setStatus(ex); transaction.setStatus(ex);
...@@ -157,7 +162,7 @@ public class RemoteConfigRepository extends AbstractConfigRepository { ...@@ -157,7 +162,7 @@ public class RemoteConfigRepository extends AbstractConfigRepository {
String appId = m_configUtil.getAppId(); String appId = m_configUtil.getAppId();
String cluster = m_configUtil.getCluster(); String cluster = m_configUtil.getCluster();
String dataCenter = m_configUtil.getDataCenter(); String dataCenter = m_configUtil.getDataCenter();
Cat.logEvent("Apollo.Client.ConfigInfo", STRING_JOINER.join(appId, cluster, m_namespace)); Cat.logEvent("Apollo.Client.ConfigMeta", STRING_JOINER.join(appId, cluster, m_namespace));
int maxRetries = 2; int maxRetries = 2;
Throwable exception = null; Throwable exception = null;
...@@ -194,8 +199,6 @@ public class RemoteConfigRepository extends AbstractConfigRepository { ...@@ -194,8 +199,6 @@ public class RemoteConfigRepository extends AbstractConfigRepository {
ApolloConfig result = response.getBody(); ApolloConfig result = response.getBody();
Cat.logEvent("Apollo.Client.ConfigLoaded." + result.getNamespaceName(),
result.getReleaseKey());
logger.debug("Loaded config for {}: {}", m_namespace, result); logger.debug("Loaded config for {}: {}", m_namespace, result);
return result; return result;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment