Revert "Merge the missing changes" This reverts commit 12fdfb0872c729f92b905aedb15b7c42b5aa1205.
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/986684d9 Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/986684d9 Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/986684d9 Branch: refs/heads/master Commit: 986684d976c69f54827889177cb659d8f5fbce2d Parents: c960c14 Author: gayangunarathne <[email protected]> Authored: Mon Nov 2 16:53:20 2015 +0530 Committer: gayangunarathne <[email protected]> Committed: Mon Nov 2 16:53:20 2015 +0530 ---------------------------------------------------------------------- .../rest/endpoint/api/StratosApiV41.java | 2 +- .../rest/endpoint/api/StratosApiV41Utils.java | 26 -------------------- extensions/cep/pom.xml | 2 +- 3 files changed, 2 insertions(+), 28 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/stratos/blob/986684d9/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java ---------------------------------------------------------------------- diff --git a/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java b/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java index 9147d27..77dd8ba 100644 --- a/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java +++ b/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java @@ -296,7 +296,7 @@ public class StratosApiV41 extends AbstractApi { PrivilegedCarbonContext carbonContext = PrivilegedCarbonContext.getThreadLocalCarbonContext(); int tenantId = carbonContext.getTenantId(); - String cartridgeUuid = cartridgeType + "~" +UUID.randomUUID().toString(); + String cartridgeUuid = cartridgeType + "~" +tenantId;//UUID.randomUUID().toString() CartridgeBean cartridgeBean = null; try { http://git-wip-us.apache.org/repos/asf/stratos/blob/986684d9/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41Utils.java ---------------------------------------------------------------------- diff --git a/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41Utils.java b/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41Utils.java index 629fdb5..958f1cd 100644 --- a/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41Utils.java +++ b/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41Utils.java @@ -108,9 +108,6 @@ public class StratosApiV41Utils { public static final String APPLICATION_STATUS_DEPLOYED = "Deployed"; public static final String APPLICATION_STATUS_CREATED = "Created"; public static final String APPLICATION_STATUS_UNDEPLOYING = "Undeploying"; - public static final String KUBERNETES_SERVICE_TYPE_NODEPORT = "NodePort"; - public static final String KUBERNETES_SERVICE_TYPE_CLUSTERIP = "ClusterIP"; - public static final String KUBERNETES_IAAS_PROVIDER = "kubernetes"; public static final int SUPER_TENANT_ID = -1234; private static final Log log = LogFactory.getLog(StratosApiV41Utils.class); @@ -137,14 +134,6 @@ public class StratosApiV41Utils { cartridgeBean.getType())); } - boolean isKubernetesIaasProviderAvailable = false; - - for (IaasProviderBean providers : iaasProviders) { - if (providers.getType().equals(KUBERNETES_IAAS_PROVIDER)) { - isKubernetesIaasProviderAvailable = true; - } - } - for (PortMappingBean portMapping : cartridgeBean.getPortMapping()) { if (StringUtils.isBlank(portMapping.getName())) { portMapping.setName(portMapping.getProtocol() + "-" + portMapping.getPort()); @@ -154,21 +143,6 @@ public class StratosApiV41Utils { cartridgeUuid, cartridgeBean.getType(), portMapping.getName())); } } - - String type = portMapping.getKubernetesPortType(); - - if (isKubernetesIaasProviderAvailable) { - if (type == null) { - throw new RestAPIException((String.format("Type is not found in portmapping: %s - Possible " + - "values - %s and %s", portMapping.getName(), KUBERNETES_SERVICE_TYPE_NODEPORT, - KUBERNETES_SERVICE_TYPE_CLUSTERIP))); - } else if (!type.equals(KUBERNETES_SERVICE_TYPE_NODEPORT) && !type.equals(KUBERNETES_SERVICE_TYPE_CLUSTERIP)) { - throw new RestAPIException((String.format("Type is not found in portmapping: %s - Possible " + - "values - %s and %s", portMapping.getName(), KUBERNETES_SERVICE_TYPE_NODEPORT, - KUBERNETES_SERVICE_TYPE_CLUSTERIP))); - } - } - } Cartridge cartridgeConfig = createCartridgeConfig(cartridgeBean, cartridgeUuid, tenantId); http://git-wip-us.apache.org/repos/asf/stratos/blob/986684d9/extensions/cep/pom.xml ---------------------------------------------------------------------- diff --git a/extensions/cep/pom.xml b/extensions/cep/pom.xml index 9c88138..285ac26 100644 --- a/extensions/cep/pom.xml +++ b/extensions/cep/pom.xml @@ -33,6 +33,6 @@ <modules> <module>modules/distribution</module> - + <module>modules/stratos-cep-extension</module> </modules> </project>
