stratos-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From im...@apache.org
Subject [50/50] [abbrv] git commit: Merge branch '4.0.0-grouping' into docker-grouping-merge
Date Thu, 30 Oct 2014 04:14:14 GMT
Merge branch '4.0.0-grouping' into docker-grouping-merge

Conflicts:
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/AutoscalerContext.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/PartitionContext.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/health/AutoscalerHealthStatEventReceiver.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/topology/AutoscalerTopologyEventReceiver.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/monitor/AbstractClusterMonitor.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/rule/AutoscalerRuleEvaluator.java
	components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/util/AutoscalerUtil.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/AutoscalePolicyCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/AutoscalingPolicyDeploymentCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/CartridgeDeploymentCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DeployServiceDeploymentCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DeploymentPolicyCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DeploymentPolicyDeploymentCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ListSubscribedCartridgesCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/PartitionCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/PartitionDeploymentCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/PoliciesCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/RemoveDomainMappingCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/SubscribeCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/SubscribedCartridgeInfoCommand.java
	components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/utils/CommandLineUtils.java
	components/org.apache.stratos.cloud.controller/pom.xml
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/AWSEC2Iaas.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/OpenstackNovaIaas.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/impl/CloudControllerServiceImpl.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/interfaces/CloudControllerService.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/internal/CloudControllerDSComponent.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/pojo/Cartridge.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/pojo/CartridgeConfig.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/topology/TopologyBuilder.java
	components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/topology/TopologyEventPublisher.java
	components/org.apache.stratos.manager.console/console/util/utility.jag
	components/org.apache.stratos.manager/src/main/java/org/apache/stratos/manager/manager/CartridgeSubscriptionManager.java
	components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/domain/topology/Cluster.java
	components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/domain/topology/Member.java
	components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/message/processor/topology/InstanceSpawnedMessageProcessor.java
	components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/util/Constants.java
	components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/util/Util.java
	components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/bean/util/converter/PojoConverter.java
	components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/services/ServiceUtils.java
	components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/services/StratosAdmin.java
	components/org.apache.stratos.rest.endpoint/src/main/webapp/stratos/WEB-INF/cxf-servlet.xml
	dependencies/pom.xml
	extensions/cep/stratos-cep-extension/src/main/java/org/apache/stratos/cep/extension/CEPTopologyEventReceiver.java
	extensions/cep/stratos-cep-extension/src/main/java/org/apache/stratos/cep/extension/FaultHandlingWindowProcessor.java
	features/cloud-controller/org.apache.stratos.cloud.controller.feature/pom.xml
	pom.xml
	products/stratos/modules/distribution/src/assembly/bin.xml
	products/stratos/modules/distribution/src/main/conf/mincheck.drl
	service-stubs/org.apache.stratos.cloud.controller.service.stub/pom.xml
	service-stubs/org.apache.stratos.cloud.controller.service.stub/src/main/resources/CloudControllerService.wsdl
	tools/puppet3/modules/mysql/manifests/init.pp


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

Branch: refs/heads/docker-grouping-merge
Commit: 17cc86ebdbc4c6e405576a98a0bb30f0f28f9fbc
Parents: dd9cc95 5e69c7f
Author: Imesh Gunaratne <imesh@apache.org>
Authored: Thu Oct 30 09:42:56 2014 +0530
Committer: Imesh Gunaratne <imesh@apache.org>
Committed: Thu Oct 30 09:42:56 2014 +0530

----------------------------------------------------------------------
 .../apache/stratos/autoscaler/Constants.java    |   9 +
 .../stratos/autoscaler/PartitionContext.java    |  45 +
 .../exception/DependencyBuilderException.java   |  48 +
 .../TopologyInConsistentException.java          |  47 +
 .../grouping/dependency/DependencyBuilder.java  | 158 ++++
 .../grouping/dependency/DependencyTree.java     | 291 ++++++
 .../dependency/context/ApplicationContext.java  | 113 +++
 .../context/ApplicationContextFactory.java      | 102 +++
 .../dependency/context/ClusterContext.java      |  38 +
 .../dependency/context/GroupContext.java        |  25 +
 .../topic/InstanceNotificationPublisher.java    |  53 ++
 .../grouping/topic/StatusEventPublisher.java    | 312 +++++++
 .../AutoscalerHealthStatEventReceiver.java      |  12 +-
 .../monitor/ApplicationMonitorFactory.java      | 344 +++++++
 .../autoscaler/monitor/EventHandler.java        |  56 ++
 .../stratos/autoscaler/monitor/Monitor.java     | 108 +++
 .../monitor/MonitorStatusEventBuilder.java      |  61 ++
 .../monitor/ParentComponentMonitor.java         | 407 +++++++++
 .../monitor/application/ApplicationMonitor.java | 196 ++++
 .../monitor/cluster/ClusterMonitor.java         | 293 ++++++
 .../monitor/cluster/LbClusterMonitor.java       | 129 +++
 .../monitor/events/ApplicationStatusEvent.java  |  42 +
 .../monitor/events/ClusterStatusEvent.java      |  42 +
 .../monitor/events/GroupStatusEvent.java        |  41 +
 .../monitor/events/GroupTerminateAllEvent.java  |  29 +
 .../autoscaler/monitor/events/MonitorEvent.java |  28 +
 .../monitor/events/MonitorScalingEvent.java     |  30 +
 .../monitor/events/MonitorStartAllEvent.java    |  28 +
 .../monitor/events/MonitorStatusEvent.java      |  41 +
 .../events/MonitorTerminateAllEvent.java        |  29 +
 .../autoscaler/monitor/group/GroupMonitor.java  | 167 ++++
 .../rule/AutoscalerRuleEvaluator.java           |  22 +
 .../autoscaler/rule/RuleTasksDelegator.java     |  27 +-
 .../status/checker/StatusChecker.java           | 428 +++++++++
 .../termination-change.patch                    | 596 +++++++++++++
 .../stratos/cartridge/agent/CartridgeAgent.java |  11 +
 .../git/impl/GitBasedArtifactRepository.java    |  47 -
 .../publisher/CartridgeStatistics.java          |  66 ++
 .../publisher/HealthStatisticsNotifier.java     | 119 ++-
 .../publisher/HealthStatisticsReader.java       |  31 +-
 .../publisher/IHealthStatisticsReader.java      |  55 ++
 .../statistics/publisher/PluginLoader.java      |  88 ++
 .../java/org/apache/stratos/cli/Command.java    |   5 +-
 .../stratos/cli/RestCommandLineService.java     |   1 +
 .../apache/stratos/cli/StratosApplication.java  |   8 +-
 .../cli/commands/ActivateTenantCommand.java     |   3 +-
 .../cli/commands/AddDomainMappingCommand.java   |   3 +-
 .../stratos/cli/commands/AddTenantCommand.java  |  30 +-
 .../cli/commands/DeactivateTenantCommand.java   |   3 +-
 .../cli/commands/DeleteTenantCommand.java       |   3 +-
 .../DescribeAutoScalingPolicyCommand.java       |   2 +-
 .../cli/commands/DescribeCartridgeCommand.java  |   2 +-
 .../DescribeDeploymentPolicyCommand.java        |   2 +-
 .../cli/commands/DescribePartitionCommand.java  |   3 +-
 .../stratos/cli/commands/ExitCommand.java       |   3 +-
 .../stratos/cli/commands/HelpCommand.java       |   3 +-
 .../stratos/cli/commands/InfoCommand.java       |   3 +-
 .../stratos/cli/commands/ListAllTenants.java    |   3 +-
 .../cli/commands/ListCartridgesCommand.java     |   3 +-
 .../cli/commands/ListDeployServiceCommand.java  |   3 +-
 .../stratos/cli/commands/ListMemberCommand.java |  14 +-
 .../stratos/cli/commands/SyncCommand.java       |   3 +-
 .../UndeployCartridgeDefinitionCommand.java     |   3 +-
 .../UndeployServiceDefinitionCommand.java       |   3 +-
 .../cli/commands/UnsubscribeCommand.java        |   9 +-
 .../src/main/resources/log4j.properties         |   2 +-
 .../org.apache.stratos.cloud.controller/pom.xml |   2 +
 .../application/ApplicationUtils.java           | 291 ++++++
 .../application/ClusterInformation.java         |  27 +
 .../application/MTClusterInformation.java       |  45 +
 .../application/STClusterInformation.java       |  55 ++
 .../parser/DefaultApplicationParser.java        | 610 +++++++++++++
 .../application/parser/ParserUtils.java         | 142 +++
 .../ApplicationCartridgePayloadData.java        |  27 +
 .../application/payload/BasicPayloadData.java   | 311 +++++++
 .../payload/DataCartridgePayloadData.java       |  27 +
 .../payload/FrameworkCartridgePayloadData.java  |  27 +
 .../LoadBalancerCartridgePayloadData.java       |  27 +
 .../application/payload/PayloadData.java        |  69 ++
 .../application/payload/PayloadFactory.java     |  59 ++
 .../ApplicationStatusTopicReceiver.java         | 175 ++++
 .../ApplicationDefinitionException.java         |  47 +
 ...CompositeApplicationDefinitionException.java |  44 +
 .../exception/InvalidServiceGroupException.java |  46 +
 .../cloud/controller/iaases/AWSEC2Iaas.java     |   4 +
 .../controller/iaases/OpenstackNovaIaas.java    |   3 +
 .../impl/CloudControllerServiceImpl.java        | 252 ++++--
 .../interfaces/ApplicationParser.java           |  53 ++
 .../interfaces/CloudControllerService.java      |  34 +-
 .../internal/CloudControllerDSComponent.java    | 180 ++--
 .../pojo/ApplicationClusterContext.java         | 137 +++
 .../cloud/controller/pojo/Cartridge.java        |  16 +-
 .../cloud/controller/pojo/CartridgeConfig.java  |  10 +
 .../pojo/CompositeApplicationDefinition.java    |  38 +
 .../cloud/controller/pojo/ConfigCartridge.java  |  17 +
 .../controller/pojo/ConfigDependencies.java     |  29 +
 .../controller/pojo/ConfigDependencyPair.java   |  29 +
 .../cloud/controller/pojo/ConfigGroup.java      |  35 +
 .../cloud/controller/pojo/Dependencies.java     |  48 +
 .../cloud/controller/pojo/ServiceGroup.java     |  69 ++
 .../pojo/application/ApplicationContext.java    |  93 ++
 .../pojo/application/ComponentContext.java      |  54 ++
 .../pojo/application/DependencyContext.java     |  44 +
 .../pojo/application/GroupContext.java          |  84 ++
 .../pojo/application/SubscribableContext.java   |  44 +
 .../application/SubscribableInfoContext.java    | 103 +++
 .../controller/pojo/payload/MetaDataHolder.java |  99 ++
 .../runtime/FasterLookUpDataHolder.java         |  37 +-
 .../InstanceStatusEventMessageDelegator.java    |  17 +-
 .../controller/topology/TopologyBuilder.java    | 892 ++++++++++++++++---
 .../topology/TopologyEventPublisher.java        | 270 ++++--
 .../controller/util/CloudControllerUtil.java    |   4 +
 .../CompositeApplicationParseTest.java          | 554 ++++++++++++
 .../LoadBalancerTopologyEventReceiver.java      |  77 +-
 .../conf/LoadBalancerConfiguration.java         |   9 +-
 .../console/util/utility.jag                    |  21 +
 .../client/CloudControllerServiceClient.java    |  49 +-
 .../composite/application/TemporyClass.java     |   7 -
 .../beans/ApplicationDefinition.java            |  67 ++
 .../application/beans/ComponentDefinition.java  |  41 +
 .../application/beans/GroupDefinition.java      |  87 ++
 .../beans/SubscribableDefinition.java           |  48 +
 .../application/beans/SubscribableInfo.java     | 106 +++
 .../parser/CompositeApplicationParser.java      |  30 +
 .../DefaultCompositeApplicationParser.java      | 431 +++++++++
 .../application/parser/ParserUtils.java         |  60 ++
 .../structure/CompositeAppContext.java          | 107 +++
 .../application/structure/GroupContext.java     | 123 +++
 .../application/structure/StartupOrder.java     |  66 ++
 .../structure/SubscribableContext.java          | 126 +++
 .../application/utils/ApplicationUtils.java     |  28 +
 .../ApplicationSubscriptionException.java       |  51 ++
 ...CompositeApplicationDefinitionException.java |  47 +
 .../CompositeApplicationException.java          |  47 +
 .../DomainSubscriptionDoesNotExist.java         |  39 +-
 .../exception/GroupSubscriptionException.java   |  47 +
 .../exception/InvalidServiceGroupException.java |  47 +
 .../ServiceGroupDefinitioException.java         |  47 +
 .../definitions/DependencyDefinitions.java      |  53 ++
 .../definitions/ServiceGroupDefinition.java     |  68 ++
 .../definitions/StartupOrderDefinition.java     |  47 +
 .../deployer/DefaultServiceGroupDeployer.java   | 326 +++++++
 .../grouping/deployer/ServiceGroupDeployer.java |  36 +
 .../manager/ServiceGroupingManager.java         |  57 ++
 .../internal/ADCManagementServerComponent.java  |  12 +
 .../manager/CartridgeSubscriptionManager.java   | 237 ++++-
 .../manager/persistence/PersistenceManager.java |  26 +
 .../RegistryBasedPersistenceManager.java        | 396 +++++++-
 .../DataInsertionAndRetrievalManager.java       |  49 +
 .../subscription/ApplicationSubscription.java   |  78 ++
 .../manager/subscription/GroupSubscription.java |  73 ++
 .../utils/CartridgeSubscriptionUtils.java       |   1 +
 .../StratosManagerTopologyEventReceiver.java    | 219 ++++-
 .../stratos/manager/utils/Serializer.java       |  53 +-
 components/org.apache.stratos.messaging/pom.xml |  20 +-
 .../messaging/domain/topology/Application.java  | 123 +++
 .../domain/topology/ApplicationStatus.java      |  74 ++
 .../messaging/domain/topology/Cartridge.java    |  89 ++
 .../messaging/domain/topology/Cluster.java      | 102 ++-
 .../domain/topology/ClusterDataHolder.java      |  51 ++
 .../domain/topology/ClusterStatus.java          |  54 +-
 .../messaging/domain/topology/Composite.java    |  15 +
 .../domain/topology/CompositeApplication.java   | 298 +++++++
 .../domain/topology/ConfigCartridge.java        |  20 +
 .../topology/ConfigCompositeApplication.java    |  42 +
 .../domain/topology/ConfigDependencies.java     |  57 ++
 .../messaging/domain/topology/ConfigGroup.java  |  33 +
 .../messaging/domain/topology/Dependencies.java | 334 +++++++
 .../domain/topology/DependencyOrder.java        |  54 ++
 .../messaging/domain/topology/Group.java        | 111 +++
 .../messaging/domain/topology/GroupStatus.java  |  73 ++
 .../messaging/domain/topology/GroupTemp.java    | 503 +++++++++++
 .../LifeCycleStateTransitionBehavior.java       |  35 +
 .../messaging/domain/topology/Member.java       |  28 +-
 .../messaging/domain/topology/MemberStatus.java |  62 +-
 .../domain/topology/ParentComponent.java        | 212 +++++
 .../messaging/domain/topology/Scalable.java     |   5 +
 .../messaging/domain/topology/Service.java      |   9 +-
 .../messaging/domain/topology/StartupOrder.java |  40 +
 .../messaging/domain/topology/Subscribable.java |  25 +
 .../messaging/domain/topology/Topology.java     | 125 ++-
 .../topology/lifecycle/LifeCycleState.java      |  28 +
 .../lifecycle/LifeCycleStateManager.java        | 138 +++
 .../domain/topology/locking/TopologyLock.java   |  63 ++
 .../topology/locking/TopologyLockHierarchy.java | 176 ++++
 .../AppStatusApplicationActivatedEvent.java     |  38 +
 .../AppStatusApplicationCreatedEvent.java       |  38 +
 .../AppStatusApplicationInactivatedEvent.java   |  38 +
 .../AppStatusApplicationTerminatedEvent.java    |  47 +
 .../AppStatusApplicationTerminatingEvent.java   |  38 +
 .../status/AppStatusClusterActivatedEvent.java  |  50 ++
 .../status/AppStatusClusterInactivateEvent.java |  50 ++
 .../AppStatusClusterMaintenanceModeEvent.java   |  49 +
 .../AppStatusClusterReadyToShutdownEvent.java   |  47 +
 .../status/AppStatusClusterTerminatedEvent.java |  50 ++
 .../AppStatusClusterTerminatingEvent.java       |  50 ++
 .../status/AppStatusGroupActivatedEvent.java    |  44 +
 .../status/AppStatusGroupInactivateEvent.java   |  44 +
 .../AppStatusGroupMaintenanceModeEvent.java     |  41 +
 .../AppStatusGroupReadyToShutdownEvent.java     |  40 +
 .../status/AppStatusGroupTerminatedEvent.java   |  44 +
 .../status/AppStatusGroupTerminatingEvent.java  |  44 +
 .../event/application/status/StatusEvent.java   |  31 +
 .../instance/status/InstanceActivatedEvent.java |   9 +
 .../status/InstanceMaintenanceModeEvent.java    |   9 +
 .../status/InstanceReadyToShutdownEvent.java    |   9 +
 .../instance/status/InstanceStartedEvent.java   |   9 +
 .../topology/ApplicationActivatedEvent.java     |  34 +
 .../event/topology/ApplicationCreatedEvent.java |  54 ++
 .../topology/ApplicationInactivatedEvent.java   |  34 +
 .../topology/ApplicationTerminatedEvent.java    |  57 ++
 .../topology/ApplicationTerminatingEvent.java   |  35 +
 .../topology/ApplicationUndeployedEvent.java    |  43 +
 .../event/topology/ClusterActivatedEvent.java   |  57 ++
 .../event/topology/ClusterCreatedEvent.java     |  22 +-
 .../event/topology/ClusterInactivateEvent.java  |  56 ++
 .../topology/ClusterMaintenanceModeEvent.java   |  58 --
 .../event/topology/ClusterTerminatedEvent.java  |  56 ++
 .../event/topology/ClusterTerminatingEvent.java |  56 ++
 .../CompositeApplicationCreatedEvent.java       |  51 ++
 .../topology/CompositeApplicationEvent.java     |  31 +
 .../CompositeApplicationRemovedEvent.java       |  49 +
 .../event/topology/GroupActivatedEvent.java     |  43 +
 .../event/topology/GroupInactivateEvent.java    |  43 +
 .../event/topology/GroupTerminatedEvent.java    |  43 +
 .../event/topology/GroupTerminatingEvent.java   |  43 +
 .../event/topology/MemberActivatedEvent.java    |  42 +-
 .../topology/MemberMaintenanceModeEvent.java    |   9 +
 .../topology/MemberReadyToShutdownEvent.java    |   9 +
 .../event/topology/MemberStartedEvent.java      |   9 +
 .../event/topology/MemberSuspendedEvent.java    |   9 +
 .../event/topology/MemberTerminatedEvent.java   |   8 +
 ...StatusApplicationActivatedEventListener.java |  27 +
 ...ppStatusApplicationCreatedEventListener.java |  27 +
 ...atusApplicationInactivatedEventListener.java |  27 +
 ...tatusApplicationTerminatedEventListener.java |  27 +
 ...atusApplicationTerminatingEventListener.java |  27 +
 .../AppStatusClusterActivatedEventListener.java |  24 +
 ...AppStatusClusterInactivateEventListener.java |  24 +
 ...AppStatusClusterTerminatedEventListener.java |  24 +
 ...ppStatusClusterTerminatingEventListener.java |  24 +
 .../AppStatusGroupActivatedEventListener.java   |  24 +
 .../AppStatusGroupInactivateEventListener.java  |  24 +
 .../AppStatusGroupTerminatedEventListener.java  |  24 +
 .../AppStatusGroupTerminatingEventListener.java |  24 +
 .../ApplicationActivatedEventListener.java      |  27 +
 .../ApplicationCreatedEventListener.java        |  26 +
 .../ApplicationInActivateEventListener.java     |  27 +
 .../ApplicationTerminatedEventListener.java     |  27 +
 .../ApplicationTerminatingEventListener.java    |  27 +
 .../ApplicationUndeployedEventListener.java     |  26 +
 .../topology/ClusterActivatedEventListener.java |  24 +
 .../ClusterInActivateEventListener.java         |  24 +
 .../ClusterMaintenanceModeEventListener.java    |  25 -
 .../ClusterTerminatedEventListener.java         |  24 +
 .../ClusterTerminatingEventListener.java        |  24 +
 .../topology/GroupActivatedEventListener.java   |  27 +
 .../topology/GroupInActivateEventListener.java  |  27 +
 .../topology/GroupTerminatedEventListener.java  |  27 +
 .../topology/GroupTerminatingEventListener.java |  27 +
 ...tusApplicationActivatedMessageProcessor.java |  62 ++
 ...tatusApplicationCreatedMessageProcessor.java |  63 ++
 ...sApplicationInactivatedMessageProcessor.java |  63 ++
 ...usApplicationTerminatedMessageProcessor.java |  63 ++
 ...sApplicationTerminatingMessageProcessor.java |  63 ++
 ...pStatusClusterActivatedMessageProcessor.java |  57 ++
 ...StatusClusterInactivateMessageProcessor.java |  58 ++
 ...StatusClusterTerminatedMessageProcessor.java |  58 ++
 ...tatusClusterTerminatingMessageProcessor.java |  58 ++
 ...AppStatusGroupActivatedMessageProcessor.java |  61 ++
 ...pStatusGroupInactivatedMessageProcessor.java |  61 ++
 ...ppStatusGroupTerminatedMessageProcessor.java |  61 ++
 ...pStatusGroupTerminatingMessageProcessor.java |  61 ++
 .../status/AppStatusMessageProcessorChain.java  | 126 +++
 .../ApplicationActivatedMessageProcessor.java   | 104 +++
 .../ApplicationCreatedMessageProcessor.java     | 121 +++
 .../ApplicationInactivatedMessageProcessor.java | 104 +++
 .../ApplicationTerminatedMessageProcessor.java  | 136 +++
 .../ApplicationTerminatingMessageProcessor.java | 104 +++
 .../ApplicationUndeployedMessageProcessor.java  | 136 +++
 .../topology/ClusterActivatedProcessor.java     | 133 +++
 .../ClusterCreatedMessageProcessor.java         | 130 +--
 .../topology/ClusterInActivateProcessor.java    | 131 +++
 .../ClusterMaintenanceModeMessageProcessor.java | 115 ---
 .../ClusterRemovedMessageProcessor.java         | 105 ++-
 .../topology/ClusterTerminatedProcessor.java    | 133 +++
 .../topology/ClusterTerminatingProcessor.java   | 133 +++
 .../CompleteTopologyMessageProcessor.java       | 210 +++--
 .../topology/GroupActivatedProcessor.java       | 104 +++
 .../topology/GroupInActivateProcessor.java      | 107 +++
 .../topology/GroupTerminatedProcessor.java      | 107 +++
 .../topology/GroupTerminatingProcessor.java     | 107 +++
 .../InstanceSpawnedMessageProcessor.java        | 151 ++--
 .../MemberActivatedMessageProcessor.java        | 184 ++--
 .../MemberMaintenanceModeProcessor.java         | 162 ++--
 .../MemberReadyToShutdownMessageProcessor.java  | 163 ++--
 .../topology/MemberStartedMessageProcessor.java | 160 ++--
 .../MemberSuspendedMessageProcessor.java        | 158 ++--
 .../MemberTerminatedMessageProcessor.java       | 139 +--
 .../ServiceCreatedMessageProcessor.java         |  74 +-
 .../ServiceRemovedMessageProcessor.java         |  71 +-
 .../topology/TopologyMessageProcessorChain.java |  98 +-
 .../topology/updater/TopologyUpdater.java       | 272 ++++++
 .../ApplicationStatusEventMessageDelegator.java | 146 +++
 .../ApplicationStatusEventMessageListener.java  |  54 ++
 .../ApplicationStatusEventMessageQueue.java     |  26 +
 .../status/ApplicationStatusEventReceiver.java  |  83 ++
 .../topology/TopologyEventMessageDelegator.java |  10 +-
 .../receiver/topology/TopologyManager.java      | 234 ++++-
 .../stratos/messaging/util/Constants.java       |  14 +-
 .../org/apache/stratos/messaging/util/Util.java |  66 +-
 .../topology/locking/TopologyLockingTest.java   | 208 +++++
 .../org.apache.stratos.metadata.client/pom.xml  |  67 ++
 .../metadata/client/beans/PropertyBean.java     |  65 ++
 .../client/config/MetaDataClientConfig.java     | 125 +++
 .../defaults/DefaultMetaDataServiceClient.java  | 131 +++
 .../client/defaults/MetaDataServiceClient.java  |  69 ++
 .../MetaDataServiceClientException.java         |  48 +
 .../client/exception/RestClientException.java   |  48 +
 .../metadata/client/rest/DefaultRestClient.java | 171 ++++
 .../client/rest/HTTPConnectionManager.java      |  50 ++
 .../metadata/client/rest/RestClient.java        |  53 ++
 .../client/util/MetaDataClientConstants.java    |  32 +
 .../org.apache.stratos.metadataservice/pom.xml  | 164 ++++
 .../stratos/metadataservice/Constants.java      |  28 +
 .../stratos/metadataservice/ServiceHolder.java  |  84 ++
 .../apache/stratos/metadataservice/Utils.java   |  44 +
 .../annotation/AuthorizationAction.java         |  36 +
 .../annotation/SuperTenantService.java          |  34 +
 .../context/AuthenticationContext.java          |  40 +
 .../definition/ApplicationBean.java             |  70 ++
 .../definition/CartridgeMetaData.java           |  36 +
 .../metadataservice/definition/ClusterBean.java |  59 ++
 .../metadataservice/definition/NewProperty.java |  68 ++
 .../definition/PropertyBean.java                |  37 +
 .../exception/MetadataException.java            |   9 +
 .../exception/RestAPIException.java             |  70 ++
 ...tractAuthenticationAuthorizationHandler.java |  56 ++
 .../CookieBasedAuthenticationHandler.java       |  94 ++
 .../handlers/CustomExceptionMapper.java         |  47 +
 .../CustomThrowableExceptionMapper.java         |  44 +
 .../handlers/GenericExceptionMapper.java        |  54 ++
 .../metadataservice/handlers/OAuthHandler.java  |  95 ++
 .../handlers/StratosAuthenticationHandler.java  | 156 ++++
 .../handlers/StratosAuthorizingHandler.java     | 333 +++++++
 .../metadataservice/listener/TopologyAgent.java | 130 +++
 .../listener/TopologyListener.java              |  69 ++
 .../oauth2/ValidationServiceClient.java         |  65 ++
 .../registry/CarbonRegistry.java                | 192 ++++
 .../registry/DataRegistryFactory.java           |  36 +
 .../metadataservice/registry/DataStore.java     |  40 +
 .../metadataservice/registry/GRegRegistry.java  | 109 +++
 .../security/StratosPrincipal.java              |  53 ++
 .../security/StratosSecurityContext.java        |  50 ++
 .../metadataservice/services/MetaDataAdmin.java | 188 ++++
 .../stratos/metadataservice/util/ConfUtil.java  |  76 ++
 .../src/main/resources/axis2_client.xml         | 299 +++++++
 .../META-INF/webapp-classloading.xml            |  35 +
 .../WEB-INF/cxf-servlet.xml                     |  46 +
 .../stratosmetadataservice-test/WEB-INF/web.xml |  40 +
 .../META-INF/webapp-classloading.xml            |  35 +
 .../WEB-INF/cxf-servlet.xml                     |  80 ++
 .../stratosmetadataservice/WEB-INF/web.xml      |  42 +
 .../rest/endpoint/bean/ApplicationBean.java     |  49 +
 .../rest/endpoint/bean/CartridgeInfoBean.java   |   3 +-
 .../stratos/rest/endpoint/bean/GroupBean.java   |  86 ++
 .../definition/CartridgeDefinitionBean.java     |  13 +-
 .../rest/endpoint/bean/topology/Cluster.java    |   2 +-
 .../bean/util/converter/PojoConverter.java      | 164 ++++
 .../stratos/rest/endpoint/services/MyType.java  |  16 -
 .../rest/endpoint/services/ServiceUtils.java    | 260 +++++-
 .../rest/endpoint/services/StratosAdmin.java    | 145 +++
 .../webapp/stratos/WEB-INF/schemas/schema.xsd   |  67 ++
 components/pom.xml                              |   5 +-
 .../pom.xml                                     | 111 +++
 features/common/pom.xml                         |  37 +
 .../pom.xml                                     | 320 +++++++
 .../src/main/resources/p2.inf                   |  23 +
 .../src/main/resources/tomcat/context.xml       |  36 +
 .../tomcat/webapp-classloading-environments.xml |  68 ++
 .../resources/tomcat/webapp-classloading.xml    |  33 +
 features/manager/pom.xml                        |   1 +
 .../pom.xml                                     |  10 +
 features/pom.xml                                |   1 +
 .../conf/templates/jndi.properties.template     |  27 +
 .../modules/distribution/src/assembly/bin.xml   |  24 +-
 .../modules/distribution/src/bin/stratos.sh     |   7 +-
 .../src/main/conf/metadataservice.xml           |  43 +
 .../distribution/src/main/conf/mincheck.drl     |  84 ++
 .../src/main/conf/terminatedependency.drl       |  52 ++
 .../distribution/src/main/license/LICENSE       |   4 +-
 products/stratos/modules/p2-profile-gen/pom.xml |  48 +-
 products/stratos/pom.xml                        |   1 +
 .../pom.xml                                     |   7 +-
 .../deployment_script.sh                        |  36 +
 .../m1-samples/ec2/autoscale-policy.json        |  14 +
 .../m1-samples/ec2/deployment-policy.json       |  14 +
 .../ec2/m1_single_subsciption_app.json          |  19 +
 .../m1-samples/ec2/p1.json                      |  10 +
 .../m1-samples/ec2/php-cart.json                |  38 +
 .../m1-samples/os/autoscale-policy.json         |  14 +
 .../m1-samples/os/deployment-policy.json        |  14 +
 .../os/m1_single_subsciption_app.json           |  19 +
 .../m1-samples/os/p1.json                       |  10 +
 .../m1-samples/os/php-cart.json                 |  46 +
 .../samples/ec2/autoscale-policy 2.json         |  17 +
 .../samples/ec2/autoscale-policy.json           |  14 +
 .../samples/ec2/deployment-policy 2.json        |  14 +
 .../samples/ec2/deployment-policy.json          |  14 +
 .../samples/ec2/group1.json                     |   9 +
 .../samples/ec2/group2.json                     |  15 +
 .../samples/ec2/m1_single_subsciption_app.json  |  19 +
 .../samples/ec2/m2_single_subsciption_app.json  |  95 ++
 .../samples/ec2/mysql.json                      |  33 +
 .../samples/ec2/mytest.json                     |  33 +
 .../samples/ec2/p1.json                         |  10 +
 .../samples/ec2/php-cart.json                   |  38 +
 .../samples/ec2/tomcat.json                     |  33 +
 .../samples/ec2/tomcat1.json                    |  33 +
 .../samples/os/autoscale-policy.json            |  14 +
 .../samples/os/deployment-policy.json           |  14 +
 .../samples/os/m1_single_subsciption_app.json   |  19 +
 .../samples/os/p1.json                          |  10 +
 .../samples/os/php-cart.json                    |  46 +
 .../mysql/templates/instance-activated.sh.erb   |  28 +
 .../mysql/templates/instance-started.sh.erb     |  43 +
 .../templates/mysql_root_password_setter.sh.erb |  16 +
 .../mysql/templates/publish-metadata.py.erb     |  95 ++
 tools/stratos-installer/conf/setup.conf         |   5 +
 .../all/repository/conf/metadataservice.xml     |  37 +
 .../config/greg/repository/conf/carbon.xml      | 609 +++++++++++++
 tools/stratos-installer/setup.sh                |  29 +
 tools/stratos-installer/start-servers.sh        |   7 +-
 433 files changed, 30504 insertions(+), 1771 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/PartitionContext.java
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/PartitionContext.java
index 07014e4,d0886a3..520cf86
--- a/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/PartitionContext.java
+++ b/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/PartitionContext.java
@@@ -23,18 -31,11 +31,20 @@@ import java.util.HashSet
  import java.util.Iterator;
  import java.util.List;
  import java.util.Map;
 +import java.util.Map.Entry;
  import java.util.Properties;
+ import java.util.Set;
  import java.util.concurrent.ConcurrentHashMap;
+ import java.util.concurrent.CopyOnWriteArrayList;
  
 +import org.apache.commons.configuration.XMLConfiguration;
 +import org.apache.commons.logging.Log;
 +import org.apache.commons.logging.LogFactory;
 +import org.apache.stratos.autoscaler.util.ConfUtil;
 +import org.apache.stratos.cloud.controller.stub.deployment.partition.Partition;
 +import org.apache.stratos.cloud.controller.stub.pojo.MemberContext;
 +import org.apache.stratos.common.constants.StratosConstants;
 +
  
  /**
   * This is an object that inserted to the rules engine.

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/health/AutoscalerHealthStatEventReceiver.java
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/health/AutoscalerHealthStatEventReceiver.java
index 88d8dee,f192cee..cd9aa9d
--- a/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/health/AutoscalerHealthStatEventReceiver.java
+++ b/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/message/receiver/health/AutoscalerHealthStatEventReceiver.java
@@@ -105,22 -84,34 +105,22 @@@ public class AutoscalerHealthStatEventR
          healthStatEventReceiver.addEventListener(new AverageLoadAverageEventListener() {
              @Override
              protected void onEvent(org.apache.stratos.messaging.event.Event event) {
 -                AverageLoadAverageEvent e = (AverageLoadAverageEvent) event;
 -                String clusterId = e.getClusterId();
 -                String networkPartitionId = e.getNetworkPartitionId();
 -
 -                Float floatValue = e.getValue();
 -
 -                if (log.isDebugEnabled()) {
 -                    log.debug(String.format("Avg load avg event: [cluster] %s [network-partition]
%s [value] %s",
 -                            clusterId, networkPartitionId, floatValue));
 -                }
 -                AbstractClusterMonitor monitor = getMonitor(clusterId);
 -                if(null != monitor){
 -                    NetworkPartitionContext networkPartitionContext = monitor.getNetworkPartitionCtxt(networkPartitionId);
 -                    if(null != networkPartitionContext){
 -                        networkPartitionContext.setAverageLoadAverage(floatValue);
 -                    } else {
 -                        if(log.isDebugEnabled()) {
 -                           log.debug(String.format("Network partition context is not available
for :" +
 -                                   " [network partition] %s", networkPartitionId));
 -                        }
 +                AverageLoadAverageEvent averageLoadAverageEvent = (AverageLoadAverageEvent)
event;
 +                String clusterId = averageLoadAverageEvent.getClusterId();
 +                AutoscalerContext asCtx = AutoscalerContext.getInstance();
 +                AbstractClusterMonitor monitor;
 +                monitor = asCtx.getClusterMonitor(clusterId);
 +                if (null == monitor) {
 +                    if (log.isDebugEnabled()) {
 +                        log.debug(String.format("A cluster monitor is not found in autoscaler
context "
 +                                                + "[cluster] %s", clusterId));
                      }
 -                } else {
                      return;
                  }
 -
 +                monitor.handleAverageLoadAverageEvent(averageLoadAverageEvent);
              }
-         });
  
+         });
          healthStatEventReceiver.addEventListener(new AverageMemoryConsumptionEventListener()
{
              @Override
              protected void onEvent(org.apache.stratos.messaging.event.Event event) {

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/rule/AutoscalerRuleEvaluator.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/rule/RuleTasksDelegator.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cartridge.agent/src/main/java/org/apache/stratos/cartridge/agent/CartridgeAgent.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/RestCommandLineService.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/StratosApplication.java
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/StratosApplication.java
index a528e61,5031aed..9fcaf9b
--- a/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/StratosApplication.java
+++ b/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/StratosApplication.java
@@@ -442,10 -444,10 +446,10 @@@ public class StratosApplication extend
  		Command<StratosCommandContext> command = commands.get(action);
  		if (command == null) {
  			System.out.println(action + ": command not found.");
 -			return CliConstants.BAD_ARGS_CODE;
 +			return CliConstants.COMMAND_FAILED;
  		}
  		try {
- 			return command.execute(context, actionArgs);
+ 			return command.execute(context, actionArgs, new Option[0]);
  		} catch (CommandException e) {
  			if (logger.isErrorEnabled()) {
  				logger.error("Error executing command: " + action, e);

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ActivateTenantCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/AddDomainMappingCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/AddTenantCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DeactivateTenantCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DeleteTenantCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DescribeAutoScalingPolicyCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DescribeCartridgeCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DescribeDeploymentPolicyCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/DescribePartitionCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ExitCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/HelpCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/InfoCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ListAllTenants.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ListCartridgesCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ListDeployServiceCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/ListMemberCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/SyncCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UndeployCartridgeDefinitionCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UndeployServiceDefinitionCommand.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UnsubscribeCommand.java
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UnsubscribeCommand.java
index c56db7d,20f3676..ff4967a
--- a/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UnsubscribeCommand.java
+++ b/components/org.apache.stratos.cli/src/main/java/org/apache/stratos/cli/commands/UnsubscribeCommand.java
@@@ -92,10 -97,10 +97,10 @@@ public class UnsubscribeCommand impleme
  						logger.debug("Unsubscribe: not enough arguments");
  					}
  					context.getStratosApplication().printUsage(getName());
 -					return CliConstants.BAD_ARGS_CODE;
 +					return CliConstants.COMMAND_FAILED;
  				}
  
- 				if (commandLine.hasOption(CliConstants.FORCE_OPTION)) {
+ 				if (opts.hasOption(CliConstants.FORCE_OPTION)) {
  					if (logger.isTraceEnabled()) {
  						logger.trace("Force option is passed");
  					}

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cloud.controller/pom.xml
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.cloud.controller/pom.xml
index c66dd7d,ce3c635..1f63e3f
--- a/components/org.apache.stratos.cloud.controller/pom.xml
+++ b/components/org.apache.stratos.cloud.controller/pom.xml
@@@ -55,8 -55,9 +55,9 @@@
                              org.apache.stratos.cloud.controller.topology.*,
                              org.apache.stratos.cloud.controller.iaases.*,
                              org.apache.stratos.cloud.controller.pojo.*,
 -                            org.apache.stratos.cloud.controller.pojo.application.*,
                              org.apache.stratos.cloud.controller.deployers.*,
                              org.apache.stratos.cloud.controller.exception.*,
++                            org.apache.stratos.cloud.controller.pojo.application.*,
                          </Export-Package>
                          <Private-Package>
                              !org.apache.stratos.cloud.controller.interfaces.*,

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/AWSEC2Iaas.java
----------------------------------------------------------------------
diff --cc components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/AWSEC2Iaas.java
index 435df18,3e46e52..a637edc
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/AWSEC2Iaas.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/AWSEC2Iaas.java
@@@ -95,7 -95,11 +95,11 @@@ public class AWSEC2Iaas extends Iaas 
  		// set image id specified
  		templateBuilder.imageId(iaasInfo.getImage());
  
+         if(!(iaasInfo instanceof IaasProvider)) {
+            templateBuilder.locationId(iaasInfo.getType());
+         }
+ 
 -        /*if(iaasInfo.getProperty(CloudControllerConstants.AVAILABILITY_ZONE) != null) {
 +        if(iaasInfo.getProperty(CloudControllerConstants.AVAILABILITY_ZONE) != null) {
              Set<? extends Location> locations = iaasInfo.getComputeService().listAssignableLocations();
              for(Location location : locations) {
                  if(location.getScope().toString().equalsIgnoreCase(CloudControllerConstants.ZONE_ELEMENT)
&&

http://git-wip-us.apache.org/repos/asf/stratos/blob/17cc86eb/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/OpenstackNovaIaas.java
----------------------------------------------------------------------


Mime
View raw message