diff --git a/components/iot-plugins/iot-base-plugin/org.wso2.carbon.device.mgt.iot.input.adapter.extension/pom.xml b/components/iot-plugins/iot-base-plugin/org.wso2.carbon.device.mgt.iot.input.adapter.extension/pom.xml index 170176ad7d..9d5353c6cb 100644 --- a/components/iot-plugins/iot-base-plugin/org.wso2.carbon.device.mgt.iot.input.adapter.extension/pom.xml +++ b/components/iot-plugins/iot-base-plugin/org.wso2.carbon.device.mgt.iot.input.adapter.extension/pom.xml @@ -53,5 +53,4 @@ - \ No newline at end of file diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/pom.xml b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/pom.xml index 9841815edf..acae2dc47e 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/pom.xml +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/pom.xml @@ -35,6 +35,10 @@ + + org.apache.maven.plugins + maven-compiler-plugin + org.apache.felix maven-scr-plugin diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/impl/android/gcm/GCMUtil.java b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/impl/android/gcm/GCMUtil.java index 19f594bc83..d051b16469 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/impl/android/gcm/GCMUtil.java +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/impl/android/gcm/GCMUtil.java @@ -27,6 +27,7 @@ import org.wso2.carbon.device.mgt.common.DeviceManagementException; import org.wso2.carbon.device.mgt.common.configuration.mgt.ConfigurationEntry; import org.wso2.carbon.device.mgt.common.configuration.mgt.TenantConfiguration; import org.wso2.carbon.device.mgt.common.spi.DeviceManagementService; +import org.wso2.carbon.device.mgt.mobile.impl.android.AndroidDeviceManagementService; import org.wso2.carbon.device.mgt.mobile.impl.android.util.AndroidPluginConstants; import org.wso2.carbon.device.mgt.mobile.internal.MobileDeviceManagementDataHolder; @@ -153,12 +154,12 @@ public class GCMUtil { } public static String getConfigurationProperty(String property) { - DeviceManagementService androidDMService = MobileDeviceManagementDataHolder.getInstance(). - getAndroidDeviceManagementService(); + DeviceManagementService androidDMService = new AndroidDeviceManagementService(); try { //Get the TenantConfiguration from cache if not we'll get it from DM service TenantConfiguration tenantConfiguration = getTenantConfigurationFromCache(); if (tenantConfiguration == null) { + androidDMService.init(); tenantConfiguration = androidDMService.getDeviceManager().getConfiguration(); if (tenantConfiguration != null) { addTenantConfigurationToCache(tenantConfiguration); diff --git a/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.adapter.feature/pom.xml b/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.adapter.feature/pom.xml index 79a61d850f..61b6faacca 100644 --- a/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.adapter.feature/pom.xml +++ b/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.adapter.feature/pom.xml @@ -18,164 +18,179 @@ ~ under the License. --> - + - - org.wso2.carbon.devicemgt-plugins - iot-base-plugin-feature - 2.1.1-SNAPSHOT - ../pom.xml - + + org.wso2.carbon.devicemgt-plugins + iot-base-plugin-feature + 2.1.1-SNAPSHOT + ../pom.xml + - 4.0.0 - org.wso2.carbon.device.mgt.iot.adapter.feature - pom - 2.1.1-SNAPSHOT - WSO2 Carbon - IoT Device Management Feature - http://wso2.org - This feature contains the adapter bundles required for IoT Server + 4.0.0 + org.wso2.carbon.device.mgt.iot.adapter.feature + pom + 2.1.1-SNAPSHOT + WSO2 Carbon - IoT Device Management Feature + http://wso2.org + This feature contains the adapter bundles required for IoT Server - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.output.adapter.mqtt - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.output.adapter.xmpp - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.output.adapter.ui - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.input.adapter.extension - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.input.adapter.http - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.input.adapter.mqtt - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.input.adapter.xmpp - - + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.output.adapter.mqtt + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.output.adapter.xmpp + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.output.adapter.ui + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.input.adapter.extension + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.input.adapter.http + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.input.adapter.mqtt + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.input.adapter.xmpp + + - - - - org.apache.maven.plugins - maven-dependency-plugin - - - copy - package - - copy - - - - - org.wso2.carbon.devicemgt-plugins - org.wso2.carbon.device.mgt.iot.output.adapter.ui.endpoint - ${carbon.devicemgt.plugins.version} - war - true - ${project.build.directory}/maven-shared-archive-resources/webapps/ - secured-outputui.war - - - - - - - - maven-resources-plugin - - - copy-resources - generate-resources - - copy-resources - - - src/main/resources - - - resources - - build.properties - p2.inf - - - - - - - - - org.wso2.maven - carbon-p2-plugin - ${carbon.p2.plugin.version} - - - p2-feature-generation - package - - p2-feature-gen - - - org.wso2.carbon.device.mgt.iot.adapter - ../../../features/etc/feature.properties - - - org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false - - - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.mqtt:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.xmpp:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.extension:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.http:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.mqtt:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.xmpp:${carbon.devicemgt.plugins.version} - - - org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.ui:${carbon.devicemgt.plugins.version} - - - - - org.wso2.carbon.event.output.adapter.server:${carbon.analytics.common.version} - - - org.wso2.carbon.event.input.adapter.server:${carbon.analytics.common.version} - - - org.wso2.carbon.identity.jwt.client.extension:${carbon.devicemgt.version} - - - - - - - - + + + + org.apache.maven.plugins + maven-dependency-plugin + + + copy + package + + copy + + + + + org.wso2.carbon.devicemgt-plugins + org.wso2.carbon.device.mgt.iot.output.adapter.ui.endpoint + ${carbon.devicemgt.plugins.version} + war + true + + ${project.build.directory}/maven-shared-archive-resources/webapps/ + + secured-outputui.war + + + + + + + + maven-resources-plugin + + + copy-resources + generate-resources + + copy-resources + + + src/main/resources + + + resources + + build.properties + p2.inf + + + + + + + + + org.wso2.maven + carbon-p2-plugin + ${carbon.p2.plugin.version} + + + p2-feature-generation + package + + p2-feature-gen + + + org.wso2.carbon.device.mgt.iot.adapter + ../../../features/etc/feature.properties + + + org.wso2.carbon.p2.category.type:server + org.eclipse.equinox.p2.type.group:false + + + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.mqtt:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.xmpp:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.extension:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.http:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.mqtt:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.input.adapter.xmpp:${carbon.devicemgt.plugins.version} + + + org.wso2.carbon.devicemgt-plugins:org.wso2.carbon.device.mgt.iot.output.adapter.ui:${carbon.devicemgt.plugins.version} + + + org.eclipse.paho:org.eclipse.paho.client.mqttv3:${eclipse.paho.version} + + + org.igniterealtime.smack.wso2:smack:${smack.wso2.version} + + + org.igniterealtime.smack.wso2:smackx:${smackx.wso2.version} + + + org.wso2.carbon.identity:org.wso2.carbon.identity.oauth.stub:${carbon.identity.version} + + + + + org.wso2.carbon.event.output.adapter.server:${carbon.analytics.common.version} + + + org.wso2.carbon.event.input.adapter.server:${carbon.analytics.common.version} + + + org.wso2.carbon.identity.jwt.client.extension:${carbon.devicemgt.version} + + + + + + + + diff --git a/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.feature/pom.xml b/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.feature/pom.xml index d29cfb369f..950d6d84df 100644 --- a/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.feature/pom.xml +++ b/features/iot-plugins-feature/iot-base-plugin-feature/org.wso2.carbon.device.mgt.iot.feature/pom.xml @@ -137,15 +137,6 @@ org.json.wso2:json:${commons-json.version} - - org.eclipse.paho:org.eclipse.paho.client.mqttv3:${eclipse.paho.version} - - - org.igniterealtime.smack.wso2:smack:${smack.wso2.version} - - - org.igniterealtime.smack.wso2:smackx:${smackx.wso2.version} - org.wso2.carbon.core.server:${carbon.kernel.version} diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/p2.inf b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/p2.inf index 9c79e2fbd7..349c097852 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/p2.inf +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/p2.inf @@ -1,6 +1,5 @@ instructions.configure = \ -org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../deployment/server/webapps/);\ -org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.mobile.android_${feature.version}/webapps/,target:${installFolder}/../../deployment/server/webapps/,overwrite:true);\ +org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.mobile.android_${feature.version}/webapps/mdm-android-agent.war,target:${installFolder}/../../deployment/server/webapps/mdm-android-agent.war,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.mobile.android_${feature.version}/jaggeryapps/,target:${installFolder}/../../deployment/server/jaggeryapps/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.mobile.android_${feature.version}/conf/mobile-config.xml,target:${installFolder}/../../conf/mobile-config.xml,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.mobile.android_${feature.version}/dbscripts/plugins/,target:${installFolder}/../../../dbscripts/cdm/plugins/android,overwrite:true);\