stratos-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From im...@apache.org
Subject stratos git commit: Fixing changes reverted by pull request 148
Date Sat, 13 Dec 2014 12:58:31 GMT
Repository: stratos
Updated Branches:
  refs/heads/4.1.0-test 731743315 -> 81431df92


Fixing changes reverted by pull request 148


Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/81431df9
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/81431df9
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/81431df9

Branch: refs/heads/4.1.0-test
Commit: 81431df9238fbb32d0240e4b906e9411873a8946
Parents: 7317433
Author: Imesh Gunaratne <imesh@apache.org>
Authored: Sat Dec 13 18:28:18 2014 +0530
Committer: Imesh Gunaratne <imesh@apache.org>
Committed: Sat Dec 13 18:28:18 2014 +0530

----------------------------------------------------------------------
 .../monitor/component/ParentComponentMonitor.java | 18 ++++++------------
 1 file changed, 6 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/81431df9/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/component/ParentComponentMonitor.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/component/ParentComponentMonitor.java
b/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/component/ParentComponentMonitor.java
index dca89e9..bc9dcc6 100644
--- a/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/component/ParentComponentMonitor.java
+++ b/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/component/ParentComponentMonitor.java
@@ -40,21 +40,16 @@ import org.apache.stratos.autoscaler.exception.policy.PolicyValidationException;
 import org.apache.stratos.autoscaler.monitor.Monitor;
 import org.apache.stratos.autoscaler.monitor.MonitorFactory;
 import org.apache.stratos.autoscaler.monitor.cluster.AbstractClusterMonitor;
-import org.apache.stratos.autoscaler.monitor.cluster.VMClusterMonitor;
 import org.apache.stratos.autoscaler.util.ServiceReferenceHolder;
 import org.apache.stratos.common.threading.StratosThreadPool;
 import org.apache.stratos.messaging.domain.applications.GroupStatus;
 import org.apache.stratos.messaging.domain.applications.ParentComponent;
-import org.apache.stratos.messaging.domain.applications.ScalingDependentList;
 import org.apache.stratos.messaging.domain.instance.ClusterInstance;
 import org.apache.stratos.messaging.domain.instance.Instance;
 import org.apache.stratos.messaging.domain.topology.ClusterStatus;
 import org.apache.stratos.messaging.message.receiver.topology.TopologyManager;
 
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ExecutorService;
 
@@ -64,8 +59,8 @@ import java.util.concurrent.ExecutorService;
  */
 public abstract class ParentComponentMonitor extends Monitor {
 	private static final Log log = LogFactory.getLog(ParentComponentMonitor.class);
-	public static final String IDENTIFIER = "Auto-Scaler";
-	public static final int THREAD_POOL_SIZE = 10;
+    private static final String IDENTIFIER = "Auto-Scaler";
+    private static final int THREAD_POOL_SIZE = 10;
 
 	//The monitors dependency tree with all the start-able/kill-able dependencies
     protected DependencyTree startupDependencyTree;
@@ -92,8 +87,8 @@ public abstract class ParentComponentMonitor extends Monitor {
         //Building the startup dependencies for this monitor within the immediate children
         startupDependencyTree = DependencyBuilder.getInstance().buildDependency(component);
         //Building the scaling dependencies for this monitor within the immediate children
-        scalingDependencyTree = DependencyBuilder.getInstance().buildDependency(component);
-		//Create the executor service with identifier and thread pool size
+        scalingDependencies  =  DependencyBuilder.getInstance().buildScalingDependencies(component);
+        //Create the executor service with identifier and thread pool size
 	    executorService= StratosThreadPool.getExecutorService(IDENTIFIER, THREAD_POOL_SIZE);
     }
 
@@ -707,6 +702,5 @@ private class MonitorAdder implements Runnable {
 
 	public Set<String> getScalingDependencies() {
 		return scalingDependencies;
-	}    
-
+	}
 }


Mime
View raw message