diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/pom.xml b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/pom.xml
similarity index 99%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/pom.xml
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/pom.xml
index 7332606e59a..ab6f88a5e37 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/pom.xml
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/pom.xml
@@ -46,7 +46,7 @@
maven-war-plugin
WEB-INF/lib/*cxf*.jar
- api#application-mgt#v1.0
+ api#application-mgt#v2.0
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/ApplicationManagementService.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/ApplicationManagementAPI.java
similarity index 95%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/ApplicationManagementService.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/ApplicationManagementAPI.java
index 1c7e44a7762..7a5d7be54e1 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/ApplicationManagementService.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/ApplicationManagementAPI.java
@@ -16,10 +16,10 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.api.services;
+package org.wso2.carbon.device.application.mgt.api.v2.apis;
import io.swagger.annotations.*;
-import org.wso2.carbon.device.application.mgt.api.beans.ErrorResponse;
+import org.wso2.carbon.device.application.mgt.api.v2.beans.ErrorResponse;
import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
import javax.ws.rs.*;
@@ -30,7 +30,7 @@ import javax.ws.rs.core.Response;
"such as get all the available devices, etc.")
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
-public interface ApplicationManagementService {
+public interface ApplicationManagementAPI {
public final static String SCOPE = "scope";
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/impl/ApplicationManagementServiceImpl.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/impl/ApplicationManagementAPIImpl.java
similarity index 89%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/impl/ApplicationManagementServiceImpl.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/impl/ApplicationManagementAPIImpl.java
index 95043e8c99b..49f8de3f8a4 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/services/impl/ApplicationManagementServiceImpl.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/apis/impl/ApplicationManagementAPIImpl.java
@@ -16,13 +16,13 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.api.services.impl;
+package org.wso2.carbon.device.application.mgt.api.v2.apis.impl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.device.application.mgt.core.components.ApplicationManager;
import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
import org.wso2.carbon.device.application.mgt.core.dto.Filter;
+import org.wso2.carbon.device.application.mgt.core.services.ApplicationManager;
import org.wso2.carbon.device.application.mgt.core.util.ApplicationManagementUtil;
import javax.ws.rs.*;
@@ -30,11 +30,11 @@ import javax.ws.rs.core.Response;
@Produces({ "application/json"})
@Consumes({ "application/json"})
-public class ApplicationManagementServiceImpl {
+public class ApplicationManagementAPIImpl {
public static final int DEFAULT_LIMIT = 20;
- private static Log log = LogFactory.getLog(ApplicationManagementServiceImpl.class);
+ private static Log log = LogFactory.getLog(ApplicationManagementAPIImpl.class);
@GET
@@ -42,7 +42,8 @@ public class ApplicationManagementServiceImpl {
@Path("applications")
public Response getApplications(@QueryParam("offset") int offset, @QueryParam("limit") int limit,
@QueryParam("q") String searchQuery) {
- ApplicationManager applicationManager = ApplicationManagementUtil.getApplicationManager();
+ ApplicationManager applicationManager = ApplicationManagementUtil.getApplicationManagementService();
+
try {
if(limit == 0){
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorListItem.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorListItem.java
similarity index 97%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorListItem.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorListItem.java
index e69f62c2cab..b120f18156c 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorListItem.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorListItem.java
@@ -16,7 +16,7 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.api.beans;
+package org.wso2.carbon.device.application.mgt.api.v2.beans;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorResponse.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorResponse.java
similarity index 98%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorResponse.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorResponse.java
index 0b648b52c60..253c848e02e 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/beans/ErrorResponse.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/beans/ErrorResponse.java
@@ -16,7 +16,7 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.api.beans;
+package org.wso2.carbon.device.application.mgt.api.v2.beans;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorHandler.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorHandler.java
similarity index 95%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorHandler.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorHandler.java
index 0b921d5ec1c..9564d90f09d 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorHandler.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorHandler.java
@@ -16,7 +16,7 @@
* under the License.
*/
-package org.wso2.carbon.device.application.mgt.api.common;
+package org.wso2.carbon.device.application.mgt.api.v2.common;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Response;
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorMessage.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorMessage.java
similarity index 94%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorMessage.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorMessage.java
index 1856305ab64..42cfb1f4d29 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/ErrorMessage.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/ErrorMessage.java
@@ -16,7 +16,7 @@
* under the License.
*/
-package org.wso2.carbon.device.application.mgt.api.common;
+package org.wso2.carbon.device.application.mgt.api.v2.common;
public class ErrorMessage {
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/GsonMessageBodyHandler.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/GsonMessageBodyHandler.java
similarity index 98%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/GsonMessageBodyHandler.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/GsonMessageBodyHandler.java
index 8789e25a3d3..ef8c4a8c702 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/GsonMessageBodyHandler.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/GsonMessageBodyHandler.java
@@ -16,7 +16,7 @@
* under the License.
*/
-package org.wso2.carbon.device.application.mgt.api.common;
+package org.wso2.carbon.device.application.mgt.api.v2.common;
import com.google.gson.Gson;
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/MDMAPIException.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/MDMAPIException.java
similarity index 95%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/MDMAPIException.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/MDMAPIException.java
index 4637c6f3ecd..def0093863d 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/java/org/wso2/carbon/device/application/mgt/api/common/MDMAPIException.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/java/org/wso2/carbon/device/application/mgt/api/v2/common/MDMAPIException.java
@@ -16,7 +16,7 @@
* under the License.
*/
-package org.wso2.carbon.device.application.mgt.api.common;
+package org.wso2.carbon.device.application.mgt.api.v2.common;
/**
* Custom exception class for handling CDM API related exceptions.
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/META-INF/permissions.xml b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/META-INF/permissions.xml
similarity index 100%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/META-INF/permissions.xml
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/META-INF/permissions.xml
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/META-INF/webapp-classloading.xml b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/META-INF/webapp-classloading.xml
similarity index 100%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/META-INF/webapp-classloading.xml
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/META-INF/webapp-classloading.xml
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/WEB-INF/cxf-servlet.xml b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/WEB-INF/cxf-servlet.xml
similarity index 85%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/WEB-INF/cxf-servlet.xml
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/WEB-INF/cxf-servlet.xml
index 65b5a921e7e..8cb974f5185 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/WEB-INF/cxf-servlet.xml
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/WEB-INF/cxf-servlet.xml
@@ -16,7 +16,7 @@ http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd">
-
-
+
+
\ No newline at end of file
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/WEB-INF/web.xml b/components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/WEB-INF/web.xml
similarity index 100%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.api/src/main/webapp/WEB-INF/web.xml
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.api.v2/src/main/webapp/WEB-INF/web.xml
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/internal/ApplicationManagementServiceComponent.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/internal/ApplicationManagementServiceComponent.java
index 41efc1b8c1d..5501e90fd2f 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/internal/ApplicationManagementServiceComponent.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/internal/ApplicationManagementServiceComponent.java
@@ -22,8 +22,8 @@ import org.apache.commons.logging.Log;
import org.osgi.service.component.ComponentContext;
import org.osgi.framework.BundleContext;
import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.device.application.mgt.core.components.ApplicationManager;
-import org.wso2.carbon.device.application.mgt.core.components.impl.ApplicationManagerImpl;
+import org.wso2.carbon.device.application.mgt.core.services.ApplicationManagementService;
+import org.wso2.carbon.device.application.mgt.core.services.impl.ApplicationManagementServiceImpl;
import org.wso2.carbon.device.application.mgt.core.config.ApplicationConfigurationManager;
import org.wso2.carbon.device.application.mgt.core.config.datasource.DataSourceConfig;
import org.wso2.carbon.device.application.mgt.core.dao.common.ApplicationManagementDAO;
@@ -33,7 +33,7 @@ import org.wso2.carbon.device.mgt.core.service.DeviceManagementProviderService;
import javax.naming.NamingException;
/**
- * @scr.component name="org.wso2.carbon.application.mgt" immediate="true"
+ * @scr.component name="org.wso2.carbon.application.mgt.service" immediate="true"
* @scr.reference name="org.wso2.carbon.device.manager"
* interface="org.wso2.carbon.device.mgt.core.service.DeviceManagementProviderService"
* cardinality="1..1"
@@ -49,8 +49,8 @@ public class ApplicationManagementServiceComponent {
protected void activate(ComponentContext componentContext) throws NamingException {
BundleContext bundleContext = componentContext.getBundleContext();
- bundleContext.registerService(ApplicationManager.class.getName(),
- ApplicationManagerImpl.getInstance(), null);
+ bundleContext.registerService(ApplicationManagementService.class.getName(),
+ ApplicationManagementServiceImpl.getInstance(), null);
DataSourceConfig dataSourceConfig = ApplicationConfigurationManager.getInstance()
@@ -73,14 +73,14 @@ public class ApplicationManagementServiceComponent {
protected void setDeviceManagementService(DeviceManagementProviderService deviceManagementProviderService) {
if (log.isDebugEnabled()) {
- log.debug("Setting Application Management OSGI Service");
+ log.debug("Setting Application Management OSGI Manager");
}
ApplicationManagementDataHolder.getInstance().setDeviceManagementService(deviceManagementProviderService);
}
protected void unsetDeviceManagementService(DeviceManagementProviderService deviceManagementProviderService) {
if (log.isDebugEnabled()) {
- log.debug("Removing Application Management OSGI Service");
+ log.debug("Removing Application Management OSGI Manager");
}
ApplicationManagementDataHolder.getInstance().setDeviceManagementService(null);
}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManagementService.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManagementService.java
new file mode 100644
index 00000000000..c6e890a7c2f
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManagementService.java
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+import org.wso2.carbon.device.application.mgt.core.dto.Application;
+import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
+import org.wso2.carbon.device.application.mgt.core.dto.Filter;
+import org.wso2.carbon.device.application.mgt.core.exception.ApplicationManagerException;
+
+public interface ApplicationManagementService extends ApplicationReleaseManager, ApplicationManager, CategoryManager,
+ CommentsManager, LifecycleStateManager, PlatformManager, ResourceTypeManager, SubscriptionManager,
+ VisibilityManager {
+
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/ApplicationManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManager.java
similarity index 80%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/ApplicationManager.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManager.java
index 086d564d39d..dbb57801b19 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/ApplicationManager.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationManager.java
@@ -16,17 +16,16 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.core.components;
+package org.wso2.carbon.device.application.mgt.core.services;
import org.wso2.carbon.device.application.mgt.core.dto.Application;
-import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
import org.wso2.carbon.device.application.mgt.core.dto.Filter;
+import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
import org.wso2.carbon.device.application.mgt.core.exception.ApplicationManagerException;
public interface ApplicationManager {
- public void createApplication(Application application) throws ApplicationManagerException;
-
- public ApplicationList getApplications(Filter filter) throws ApplicationManagerException;
+ void createApplication(Application application) throws ApplicationManagerException;
+ ApplicationList getApplications(Filter filter) throws ApplicationManagerException;
}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationReleaseManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationReleaseManager.java
new file mode 100644
index 00000000000..5d30f29fa69
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ApplicationReleaseManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface ApplicationReleaseManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CategoryManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CategoryManager.java
new file mode 100644
index 00000000000..08621f19fef
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CategoryManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface CategoryManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CommentsManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CommentsManager.java
new file mode 100644
index 00000000000..d0c04cfc7ce
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/CommentsManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface CommentsManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/LifecycleStateManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/LifecycleStateManager.java
new file mode 100644
index 00000000000..a09d7475b4a
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/LifecycleStateManager.java
@@ -0,0 +1,23 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface LifecycleStateManager {
+
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/PlatformManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/PlatformManager.java
new file mode 100644
index 00000000000..9b90516d56d
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/PlatformManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface PlatformManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ResourceTypeManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ResourceTypeManager.java
new file mode 100644
index 00000000000..582e2b30b7c
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/ResourceTypeManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface ResourceTypeManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/SubscriptionManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/SubscriptionManager.java
new file mode 100644
index 00000000000..074292d031c
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/SubscriptionManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface SubscriptionManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/VisibilityManager.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/VisibilityManager.java
new file mode 100644
index 00000000000..a83435cec22
--- /dev/null
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/VisibilityManager.java
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2017, 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.device.application.mgt.core.services;
+
+public interface VisibilityManager {
+}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/impl/ApplicationManagerImpl.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/impl/ApplicationManagementServiceImpl.java
similarity index 79%
rename from components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/impl/ApplicationManagerImpl.java
rename to components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/impl/ApplicationManagementServiceImpl.java
index 20fd44a346f..a4ab9f7e204 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/components/impl/ApplicationManagerImpl.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/services/impl/ApplicationManagementServiceImpl.java
@@ -16,11 +16,11 @@
* under the License.
*
*/
-package org.wso2.carbon.device.application.mgt.core.components.impl;
+package org.wso2.carbon.device.application.mgt.core.services.impl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.wso2.carbon.device.application.mgt.core.components.ApplicationManager;
+import org.wso2.carbon.device.application.mgt.core.services.ApplicationManagementService;
import org.wso2.carbon.device.application.mgt.core.dao.common.ApplicationManagementDAO;
import org.wso2.carbon.device.application.mgt.core.dto.Application;
import org.wso2.carbon.device.application.mgt.core.dto.lists.ApplicationList;
@@ -29,18 +29,18 @@ import org.wso2.carbon.device.application.mgt.core.exception.ApplicationManagerE
import org.wso2.carbon.device.application.mgt.core.internal.ApplicationManagementDataHolder;
import org.wso2.carbon.device.application.mgt.core.util.ConnectionManagerUtil;
-public class ApplicationManagerImpl implements ApplicationManager {
+public class ApplicationManagementServiceImpl implements ApplicationManagementService {
- private static final Log log = LogFactory.getLog(ApplicationManagerImpl.class);
+ private static final Log log = LogFactory.getLog(ApplicationManagementServiceImpl.class);
- private static ApplicationManagerImpl applicationManager = new ApplicationManagerImpl();
+ private static ApplicationManagementServiceImpl applicationManager = new ApplicationManagementServiceImpl();
- private ApplicationManagerImpl() {
+ private ApplicationManagementServiceImpl() {
}
- public static ApplicationManagerImpl getInstance() {
+ public static ApplicationManagementServiceImpl getInstance() {
return applicationManager;
}
diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/util/ApplicationManagementUtil.java b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/util/ApplicationManagementUtil.java
index 103cf97c7d6..55626599b2d 100644
--- a/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/util/ApplicationManagementUtil.java
+++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.core/src/main/java/org/wso2/carbon/device/application/mgt/core/util/ApplicationManagementUtil.java
@@ -23,7 +23,7 @@ import org.apache.commons.logging.LogFactory;
import org.w3c.dom.Document;
import org.wso2.carbon.context.CarbonContext;
import org.wso2.carbon.context.PrivilegedCarbonContext;
-import org.wso2.carbon.device.application.mgt.core.components.ApplicationManager;
+import org.wso2.carbon.device.application.mgt.core.services.ApplicationManagementService;
import org.wso2.carbon.device.application.mgt.core.exception.ApplicationManagerException;
import javax.xml.XMLConstants;
@@ -35,10 +35,10 @@ public class ApplicationManagementUtil {
private static Log log = LogFactory.getLog(ApplicationManagementUtil.class);
- public static ApplicationManager getApplicationManager() {
+ public static ApplicationManagementService getApplicationManagementService() {
PrivilegedCarbonContext ctx = PrivilegedCarbonContext.getThreadLocalCarbonContext();
- ApplicationManager applicationManager =
- (ApplicationManager) CarbonContext.getThreadLocalCarbonContext().getOSGiService(ApplicationManager.class, null);
+ ApplicationManagementService applicationManager =
+ (ApplicationManagementService) CarbonContext.getThreadLocalCarbonContext().getOSGiService(ApplicationManagementService.class, null);
if (applicationManager == null) {
String msg = "Application Management provider service has not initialized.";
log.error(msg);
diff --git a/components/application-mgt/pom.xml b/components/application-mgt/pom.xml
index 1823e25fbb7..a6560954a3c 100644
--- a/components/application-mgt/pom.xml
+++ b/components/application-mgt/pom.xml
@@ -36,7 +36,7 @@
org.wso2.carbon.device.application.mgt.core
- org.wso2.carbon.device.application.mgt.api
+ org.wso2.carbon.device.application.mgt.api.v2