Github user imesh commented on a diff in the pull request:
https://github.com/apache/stratos/pull/35#discussion_r18500482
--- Diff:
components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/topology/AutoscalerTopologyEventReceiver.java
---
@@ -564,6 +577,51 @@ public void run() {
}
}
+ private class KubernetesClusterMonitorAdder implements Runnable {
+ private Cluster cluster;
+
+ public KubernetesClusterMonitorAdder(Cluster cluster) {
+ this.cluster = cluster;
+ }
+
+ public void run() {
+ KubernetesClusterMonitor monitor = null;
+ int retries = 5;
+ boolean success = false;
+ do {
+ try {
+ Thread.sleep(5000);
+ } catch (InterruptedException e1) {
+ }
+
+ try {
+ monitor =
AutoscalerUtil.getKubernetesClusterMonitor(cluster);
+ success = true;
+
+ } catch (Exception e) {
+ String msg = "Kubernetes cluster monitor creation
failed for cluster: " + cluster.getClusterId();
+ log.debug(msg, e);
--- End diff --
Debug log statements will not be seen by the end users in a production
environment. Shall we change the log level to error or warning?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---