cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t..@apache.org
Subject [37/50] [abbrv] git commit: updated refs/heads/marvin_refactor to 284581f
Date Tue, 16 Apr 2013 16:40:43 GMT
Removing the auto-wiring of AffinityGroupProcessors since this is an optional component


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/8d33353b
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/8d33353b
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/8d33353b

Branch: refs/heads/marvin_refactor
Commit: 8d33353b40f7599466a5175036c3021513cbdc81
Parents: f1b1480
Author: Prachi Damle <prachi@cloud.com>
Authored: Mon Apr 15 16:01:33 2013 -0700
Committer: Prachi Damle <prachi@cloud.com>
Committed: Mon Apr 15 16:02:05 2013 -0700

----------------------------------------------------------------------
 client/tomcatconf/applicationContext.xml.in        |    9 +++++-
 client/tomcatconf/componentContext.xml.in          |   16 ++++++++++---
 client/tomcatconf/nonossComponentContext.xml.in    |   16 ++++++++++---
 .../deploy/DeploymentPlanningManagerImpl.java      |   14 ++++++++++-
 .../src/com/cloud/server/ManagementServerImpl.java |   18 +++++++++++---
 5 files changed, 57 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8d33353b/client/tomcatconf/applicationContext.xml.in
----------------------------------------------------------------------
diff --git a/client/tomcatconf/applicationContext.xml.in b/client/tomcatconf/applicationContext.xml.in
index 15cd6fe..866e3ed 100644
--- a/client/tomcatconf/applicationContext.xml.in
+++ b/client/tomcatconf/applicationContext.xml.in
@@ -609,8 +609,10 @@
     <property name="UserAuthenticators" value="#{userAuthenticators.Adapters}" />
     <property name="UserPasswordEncoders" value="#{userPasswordEncoders.Adapters}" />
     <property name="HostAllocators" value="#{hostAllocators.Adapters}" />
+    <property name="Planners" value="#{deploymentPlanners.Adapters}" />
+	<property name="AffinityGroupProcessors" value="#{affinityProcessors.Adapters}" />
   </bean>
-
+  
   <bean id="storageManagerImpl" class="com.cloud.storage.StorageManagerImpl">
     <property name="StoragePoolAllocators" value="#{storagePoolAllocators.Adapters}" />
   </bean>
@@ -838,7 +840,10 @@
 -->
 
   <bean id="AffinityGroupServiceImpl" class="org.apache.cloudstack.affinity.AffinityGroupServiceImpl"/>
-  <bean id="DeploymentPlanningManager" class="com.cloud.deploy.DeploymentPlanningManagerImpl"
/>
+  <bean id="DeploymentPlanningManager" class="com.cloud.deploy.DeploymentPlanningManagerImpl">
+    <property name="Planners" value="#{deploymentPlanners.Adapters}" />
+	<property name="AffinityGroupProcessors" value="#{affinityProcessors.Adapters}" />
+  </bean>
   
   <bean id="AffinityGroupJoinDaoImpl" class="com.cloud.api.query.dao.AffinityGroupJoinDaoImpl">
   </bean>

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8d33353b/client/tomcatconf/componentContext.xml.in
----------------------------------------------------------------------
diff --git a/client/tomcatconf/componentContext.xml.in b/client/tomcatconf/componentContext.xml.in
index 23284ab..7a46981 100644
--- a/client/tomcatconf/componentContext.xml.in
+++ b/client/tomcatconf/componentContext.xml.in
@@ -253,9 +253,17 @@
   <!--
    AffinityGroup Processors
   -->
-    <bean id="HostAntiAffinityProcessor" class="org.apache.cloudstack.affinity.HostAntiAffinityProcessor">
-    	<property name="name" value="HostAntiAffinityProcessor"/>
-    	<property name="type" value="host anti-affinity"/>
- 	</bean>
+  <bean id="HostAntiAffinityProcessor" class="org.apache.cloudstack.affinity.HostAntiAffinityProcessor">
+   	<property name="name" value="HostAntiAffinityProcessor"/>
+   	<property name="type" value="host anti-affinity"/>
+  </bean>
+  
+  <bean id="affinityProcessors" class="com.cloud.utils.component.AdapterList">
+    <property name="Adapters">
+      <list>
+          <ref bean="HostAntiAffinityProcessor" />
+      </list>
+    </property>
+  </bean>
   
 </beans>

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8d33353b/client/tomcatconf/nonossComponentContext.xml.in
----------------------------------------------------------------------
diff --git a/client/tomcatconf/nonossComponentContext.xml.in b/client/tomcatconf/nonossComponentContext.xml.in
index a2182d1..2359ba8 100644
--- a/client/tomcatconf/nonossComponentContext.xml.in
+++ b/client/tomcatconf/nonossComponentContext.xml.in
@@ -355,9 +355,17 @@
   <!--
    AffinityGroup Processors
   -->
-    <bean id="HostAntiAffinityProcessor" class="org.apache.cloudstack.affinity.HostAntiAffinityProcessor">
-    	<property name="name" value="HostAntiAffinityProcessor"/>
-    	<property name="type" value="host anti-affinity"/>
- 	</bean>
+  <bean id="HostAntiAffinityProcessor" class="org.apache.cloudstack.affinity.HostAntiAffinityProcessor">
+   	<property name="name" value="HostAntiAffinityProcessor"/>
+   	<property name="type" value="host anti-affinity"/>
+  </bean>
+  
+  <bean id="affinityProcessors" class="com.cloud.utils.component.AdapterList">
+    <property name="Adapters">
+      <list>
+          <ref bean="HostAntiAffinityProcessor" />
+      </list>
+    </property>
+  </bean>
 
 </beans>

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8d33353b/server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java b/server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
index 92aac37..c7162a2 100644
--- a/server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
+++ b/server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
@@ -50,11 +50,21 @@ public class DeploymentPlanningManagerImpl extends ManagerBase implements
Deploy
     @Inject
     protected AffinityGroupVMMapDao _affinityGroupVMMapDao;
 
-    @Inject
     protected List<DeploymentPlanner> _planners;
+    public List<DeploymentPlanner> getPlanners() {
+        return _planners;
+    }
+    public void setPlanners(List<DeploymentPlanner> _planners) {
+        this._planners = _planners;
+    }
 
-    @Inject
     protected List<AffinityGroupProcessor> _affinityProcessors;
+    public List<AffinityGroupProcessor> getAffinityGroupProcessors() {
+        return _affinityProcessors;
+    }
+    public void setAffinityGroupProcessors(List<AffinityGroupProcessor> affinityProcessors)
{
+        this._affinityProcessors = affinityProcessors;
+    }
 
     @Override
     public DeployDestination planDeployment(VirtualMachineProfile<? extends VirtualMachine>
vmProfile,

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8d33353b/server/src/com/cloud/server/ManagementServerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/server/ManagementServerImpl.java b/server/src/com/cloud/server/ManagementServerImpl.java
index d9a4317..50b21ab 100755
--- a/server/src/com/cloud/server/ManagementServerImpl.java
+++ b/server/src/com/cloud/server/ManagementServerImpl.java
@@ -390,8 +390,13 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe
     private List<UserAuthenticator> _userAuthenticators;
     private List<UserAuthenticator> _userPasswordEncoders;
 
-    @Inject
     protected List<DeploymentPlanner> _planners;
+    public List<DeploymentPlanner> getPlanners() {
+        return _planners;
+    }
+    public void setPlanners(List<DeploymentPlanner> _planners) {
+        this._planners = _planners;
+    }
 
     @Inject ClusterManager _clusterMgr;
     private String _hashKey = null;
@@ -399,17 +404,22 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe
     @Inject
     protected AffinityGroupVMMapDao _affinityGroupVMMapDao;
 
-    @Inject
     protected List<AffinityGroupProcessor> _affinityProcessors;
+    public List<AffinityGroupProcessor> getAffinityGroupProcessors() {
+        return _affinityProcessors;
+    }
+    public void setAffinityGroupProcessors(List<AffinityGroupProcessor> affinityProcessors)
{
+        this._affinityProcessors = affinityProcessors;
+    }
 
     public ManagementServerImpl() {
     	setRunLevel(ComponentLifecycle.RUN_LEVEL_APPLICATION_MAINLOOP);
     }
-    
+
     public List<UserAuthenticator> getUserAuthenticators() {
     	return _userAuthenticators;
     }
-    
+
     public void setUserAuthenticators(List<UserAuthenticator> authenticators) {
     	_userAuthenticators = authenticators;
     }


Mime
View raw message