You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by la...@apache.org on 2013/07/12 18:55:02 UTC

[2/3] git commit: removed directories which refactors and some are not in use

removed directories which refactors and some are not in use


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

Branch: refs/heads/master
Commit: 6be46269c1ca7e7468882909f6c8c9d44bc35bd6
Parents: 69d8c75
Author: Lakmal Warusawithana <la...@wso2.com>
Authored: Fri Jul 12 22:23:59 2013 +0530
Committer: Lakmal Warusawithana <la...@wso2.com>
Committed: Fri Jul 12 22:23:59 2013 +0530

----------------------------------------------------------------------
 components/stratos/account-mgt/pom.xml          |  41 -----
 components/stratos/domain-validator/pom.xml     |  41 -----
 .../org.wso2.carbon.activation/2.1.0/pom.xml    |  94 -----------
 .../internal/ActivationServiceComponent.java    | 152 -----------------
 .../activation/module/ActivationHandler.java    | 154 ------------------
 .../activation/module/ActivationModule.java     |  65 --------
 .../activation/service/ActivationService.java   |  85 ----------
 .../activation/utils/ActivationManager.java     |  96 -----------
 .../org/wso2/carbon/activation/utils/Util.java  | 138 ----------------
 .../src/main/resources/META-INF/module.xml      |  33 ----
 .../src/main/resources/META-INF/services.xml    |  30 ----
 .../org.wso2.carbon.activation/2.1.2/pom.xml    |  94 -----------
 .../internal/ActivationServiceComponent.java    | 152 -----------------
 .../activation/module/ActivationHandler.java    | 161 -------------------
 .../activation/module/ActivationModule.java     |  65 --------
 .../activation/service/ActivationService.java   |  85 ----------
 .../activation/utils/ActivationManager.java     |  96 -----------
 .../org/wso2/carbon/activation/utils/Util.java  | 138 ----------------
 .../src/main/resources/META-INF/module.xml      |  33 ----
 .../src/main/resources/META-INF/services.xml    |  30 ----
 .../2.1.0/pom.xml                               |  92 -----------
 .../deployer/LandingPageWebappDeployer.java     | 109 -------------
 .../page/deployer/internal/DataHolder.java      |  37 -----
 ...ndingPageWebappDeployerServiceComponent.java |  44 -----
 .../src/main/resources/META-INF/component.xml   |  23 ---
 .../2.1.0/pom.xml                               |  90 -----------
 .../org/wso2/carbon/ui/menu/stratos/Util.java   |  88 ----------
 .../StratosUIGeneralMenuDSComponent.java        |  52 ------
 .../src/main/resources/META-INF/component.xml   |  45 ------
 .../ui/menu/general/i18n/Resources.properties   |   2 -
 .../web/manager-home/images/services.gif        | Bin 604 -> 0 bytes
 .../manager-home/load_manager_ajaxprocessor.jsp |  30 ----
 .../2.1.0/pom.xml                               | 132 ---------------
 .../web/tenant-activity/docs/userguide.html     |  76 ---------
 .../2.1.0/pom.xml                               | 144 -----------------
 35 files changed, 2747 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/account-mgt/pom.xml
----------------------------------------------------------------------
diff --git a/components/stratos/account-mgt/pom.xml b/components/stratos/account-mgt/pom.xml
deleted file mode 100644
index c58b0a4..0000000
--- a/components/stratos/account-mgt/pom.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- ~ Copyright (c) 2009-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- ~
- ~ Licensed under the Apache License, Version 2.0 (the "License");
- ~ you may not use this file except in compliance with the License.
- ~ You may obtain a copy of the License at
- ~
- ~      http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing, software
- ~ distributed under the License is distributed on an "AS IS" BASIS,
- ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ~ See the License for the specific language governing permissions and
- ~ limitations under the License.
--->
-
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-
-    <parent>
-        <groupId>org.wso2.carbon</groupId>
-        <artifactId>stratos-components</artifactId>
-        <version>2.1.0</version>
-    </parent>
-
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>account-mgt-parent</artifactId>
-    <packaging>pom</packaging>
-    <name>WSO2 Stratos - Account  Management Parent Module</name>
-    <description>WSO2 Stratos Account Management Parent Module</description>
-    <url>http://wso2.org</url>
-
-    <modules>
-        <module>org.wso2.carbon.account.mgt/2.1.0</module>
-        <module>org.wso2.carbon.account.mgt.ui/2.1.0</module>
-    </modules>
-
-</project>
-

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/domain-validator/pom.xml
----------------------------------------------------------------------
diff --git a/components/stratos/domain-validator/pom.xml b/components/stratos/domain-validator/pom.xml
deleted file mode 100644
index aff23aa..0000000
--- a/components/stratos/domain-validator/pom.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- ~ Copyright (c) 2009-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- ~
- ~ Licensed under the Apache License, Version 2.0 (the "License");
- ~ you may not use this file except in compliance with the License.
- ~ You may obtain a copy of the License at
- ~
- ~      http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing, software
- ~ distributed under the License is distributed on an "AS IS" BASIS,
- ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ~ See the License for the specific language governing permissions and
- ~ limitations under the License.
--->
-
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-
-    <parent>
-        <groupId>org.wso2.carbon</groupId>
-        <artifactId>stratos-components</artifactId>
-        <version>2.1.0</version>
-    </parent>
-
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>domain-validator-parent</artifactId>
-    <packaging>pom</packaging>
-    <name>WSO2 Stratos - Domain Validator Parent Module</name>
-    <description>WSO2 Stratos Domain Validator Parent Module</description>
-    <url>http://wso2.org</url>
-
-    <modules>
-        <module>org.wso2.carbon.validate.domain/2.1.0</module>
-        <module>org.wso2.carbon.validate.domain.ui/2.1.0</module>
-    </modules>
-
-</project>
-

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/pom.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/pom.xml b/components/stratos/org.wso2.carbon.activation/2.1.0/pom.xml
deleted file mode 100644
index a024242..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/pom.xml
+++ /dev/null
@@ -1,94 +0,0 @@
-<!--
-# Copyright (c) 2008, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-  -->
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-    <parent>
-        <groupId>org.wso2.carbon</groupId>
-        <artifactId>stratos-components</artifactId>
-        <version>2.1.0</version>
-<relativePath>../../pom.xml</relativePath>
-    </parent>
-
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>org.wso2.carbon.activation</artifactId>
-    <version>2.1.0</version>
-    <packaging>bundle</packaging>
-    <name>WSO2 Stratos - Activation</name>
-
-    <build>
-
-        <plugins>
-            <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-scr-plugin</artifactId>
-            </plugin>
-            <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-bundle-plugin</artifactId>
-                
-                <extensions>true</extensions>
-                <configuration>
-                    <instructions>
-                        <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
-                        <Axis2Module>${project.artifactId}-${project.version}</Axis2Module>
-                        <Bundle-Name>${project.artifactId}</Bundle-Name>
-                        <Export-Package>
-                            org.wso2.carbon.activation.*,
-                        </Export-Package>
-                        <Import-Package>
-                            org.wso2.carbon.stratos.common.*,
-                            org.wso2.carbon.registry.core.*;version=1.0.1,
-                            org.wso2.carbon.registry.resource.*,
-                            !javax.xml.namespace,
-                            javax.xml.namespace; version=0.0.0,
-                            javax.servlet;version="${imp.pkg.version.javax.servlet}",
-                            javax.servlet.http;version="${imp.pkg.version.javax.servlet}",
-                            org.apache.axiom.*; version="${axiom.osgi.version.range}",
-                            *;resolution:=optional
-                        </Import-Package>
-                        <DynamicImport-Package>*</DynamicImport-Package>
-                    </instructions>
-                </configuration>
-            </plugin>
-        </plugins>
-    </build>
-
-    <dependencies>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.utils</artifactId>
-	    <version>4.1.0</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.axis2.wso2</groupId>
-            <artifactId>axis2</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.registry.core</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>commons-logging</groupId>
-            <artifactId>commons-logging</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.stratos.common</artifactId>
-        </dependency>
-    </dependencies>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
deleted file mode 100644
index e3fb386..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.internal;
-
-import org.apache.axis2.AxisFault;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.osgi.framework.ServiceRegistration;
-import org.osgi.service.component.ComponentContext;
-import org.wso2.carbon.registry.core.service.RegistryService;
-import org.wso2.carbon.user.core.service.RealmService;
-import org.wso2.carbon.utils.ConfigurationContextService;
-import org.wso2.carbon.activation.service.ActivationService;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-
-/**
- * The Declarative Service Component for the Service Activation Module for Tenants.
- *
- * @scr.component name="org.wso2.carbon.metering" immediate="true"
- * @scr.reference name="registry.service"
- * interface="org.wso2.carbon.registry.core.service.RegistryService"
- * cardinality="1..1" policy="dynamic" bind="setRegistryService" unbind="unsetRegistryService"
- * @scr.reference name="user.realmservice.default"
- * interface="org.wso2.carbon.user.core.service.RealmService"
- * cardinality="1..1" policy="dynamic" bind="setRealmService" unbind="unsetRealmService"
- * @scr.reference name="config.context.service"
- * interface="org.wso2.carbon.utils.ConfigurationContextService"
- * cardinality="0..1" policy="dynamic"  bind="setConfigurationContextService"
- * unbind="unsetConfigurationContextService"
- */
-@SuppressWarnings({"JavaDoc", "unused"})
-public class ActivationServiceComponent {
-
-    private static final Log log = LogFactory.getLog(ActivationServiceComponent.class);
-
-    private static ServiceRegistration registration = null;
-
-    /**
-     * Activates the Registry Kernel bundle.
-     *
-     * @param context the OSGi component context.
-     */
-    protected void activate(ComponentContext context) {
-        try {
-            ActivationManager.startCacheCleaner();
-            if (registration == null) {
-                registration = context.getBundleContext().registerService(
-                        ActivationService.class.getName(), new ActivationService(), null);
-            }
-            log.debug("******* Stratos Activation bundle is activated ******* ");
-        } catch (Exception e) {
-            log.error("******* Stratos Activation bundle failed activating ****", e);
-        }
-    }
-
-    /**
-     * Deactivates the Registry Kernel bundle.
-     *
-     * @param context the OSGi component context.
-     */
-    protected void deactivate(ComponentContext context) {
-        registration.unregister();
-        registration = null;
-        ActivationManager.stopCacheCleaner();
-        log.debug("******* Stratos Activation bundle is deactivated ******* ");
-    }
-
-    /**
-     * Method to set the registry service used. This will be used when accessing the registry. This
-     * method is called when the OSGi Registry Service is available.
-     *
-     * @param registryService the registry service.
-     */
-    protected void setRegistryService(RegistryService registryService) {
-        Util.setRegistryService(registryService);
-    }
-
-    /**
-     * This method is called when the current registry service becomes un-available.
-     *
-     * @param registryService the current registry service instance, to be used for any
-     *                        cleaning-up.
-     */
-    protected void unsetRegistryService(RegistryService registryService) {
-        Util.setRegistryService(null);
-    }
-
-    /**
-     * Method to set the realm service used. This will be used when accessing the user realm. This
-     * method is called when the OSGi Realm Service is available.
-     *
-     * @param realmService the realm service.
-     */
-    protected void setRealmService(RealmService realmService) {
-        Util.setRealmService(realmService);
-    }
-
-    /**
-     * This method is called when the current realm service becomes un-available.
-     *
-     * @param realmService the current realm service instance, to be used for any cleaning-up.
-     */
-    protected void unsetRealmService(RealmService realmService) {
-        Util.setRealmService(null);
-    }
-
-    /**
-     * Method to set the configuration context service used. This method is called when the OSGi
-     * ConfigurationContext Service is available.
-     *
-     * @param contextService the configuration context service.
-     */
-    protected void setConfigurationContextService(ConfigurationContextService contextService) {
-        try {
-            if (contextService.getServerConfigContext() != null &&
-                    contextService.getServerConfigContext().getAxisConfiguration() != null) {
-                contextService.getServerConfigContext().getAxisConfiguration().engageModule(
-                        "activation");
-            } else {
-                log.error("Failed to engage Activation Module.");
-            }
-        } catch (AxisFault e) {
-            log.error("Failed to engage Activation Module", e);
-        }
-    }
-
-    /**
-     * This method is called when the current configuration context service becomes un-available.
-     *
-     * @param contextService the current configuration context service instance, to be used for any
-     *                       cleaning-up.
-     */
-    protected void unsetConfigurationContextService(ConfigurationContextService contextService) {
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
deleted file mode 100644
index 4f1a1ca..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
+++ /dev/null
@@ -1,154 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.module;
-
-import javax.xml.namespace.QName;
-
-import org.apache.axiom.om.OMElement;
-import org.apache.axiom.soap.SOAPBody;
-import org.apache.axis2.AxisFault;
-import org.apache.axis2.context.MessageContext;
-import org.apache.axis2.description.AxisService;
-import org.apache.axis2.engine.Handler;
-import org.apache.axis2.handlers.AbstractHandler;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-import org.wso2.carbon.context.PrivilegedCarbonContext;
-import org.wso2.carbon.core.multitenancy.utils.TenantAxisUtils;
-import org.wso2.carbon.stratos.common.util.CloudServicesUtil;
-import org.wso2.carbon.utils.ServerConstants;
-import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
-import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
-
-public class ActivationHandler extends AbstractHandler implements Handler {
-
-    private static final Log log = LogFactory.getLog(ActivationHandler.class);
-
-    private String name = "ActivationHandler";
-
-    /**
-     * {@inheritDoc}
-     */
-    public InvocationResponse invoke(MessageContext messageContext) throws AxisFault {
-        if(log.isDebugEnabled()){
-            log.debug("Starting Activation Handler invocation. Incoming Message: " +
-                    messageContext.getEnvelope().toString());
-        }
-
-        AxisService service = messageContext.getAxisService();
-        int tenantId = getTenantId(messageContext);
-        if (service != null && "ActivationService".equals(service.getName())) {
-            log.debug("Granted access to the Activation Service");
-            if (tenantId > 0) {
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-            }
-            return InvocationResponse.CONTINUE;
-        }
-        if (tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            log.debug("Granted access for super tenant");
-            return InvocationResponse.CONTINUE;
-        }
-        if (ActivationManager.activationRecorded(tenantId)) {
-            if (ActivationManager.getActivation(tenantId)) {
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-                return InvocationResponse.CONTINUE;
-            } else {
-                if (log.isWarnEnabled()) {
-                    String serviceName = Util.getServiceName();
-                    log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-                }
-                return InvocationResponse.ABORT;
-            }
-        }
-        String serviceName = Util.getServiceName();
-        try {
-            if (CloudServicesUtil.isCloudServiceActive(serviceName, tenantId)) {
-                log.debug("Successful attempt to access " + serviceName + " by tenant " + tenantId);
-                ActivationManager.setActivation(tenantId, true);
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-                return InvocationResponse.CONTINUE;
-            }
-        } catch (Exception e) {
-            throw new AxisFault("Failed to determine Activation status.", e);
-        }
-        log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-        ActivationManager.setActivation(tenantId, false);
-        return InvocationResponse.ABORT;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Method to set the name of the activation handler.
-     *
-     * @param name the name.
-     */
-    @SuppressWarnings("unused")
-    public void setName(String name) {
-        this.name = name;
-    }
-
-    private String getTenantDomain(MessageContext messageContext) {
-        return PrivilegedCarbonContext.getCurrentContext(messageContext).getTenantDomain(true);
-    }
-
-    private int getTenantId(MessageContext messageContext) {
-        PrivilegedCarbonContext carbonContext =
-                PrivilegedCarbonContext.getCurrentContext(messageContext);
-        int tenantId = carbonContext.getTenantId();
-        if (tenantId > -1 || tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            return tenantId;
-        }
-        String domain = carbonContext.getTenantDomain();
-        if (domain == null) {
-            SOAPBody soapBody = messageContext.getEnvelope().getBody();
-            if (soapBody != null && soapBody.getFirstElement() != null) {
-                OMElement usernameElem = soapBody.getFirstElement().getFirstChildWithName(
-                        new QName(ServerConstants.AUTHENTICATION_SERVICE_NS,
-                                ServerConstants.AUTHENTICATION_SERVICE_USERNAME));
-                if (usernameElem != null) {
-                    String userName = usernameElem.getText();
-                    domain = MultitenantUtils.getTenantDomain(userName);
-                }
-            }
-        }
-        if (domain != null) {
-            try {
-                tenantId = Util.getRealmService().getTenantManager().getTenantId(domain);
-            } catch (org.wso2.carbon.user.api.UserStoreException e) {
-                log.error("An error occurred while obtaining the tenant id.", e);
-            }
-        }
-        return tenantId;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
deleted file mode 100644
index 9cfbee5..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.module;
-
-import org.apache.axis2.AxisFault;
-import org.apache.axis2.context.ConfigurationContext;
-import org.apache.axis2.description.AxisDescription;
-import org.apache.axis2.description.AxisModule;
-import org.apache.axis2.modules.Module;
-import org.apache.neethi.Assertion;
-import org.apache.neethi.Policy;
-
-/**
- * Module used to engage the activation handler.
- */
-public class ActivationModule implements Module {
-
-    /**
-     * {@inheritDoc}
-     */
-    public void init(ConfigurationContext configurationContext, AxisModule axisModule)
-            throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void engageNotify(AxisDescription axisDescription) throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public boolean canSupportAssertion(Assertion assertion) {
-        return true;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void applyPolicy(Policy policy, AxisDescription axisDescription) throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void shutdown(ConfigurationContext configurationContext) throws AxisFault {
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/service/ActivationService.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
deleted file mode 100644
index e16f2fb..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.service;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-import org.wso2.carbon.stratos.common.config.CloudServiceConfigParser;
-import org.wso2.carbon.stratos.common.config.CloudServicesDescConfig;
-import org.wso2.carbon.stratos.common.util.CloudServicesUtil;
-import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
-
-/**
- * Admin Service to handle activation of cloud services used by tenants.
- */
-public class ActivationService {
-
-    private static final Log log = LogFactory.getLog(ActivationService.class);
-
-    /**
-     * Method to update an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @throws Exception if the operation failed.
-     */
-    public static void updateActivation(int tenantId) throws Exception {
-        if (tenantId != 0) {
-            String serviceName = Util.getServiceName();
-            boolean isActive = CloudServicesUtil.isCloudServiceActive(serviceName, tenantId);
-            CloudServicesDescConfig cloudServicesDesc =
-                                                        CloudServiceConfigParser.loadCloudServicesConfiguration();
-            CloudServicesUtil.setCloudServiceActive(!isActive,
-                                                    serviceName,
-                                                    tenantId,
-                                                    cloudServicesDesc.getCloudServiceConfigs()
-                                                                     .get(serviceName));
-            ActivationManager.setActivation(tenantId, !isActive);
-        }
-    }
-
-    /**
-     * Method to determine whether a service is active for the given tenant.
-     *
-     * @param tenantId tenantId the tenant identifier.
-     *
-     * @return whether the service is active.
-     * @throws Exception if the operation failed.
-     */
-    public boolean isActive(int tenantId) throws Exception {
-        if (tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            return true;
-        }
-        if (ActivationManager.activationRecorded(tenantId)) {
-            return ActivationManager.getActivation(tenantId);
-        }
-        String serviceName = Util.getServiceName();
-        if (CloudServicesUtil.isCloudServiceActive(serviceName, tenantId)) {
-            log.debug("Successful attempt to access " + serviceName + " by tenant " + tenantId);
-            ActivationManager.setActivation(tenantId, true);
-            return true;
-        }
-        log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-        ActivationManager.setActivation(tenantId, false);
-        return false;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
deleted file mode 100644
index 41153a8..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.utils;
-
-import java.util.Timer;
-import java.util.TimerTask;
-import java.util.concurrent.ConcurrentHashMap;
-
-/**
- * Manages Activations of Services for Tenants.
- */
-public class ActivationManager {
-
-    private static final ConcurrentHashMap<Integer, Boolean> activations =
-            new ConcurrentHashMap<Integer, Boolean>();
-    private static Timer timer = null;
-
-    /**
-     * Starts cleaning up cached activation records at periodic intervals.
-     */
-    public static void startCacheCleaner() {
-        TimerTask faultyServiceRectifier = new CacheCleaner();
-        timer = new Timer();
-        // Retry in 1 minute
-        long retryIn = 1000 * 60;
-        timer.schedule(faultyServiceRectifier, 0, retryIn);
-    }
-
-    /**
-     * Stops cleaning up cached activation records.
-     */
-    public static void stopCacheCleaner() {
-        timer.cancel();
-        timer = null;
-    }
-
-    /**
-     * Method to set an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     * @param status   true if the service is active or false if not.
-     */
-    public static void setActivation(int tenantId, boolean status) {
-        ActivationManager.activations.put(tenantId, status);
-    }
-
-    /**
-     * Method to check whether an activation record exists for the given tenant.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @return true if a record exists.
-     */
-    public static boolean activationRecorded(int tenantId) {
-        return ActivationManager.activations.get(tenantId) != null;
-    }
-
-    /**
-     * Method to retrieve an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @return true if the service is active or false if not.
-     */
-    public static boolean getActivation(int tenantId) {
-        return ActivationManager.activations.get(tenantId) != null &&
-                ActivationManager.activations.get(tenantId);
-    }
-
-    private static class CacheCleaner extends TimerTask {
-
-        /**
-         * {@inheritDoc}
-         */
-        public void run() {
-            ActivationManager.activations.clear();
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/Util.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/Util.java b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/Util.java
deleted file mode 100644
index 9f01045..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/java/org/wso2/carbon/activation/utils/Util.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.utils;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.base.ServerConfiguration;
-import org.wso2.carbon.registry.core.exceptions.RegistryException;
-import org.wso2.carbon.registry.core.service.RegistryService;
-import org.wso2.carbon.registry.core.session.UserRegistry;
-import org.wso2.carbon.user.core.service.RealmService;
-
-/**
- * Utilities for the Service Activation Module for Tenants.
- */
-public class Util {
-
-    private static RegistryService registryService = null;
-    private static RealmService realmService = null;
-    private static String serviceName = null;
-    private static final Log log = LogFactory.getLog(Util.class);
-
-    private static boolean cloudServiceInfoPathSanityChecked = false;
-
-    /**
-     * Stores an instance of the Registry Service that can be used to access the registry.
-     *
-     * @param service the Registry Service instance.
-     */
-    public static synchronized void setRegistryService(RegistryService service) {
-        if (registryService == null) {
-            registryService = service;
-        }
-    }
-
-    /**
-     * Method to retrieve the Registry Service instance.
-     *
-     * @return the Registry Service instance if it has been stored or null if not.
-     */
-    @SuppressWarnings("unused")
-    public static RegistryService getRegistryService() {
-        return registryService;
-    }
-
-    /**
-     * Stores an instance of the Realm Service that can be used to access the user realm.
-     *
-     * @param service the Realm Service instance.
-     */
-    public static synchronized void setRealmService(RealmService service) {
-        if (realmService == null) {
-            realmService = service;
-        }
-    }
-
-    /**
-     * Method to retrieve the Realm Service instance.
-     *
-     * @return the Realm Service instance if it has been stored or null if not.
-     */
-    public static RealmService getRealmService() {
-        return realmService;
-    }
-
-    private static UserRegistry getSuperTenantGovernanceSystemRegistry() throws RegistryException {
-        return registryService.getGovernanceSystemRegistry();
-    }
-
-//    /**
-//     * Method to determine whether the given cloud service is active.
-//     *
-//     * @param cloudServiceName the name of the cloud service.
-//     * @param tenantId         the tenant identifier.
-//     * @param systemRegistry   the super tenant's governance system registry
-//     *
-//     * @return true if the service is active or false if not.
-//     * @throws Exception if the operation failed.
-//     */
-//    public static boolean isCloudServiceActive(String cloudServiceName,
-//                                               int tenantId, UserRegistry systemRegistry)
-//            throws Exception {
-//        // The cloud manager is always active
-//        if (StratosConstants.CLOUD_MANAGER_SERVICE.equals(cloudServiceName)) {
-//            return true;
-//        }
-//
-//        if(!cloudServiceInfoPathSanityChecked) {
-//            if(!systemRegistry.resourceExists(StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH)) {
-//                throw new RuntimeException("Cloud services list resource " +
-//                                           StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH + " does not exist");
-//            }
-//            cloudServiceInfoPathSanityChecked = true;
-//        }
-//
-//        String cloudServiceInfoPath = StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH +
-//                RegistryConstants.PATH_SEPARATOR + tenantId +
-//                RegistryConstants.PATH_SEPARATOR + cloudServiceName;
-//        Resource cloudServiceInfoResource;
-//        if (systemRegistry.resourceExists(cloudServiceInfoPath)) {
-//            cloudServiceInfoResource = systemRegistry.get(cloudServiceInfoPath);
-//            String isActiveStr =
-//                cloudServiceInfoResource.getProperty(StratosConstants.CLOUD_SERVICE_IS_ACTIVE_PROP_KEY);
-//            return Boolean.toString(true).equals(isActiveStr);
-//        }
-//        return false;
-//    }
-//
-
-    /**
-     * Method to obtain the name of the cloud service in which this module is running.
-     *
-     * @return the name of the service as defined in the server configuration.
-     */
-    public static String getServiceName() {
-        if (serviceName == null) {
-            serviceName = ServerConfiguration.getInstance().getFirstProperty("Name");
-        }
-        return serviceName;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/module.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/module.xml b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/module.xml
deleted file mode 100644
index b92b725..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/module.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<!--
- ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- ~
- ~ WSO2 Inc. licenses this file to you under the Apache License,
- ~ Version 2.0 (the "License"); you may not use this file except
- ~ in compliance with the License.
- ~ You may obtain a copy of the License at
- ~
- ~    http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied.  See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
- -->
-<module name="activation" class="org.wso2.carbon.activation.module.ActivationModule">
-   <InFlow>
-        <handler name="InFlowActivationHandler"
-                 class="org.wso2.carbon.activation.module.ActivationHandler">
-        <order phase="Validation" phaseFirst="true"/>
-        </handler>
-   </InFlow>
-
-   <InFaultFlow>
-        <handler name="FaultInFlowActivationHandler"
-                 class="org.wso2.carbon.activation.module.ActivationHandler">
-        <order phase="Validation" phaseFirst="true"/>
-        </handler>
-   </InFaultFlow>
-  <parameter name="adminModule" locked="true">true</parameter>
-</module>

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/services.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/services.xml b/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/services.xml
deleted file mode 100644
index dde74d7..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.0/src/main/resources/META-INF/services.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- !
- ! Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- !
- ! WSO2 Inc. licenses this file to you under the Apache License,
- ! Version 2.0 (the "License"); you may not use this file except
- ! in compliance with the License.
- ! You may obtain a copy of the License at
- !
- ! http://www.apache.org/licenses/LICENSE-2.0
- !
- ! Unless required by applicable law or agreed to in writing,
- ! software distributed under the License is distributed on an
- ! "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ! KIND, either express or implied.  See the License for the
- ! specific language governing permissions and limitations
- ! under the License.
- !-->
-<serviceGroup>
-    <service name="ActivationService" scope="transportsession">
-        <transports>
-            <transport>https</transport>
-        </transports>
-        <parameter name="ServiceClass" locked="false">
-            org.wso2.carbon.activation.service.ActivationService
-        </parameter>
-    </service>
-    <parameter name="hiddenService" locked="true">true</parameter>
-</serviceGroup>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/pom.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/pom.xml b/components/stratos/org.wso2.carbon.activation/2.1.2/pom.xml
deleted file mode 100644
index b499811..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/pom.xml
+++ /dev/null
@@ -1,94 +0,0 @@
-<!--
-# Copyright (c) 2008, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-  -->
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-    <parent>
-        <groupId>org.wso2.carbon</groupId>
-        <artifactId>stratos-components</artifactId>
-        <version>2.1.0</version>
-<relativePath>../../pom.xml</relativePath>
-    </parent>
-
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>org.wso2.carbon.activation</artifactId>
-    <version>2.1.2</version>
-    <packaging>bundle</packaging>
-    <name>WSO2 Stratos - Activation</name>
-
-    <build>
-
-        <plugins>
-            <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-scr-plugin</artifactId>
-            </plugin>
-            <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-bundle-plugin</artifactId>
-                
-                <extensions>true</extensions>
-                <configuration>
-                    <instructions>
-                        <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
-                        <Axis2Module>${project.artifactId}-${project.version}</Axis2Module>
-                        <Bundle-Name>${project.artifactId}</Bundle-Name>
-                        <Export-Package>
-                            org.wso2.carbon.activation.*,
-                        </Export-Package>
-                        <Import-Package>
-                            org.wso2.carbon.stratos.common.*,
-                            org.wso2.carbon.registry.core.*;version=1.0.1,
-                            org.wso2.carbon.registry.resource.*,
-                            !javax.xml.namespace,
-                            javax.xml.namespace; version=0.0.0,
-                            javax.servlet;version="${imp.pkg.version.javax.servlet}",
-                            javax.servlet.http;version="${imp.pkg.version.javax.servlet}",
-                            org.apache.axiom.*; version="${axiom.osgi.version.range}",
-                            *;resolution:=optional
-                        </Import-Package>
-                        <DynamicImport-Package>*</DynamicImport-Package>
-                    </instructions>
-                </configuration>
-            </plugin>
-        </plugins>
-    </build>
-
-    <dependencies>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.utils</artifactId>
-	    <version>4.1.0</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.axis2.wso2</groupId>
-            <artifactId>axis2</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.registry.core</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>commons-logging</groupId>
-            <artifactId>commons-logging</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.wso2.carbon</groupId>
-            <artifactId>org.wso2.carbon.stratos.common</artifactId>
-        </dependency>
-    </dependencies>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
deleted file mode 100644
index e3fb386..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/internal/ActivationServiceComponent.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.internal;
-
-import org.apache.axis2.AxisFault;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.osgi.framework.ServiceRegistration;
-import org.osgi.service.component.ComponentContext;
-import org.wso2.carbon.registry.core.service.RegistryService;
-import org.wso2.carbon.user.core.service.RealmService;
-import org.wso2.carbon.utils.ConfigurationContextService;
-import org.wso2.carbon.activation.service.ActivationService;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-
-/**
- * The Declarative Service Component for the Service Activation Module for Tenants.
- *
- * @scr.component name="org.wso2.carbon.metering" immediate="true"
- * @scr.reference name="registry.service"
- * interface="org.wso2.carbon.registry.core.service.RegistryService"
- * cardinality="1..1" policy="dynamic" bind="setRegistryService" unbind="unsetRegistryService"
- * @scr.reference name="user.realmservice.default"
- * interface="org.wso2.carbon.user.core.service.RealmService"
- * cardinality="1..1" policy="dynamic" bind="setRealmService" unbind="unsetRealmService"
- * @scr.reference name="config.context.service"
- * interface="org.wso2.carbon.utils.ConfigurationContextService"
- * cardinality="0..1" policy="dynamic"  bind="setConfigurationContextService"
- * unbind="unsetConfigurationContextService"
- */
-@SuppressWarnings({"JavaDoc", "unused"})
-public class ActivationServiceComponent {
-
-    private static final Log log = LogFactory.getLog(ActivationServiceComponent.class);
-
-    private static ServiceRegistration registration = null;
-
-    /**
-     * Activates the Registry Kernel bundle.
-     *
-     * @param context the OSGi component context.
-     */
-    protected void activate(ComponentContext context) {
-        try {
-            ActivationManager.startCacheCleaner();
-            if (registration == null) {
-                registration = context.getBundleContext().registerService(
-                        ActivationService.class.getName(), new ActivationService(), null);
-            }
-            log.debug("******* Stratos Activation bundle is activated ******* ");
-        } catch (Exception e) {
-            log.error("******* Stratos Activation bundle failed activating ****", e);
-        }
-    }
-
-    /**
-     * Deactivates the Registry Kernel bundle.
-     *
-     * @param context the OSGi component context.
-     */
-    protected void deactivate(ComponentContext context) {
-        registration.unregister();
-        registration = null;
-        ActivationManager.stopCacheCleaner();
-        log.debug("******* Stratos Activation bundle is deactivated ******* ");
-    }
-
-    /**
-     * Method to set the registry service used. This will be used when accessing the registry. This
-     * method is called when the OSGi Registry Service is available.
-     *
-     * @param registryService the registry service.
-     */
-    protected void setRegistryService(RegistryService registryService) {
-        Util.setRegistryService(registryService);
-    }
-
-    /**
-     * This method is called when the current registry service becomes un-available.
-     *
-     * @param registryService the current registry service instance, to be used for any
-     *                        cleaning-up.
-     */
-    protected void unsetRegistryService(RegistryService registryService) {
-        Util.setRegistryService(null);
-    }
-
-    /**
-     * Method to set the realm service used. This will be used when accessing the user realm. This
-     * method is called when the OSGi Realm Service is available.
-     *
-     * @param realmService the realm service.
-     */
-    protected void setRealmService(RealmService realmService) {
-        Util.setRealmService(realmService);
-    }
-
-    /**
-     * This method is called when the current realm service becomes un-available.
-     *
-     * @param realmService the current realm service instance, to be used for any cleaning-up.
-     */
-    protected void unsetRealmService(RealmService realmService) {
-        Util.setRealmService(null);
-    }
-
-    /**
-     * Method to set the configuration context service used. This method is called when the OSGi
-     * ConfigurationContext Service is available.
-     *
-     * @param contextService the configuration context service.
-     */
-    protected void setConfigurationContextService(ConfigurationContextService contextService) {
-        try {
-            if (contextService.getServerConfigContext() != null &&
-                    contextService.getServerConfigContext().getAxisConfiguration() != null) {
-                contextService.getServerConfigContext().getAxisConfiguration().engageModule(
-                        "activation");
-            } else {
-                log.error("Failed to engage Activation Module.");
-            }
-        } catch (AxisFault e) {
-            log.error("Failed to engage Activation Module", e);
-        }
-    }
-
-    /**
-     * This method is called when the current configuration context service becomes un-available.
-     *
-     * @param contextService the current configuration context service instance, to be used for any
-     *                       cleaning-up.
-     */
-    protected void unsetConfigurationContextService(ConfigurationContextService contextService) {
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
deleted file mode 100644
index b2171cf..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationHandler.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.module;
-
-import javax.xml.namespace.QName;
-
-import org.apache.axiom.om.OMElement;
-import org.apache.axiom.soap.SOAPBody;
-import org.apache.axis2.AxisFault;
-import org.apache.axis2.context.MessageContext;
-import org.apache.axis2.description.AxisService;
-import org.apache.axis2.engine.Handler;
-import org.apache.axis2.handlers.AbstractHandler;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-import org.wso2.carbon.context.PrivilegedCarbonContext;
-import org.wso2.carbon.core.multitenancy.utils.TenantAxisUtils;
-import org.wso2.carbon.stratos.common.util.CloudServicesUtil;
-import org.wso2.carbon.utils.ServerConstants;
-import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
-import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
-
-public class ActivationHandler extends AbstractHandler implements Handler {
-
-    private static final Log log = LogFactory.getLog(ActivationHandler.class);
-
-    private String name = "ActivationHandler";
-
-    /**
-     * {@inheritDoc}
-     */
-    public InvocationResponse invoke(MessageContext messageContext) throws AxisFault {
-        String serviceName = Util.getServiceName();
-        //TODO - tenant id and domain should retrieve from thread local carbon context
-        //If service is api manager then we will pass activation handler check
-        if(serviceName.equalsIgnoreCase("WSO2 API Manager")) {
-            return InvocationResponse.CONTINUE;
-        }
-        if(log.isDebugEnabled()){
-            log.debug("Starting Activation Handler invocation. Incoming Message: " +
-                    messageContext.getEnvelope().toString());
-        }
-
-        AxisService service = messageContext.getAxisService();
-        int tenantId = getTenantId(messageContext);
-        if (service != null && "ActivationService".equals(service.getName())) {
-            log.debug("Granted access to the Activation Service");
-            if (tenantId > 0) {
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-            }
-            return InvocationResponse.CONTINUE;
-        }
-        if (tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            log.debug("Granted access for super tenant");
-            return InvocationResponse.CONTINUE;
-        }
-        if (ActivationManager.activationRecorded(tenantId)) {
-            if (ActivationManager.getActivation(tenantId)) {
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-                return InvocationResponse.CONTINUE;
-            } else {
-                if (log.isWarnEnabled()) {
-                    log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-                }
-                return InvocationResponse.ABORT;
-            }
-        }
-
-        try {
-            if (CloudServicesUtil.isCloudServiceActive(serviceName, tenantId)) {
-                log.debug("Successful attempt to access " + serviceName + " by tenant " + tenantId);
-                ActivationManager.setActivation(tenantId, true);
-                TenantAxisUtils.getTenantAxisConfiguration(getTenantDomain(messageContext),
-                        messageContext.getConfigurationContext());
-                log.debug("Loaded Tenant Configuration");
-                return InvocationResponse.CONTINUE;
-            }
-        } catch (Exception e) {
-            throw new AxisFault("Failed to determine Activation status.", e);
-        }
-        log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-        ActivationManager.setActivation(tenantId, false);
-        return InvocationResponse.ABORT;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Method to set the name of the activation handler.
-     *
-     * @param name the name.
-     */
-    @SuppressWarnings("unused")
-    public void setName(String name) {
-        this.name = name;
-    }
-
-    private String getTenantDomain(MessageContext messageContext) {
-        //Ideally this should take from thread local carbon context change this temporary
-        return PrivilegedCarbonContext.getCurrentContext(messageContext).getTenantDomain();
-    }
-
-    private int getTenantId(MessageContext messageContext) {
-        //Ideally this should take from thread local carbon context change this temporary
-        PrivilegedCarbonContext carbonContext =
-                PrivilegedCarbonContext.getCurrentContext(messageContext);
-        int tenantId = carbonContext.getTenantId();
-        if (tenantId > -1 || tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            return tenantId;
-        }
-        String domain = carbonContext.getTenantDomain();
-        if (domain == null) {
-            SOAPBody soapBody = messageContext.getEnvelope().getBody();
-            if (soapBody != null && soapBody.getFirstElement() != null) {
-                OMElement usernameElem = soapBody.getFirstElement().getFirstChildWithName(
-                        new QName(ServerConstants.AUTHENTICATION_SERVICE_NS,
-                                ServerConstants.AUTHENTICATION_SERVICE_USERNAME));
-                if (usernameElem != null) {
-                    String userName = usernameElem.getText();
-                    domain = MultitenantUtils.getTenantDomain(userName);
-                }
-            }
-        }
-        if (domain != null) {
-            try {
-                tenantId = Util.getRealmService().getTenantManager().getTenantId(domain);
-            } catch (org.wso2.carbon.user.api.UserStoreException e) {
-                log.error("An error occurred while obtaining the tenant id.", e);
-            }
-        }
-        return tenantId;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
deleted file mode 100644
index 9cfbee5..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/module/ActivationModule.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.module;
-
-import org.apache.axis2.AxisFault;
-import org.apache.axis2.context.ConfigurationContext;
-import org.apache.axis2.description.AxisDescription;
-import org.apache.axis2.description.AxisModule;
-import org.apache.axis2.modules.Module;
-import org.apache.neethi.Assertion;
-import org.apache.neethi.Policy;
-
-/**
- * Module used to engage the activation handler.
- */
-public class ActivationModule implements Module {
-
-    /**
-     * {@inheritDoc}
-     */
-    public void init(ConfigurationContext configurationContext, AxisModule axisModule)
-            throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void engageNotify(AxisDescription axisDescription) throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public boolean canSupportAssertion(Assertion assertion) {
-        return true;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void applyPolicy(Policy policy, AxisDescription axisDescription) throws AxisFault {
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public void shutdown(ConfigurationContext configurationContext) throws AxisFault {
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/service/ActivationService.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
deleted file mode 100644
index e16f2fb..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/service/ActivationService.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.service;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.activation.utils.ActivationManager;
-import org.wso2.carbon.activation.utils.Util;
-import org.wso2.carbon.stratos.common.config.CloudServiceConfigParser;
-import org.wso2.carbon.stratos.common.config.CloudServicesDescConfig;
-import org.wso2.carbon.stratos.common.util.CloudServicesUtil;
-import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
-
-/**
- * Admin Service to handle activation of cloud services used by tenants.
- */
-public class ActivationService {
-
-    private static final Log log = LogFactory.getLog(ActivationService.class);
-
-    /**
-     * Method to update an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @throws Exception if the operation failed.
-     */
-    public static void updateActivation(int tenantId) throws Exception {
-        if (tenantId != 0) {
-            String serviceName = Util.getServiceName();
-            boolean isActive = CloudServicesUtil.isCloudServiceActive(serviceName, tenantId);
-            CloudServicesDescConfig cloudServicesDesc =
-                                                        CloudServiceConfigParser.loadCloudServicesConfiguration();
-            CloudServicesUtil.setCloudServiceActive(!isActive,
-                                                    serviceName,
-                                                    tenantId,
-                                                    cloudServicesDesc.getCloudServiceConfigs()
-                                                                     .get(serviceName));
-            ActivationManager.setActivation(tenantId, !isActive);
-        }
-    }
-
-    /**
-     * Method to determine whether a service is active for the given tenant.
-     *
-     * @param tenantId tenantId the tenant identifier.
-     *
-     * @return whether the service is active.
-     * @throws Exception if the operation failed.
-     */
-    public boolean isActive(int tenantId) throws Exception {
-        if (tenantId == MultitenantConstants.SUPER_TENANT_ID) {
-            return true;
-        }
-        if (ActivationManager.activationRecorded(tenantId)) {
-            return ActivationManager.getActivation(tenantId);
-        }
-        String serviceName = Util.getServiceName();
-        if (CloudServicesUtil.isCloudServiceActive(serviceName, tenantId)) {
-            log.debug("Successful attempt to access " + serviceName + " by tenant " + tenantId);
-            ActivationManager.setActivation(tenantId, true);
-            return true;
-        }
-        log.warn("Failed attempt to access " + serviceName + " by tenant " + tenantId);
-        ActivationManager.setActivation(tenantId, false);
-        return false;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
deleted file mode 100644
index 41153a8..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/ActivationManager.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.utils;
-
-import java.util.Timer;
-import java.util.TimerTask;
-import java.util.concurrent.ConcurrentHashMap;
-
-/**
- * Manages Activations of Services for Tenants.
- */
-public class ActivationManager {
-
-    private static final ConcurrentHashMap<Integer, Boolean> activations =
-            new ConcurrentHashMap<Integer, Boolean>();
-    private static Timer timer = null;
-
-    /**
-     * Starts cleaning up cached activation records at periodic intervals.
-     */
-    public static void startCacheCleaner() {
-        TimerTask faultyServiceRectifier = new CacheCleaner();
-        timer = new Timer();
-        // Retry in 1 minute
-        long retryIn = 1000 * 60;
-        timer.schedule(faultyServiceRectifier, 0, retryIn);
-    }
-
-    /**
-     * Stops cleaning up cached activation records.
-     */
-    public static void stopCacheCleaner() {
-        timer.cancel();
-        timer = null;
-    }
-
-    /**
-     * Method to set an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     * @param status   true if the service is active or false if not.
-     */
-    public static void setActivation(int tenantId, boolean status) {
-        ActivationManager.activations.put(tenantId, status);
-    }
-
-    /**
-     * Method to check whether an activation record exists for the given tenant.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @return true if a record exists.
-     */
-    public static boolean activationRecorded(int tenantId) {
-        return ActivationManager.activations.get(tenantId) != null;
-    }
-
-    /**
-     * Method to retrieve an activation record.
-     *
-     * @param tenantId the tenant identifier.
-     *
-     * @return true if the service is active or false if not.
-     */
-    public static boolean getActivation(int tenantId) {
-        return ActivationManager.activations.get(tenantId) != null &&
-                ActivationManager.activations.get(tenantId);
-    }
-
-    private static class CacheCleaner extends TimerTask {
-
-        /**
-         * {@inheritDoc}
-         */
-        public void run() {
-            ActivationManager.activations.clear();
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/Util.java
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/Util.java b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/Util.java
deleted file mode 100644
index 9f01045..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/java/org/wso2/carbon/activation/utils/Util.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- *  Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- *
- *  WSO2 Inc. licenses this file to you under the Apache License,
- *  Version 2.0 (the "License"); you may not use this file except
- *  in compliance with the License.
- *  You may obtain a copy of the License at
- *
- *  http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.wso2.carbon.activation.utils;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.base.ServerConfiguration;
-import org.wso2.carbon.registry.core.exceptions.RegistryException;
-import org.wso2.carbon.registry.core.service.RegistryService;
-import org.wso2.carbon.registry.core.session.UserRegistry;
-import org.wso2.carbon.user.core.service.RealmService;
-
-/**
- * Utilities for the Service Activation Module for Tenants.
- */
-public class Util {
-
-    private static RegistryService registryService = null;
-    private static RealmService realmService = null;
-    private static String serviceName = null;
-    private static final Log log = LogFactory.getLog(Util.class);
-
-    private static boolean cloudServiceInfoPathSanityChecked = false;
-
-    /**
-     * Stores an instance of the Registry Service that can be used to access the registry.
-     *
-     * @param service the Registry Service instance.
-     */
-    public static synchronized void setRegistryService(RegistryService service) {
-        if (registryService == null) {
-            registryService = service;
-        }
-    }
-
-    /**
-     * Method to retrieve the Registry Service instance.
-     *
-     * @return the Registry Service instance if it has been stored or null if not.
-     */
-    @SuppressWarnings("unused")
-    public static RegistryService getRegistryService() {
-        return registryService;
-    }
-
-    /**
-     * Stores an instance of the Realm Service that can be used to access the user realm.
-     *
-     * @param service the Realm Service instance.
-     */
-    public static synchronized void setRealmService(RealmService service) {
-        if (realmService == null) {
-            realmService = service;
-        }
-    }
-
-    /**
-     * Method to retrieve the Realm Service instance.
-     *
-     * @return the Realm Service instance if it has been stored or null if not.
-     */
-    public static RealmService getRealmService() {
-        return realmService;
-    }
-
-    private static UserRegistry getSuperTenantGovernanceSystemRegistry() throws RegistryException {
-        return registryService.getGovernanceSystemRegistry();
-    }
-
-//    /**
-//     * Method to determine whether the given cloud service is active.
-//     *
-//     * @param cloudServiceName the name of the cloud service.
-//     * @param tenantId         the tenant identifier.
-//     * @param systemRegistry   the super tenant's governance system registry
-//     *
-//     * @return true if the service is active or false if not.
-//     * @throws Exception if the operation failed.
-//     */
-//    public static boolean isCloudServiceActive(String cloudServiceName,
-//                                               int tenantId, UserRegistry systemRegistry)
-//            throws Exception {
-//        // The cloud manager is always active
-//        if (StratosConstants.CLOUD_MANAGER_SERVICE.equals(cloudServiceName)) {
-//            return true;
-//        }
-//
-//        if(!cloudServiceInfoPathSanityChecked) {
-//            if(!systemRegistry.resourceExists(StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH)) {
-//                throw new RuntimeException("Cloud services list resource " +
-//                                           StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH + " does not exist");
-//            }
-//            cloudServiceInfoPathSanityChecked = true;
-//        }
-//
-//        String cloudServiceInfoPath = StratosConstants.CLOUD_SERVICE_INFO_STORE_PATH +
-//                RegistryConstants.PATH_SEPARATOR + tenantId +
-//                RegistryConstants.PATH_SEPARATOR + cloudServiceName;
-//        Resource cloudServiceInfoResource;
-//        if (systemRegistry.resourceExists(cloudServiceInfoPath)) {
-//            cloudServiceInfoResource = systemRegistry.get(cloudServiceInfoPath);
-//            String isActiveStr =
-//                cloudServiceInfoResource.getProperty(StratosConstants.CLOUD_SERVICE_IS_ACTIVE_PROP_KEY);
-//            return Boolean.toString(true).equals(isActiveStr);
-//        }
-//        return false;
-//    }
-//
-
-    /**
-     * Method to obtain the name of the cloud service in which this module is running.
-     *
-     * @return the name of the service as defined in the server configuration.
-     */
-    public static String getServiceName() {
-        if (serviceName == null) {
-            serviceName = ServerConfiguration.getInstance().getFirstProperty("Name");
-        }
-        return serviceName;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/module.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/module.xml b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/module.xml
deleted file mode 100644
index b92b725..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/module.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<!--
- ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- ~
- ~ WSO2 Inc. licenses this file to you under the Apache License,
- ~ Version 2.0 (the "License"); you may not use this file except
- ~ in compliance with the License.
- ~ You may obtain a copy of the License at
- ~
- ~    http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied.  See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
- -->
-<module name="activation" class="org.wso2.carbon.activation.module.ActivationModule">
-   <InFlow>
-        <handler name="InFlowActivationHandler"
-                 class="org.wso2.carbon.activation.module.ActivationHandler">
-        <order phase="Validation" phaseFirst="true"/>
-        </handler>
-   </InFlow>
-
-   <InFaultFlow>
-        <handler name="FaultInFlowActivationHandler"
-                 class="org.wso2.carbon.activation.module.ActivationHandler">
-        <order phase="Validation" phaseFirst="true"/>
-        </handler>
-   </InFaultFlow>
-  <parameter name="adminModule" locked="true">true</parameter>
-</module>

http://git-wip-us.apache.org/repos/asf/incubator-stratos/blob/6be46269/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/services.xml
----------------------------------------------------------------------
diff --git a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/services.xml b/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/services.xml
deleted file mode 100644
index dde74d7..0000000
--- a/components/stratos/org.wso2.carbon.activation/2.1.2/src/main/resources/META-INF/services.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- !
- ! Copyright (c) 2005-2009, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
- !
- ! WSO2 Inc. licenses this file to you under the Apache License,
- ! Version 2.0 (the "License"); you may not use this file except
- ! in compliance with the License.
- ! You may obtain a copy of the License at
- !
- ! http://www.apache.org/licenses/LICENSE-2.0
- !
- ! Unless required by applicable law or agreed to in writing,
- ! software distributed under the License is distributed on an
- ! "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ! KIND, either express or implied.  See the License for the
- ! specific language governing permissions and limitations
- ! under the License.
- !-->
-<serviceGroup>
-    <service name="ActivationService" scope="transportsession">
-        <transports>
-            <transport>https</transport>
-        </transports>
-        <parameter name="ServiceClass" locked="false">
-            org.wso2.carbon.activation.service.ActivationService
-        </parameter>
-    </service>
-    <parameter name="hiddenService" locked="true">true</parameter>
-</serviceGroup>
\ No newline at end of file