From d6373255902d76851d8d3aa234d23cd0d0854eeb Mon Sep 17 00:00:00 2001 From: NuwanSameera Date: Thu, 31 Mar 2016 17:06:25 +0530 Subject: [PATCH 1/2] Add db scripts to mssql, oracle, postgresql databases. --- .../service/impl/VirtualFireAlarmManagerService.java | 12 ++++++------ .../src/main/resources/dbscripts/h2.sql | 3 --- .../src/main/resources/dbscripts/mssql.sql | 8 ++++++++ .../src/main/resources/dbscripts/oracle.sql | 8 ++++++++ .../src/main/resources/dbscripts/postgresql.sql | 8 ++++++++ .../src/main/resources/dbscripts/h2.sql | 3 --- .../src/main/resources/dbscripts/mssql.sql | 8 ++++++++ .../src/main/resources/dbscripts/oracle.sql | 8 ++++++++ .../src/main/resources/dbscripts/postgresql.sql | 8 ++++++++ .../src/main/resources/dbscripts/h2.sql | 3 --- .../src/main/resources/dbscripts/mssql.sql | 8 ++++++++ .../src/main/resources/dbscripts/oracle.sql | 8 ++++++++ .../src/main/resources/dbscripts/postgresql.sql | 8 ++++++++ .../src/main/resources/dbscripts/h2.sql | 2 -- .../src/main/resources/dbscripts/mssql.sql | 9 +++++++++ .../src/main/resources/dbscripts/oracle.sql | 9 +++++++++ .../src/main/resources/dbscripts/postgresql.sql | 9 +++++++++ .../src/main/resources/dbscripts/h2.sql | 2 -- .../src/main/resources/dbscripts/mssql.sql | 9 +++++++++ .../src/main/resources/dbscripts/oracle.sql | 9 +++++++++ .../src/main/resources/dbscripts/postgresql.sql | 9 +++++++++ .../src/main/resources/dbscripts/h2.sql | 3 --- .../src/main/resources/dbscripts/mssql.sql | 8 ++++++++ .../src/main/resources/dbscripts/oracle.sql | 8 ++++++++ .../src/main/resources/dbscripts/postgresql.sql | 8 ++++++++ 25 files changed, 156 insertions(+), 22 deletions(-) create mode 100644 features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/postgresql.sql create mode 100644 features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/postgresql.sql create mode 100644 features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/postgresql.sql create mode 100644 features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/postgresql.sql create mode 100644 features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/postgresql.sql create mode 100644 features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/mssql.sql create mode 100644 features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/oracle.sql create mode 100644 features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/postgresql.sql diff --git a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.api/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/service/impl/VirtualFireAlarmManagerService.java b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.api/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/service/impl/VirtualFireAlarmManagerService.java index 9f89af761..e8117619c 100644 --- a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.api/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/service/impl/VirtualFireAlarmManagerService.java +++ b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.api/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/service/impl/VirtualFireAlarmManagerService.java @@ -36,34 +36,34 @@ import javax.ws.rs.core.Response; @DeviceType(value = "virtual_firealarm") public interface VirtualFireAlarmManagerService { - @Path("manager/device/{device_id}") + @Path("devices/{device_id}") @DELETE Response removeDevice(@PathParam("device_id") String deviceId); - @Path("manager/device/{device_id}") + @Path("devices/{device_id}") @PUT Response updateDevice(@PathParam("device_id") String deviceId, @QueryParam("name") String name); - @Path("manager/device/{device_id}") + @Path("devices/{device_id}") @GET @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) Response getDevice(@PathParam("device_id") String deviceId); - @Path("manager/devices") + @Path("devices") @GET @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) Response getFirealarmDevices(); - @Path("manager/device/{sketch_type}/download") + @Path("devices/{sketch_type}/download") @GET @Produces(MediaType.APPLICATION_JSON) Response downloadSketch(@QueryParam("deviceName") String deviceName, @PathParam("sketch_type") String sketchType); - @Path("manager/device/{sketch_type}/generate_link") + @Path("devices/{sketch_type}/generate_link") @GET Response generateSketchLink(@QueryParam("deviceName") String deviceName, @PathParam("sketch_type") String sketchType); diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/h2.sql index 218cdbf05..ee3bfa73a 100644 --- a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/h2.sql @@ -6,6 +6,3 @@ CREATE TABLE IF NOT EXISTS `ANDROID_SENSE_DEVICE` ( `ANDROID_DEVICE_ID` VARCHAR(45) NOT NULL , `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`ANDROID_DEVICE_ID`) ); - - - diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..cf677ff07 --- /dev/null +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `ANDROID_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ANDROID_SENSE_DEVICE ( + ANDROID_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ANDROID_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..cf677ff07 --- /dev/null +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `ANDROID_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ANDROID_SENSE_DEVICE ( + ANDROID_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ANDROID_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..987f4992b --- /dev/null +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `ANDROID_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ANDROID_SENSE_DEVICE ( + ANDROID_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ANDROID_DEVICE_ID)); diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/h2.sql index 2e9bc926b..7d5b98b72 100644 --- a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/h2.sql @@ -6,6 +6,3 @@ CREATE TABLE IF NOT EXISTS `ARDUINO_DEVICE` ( `ARDUINO_DEVICE_ID` VARCHAR(45) NOT NULL , `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`ARDUINO_DEVICE_ID`) ); - - - diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..e966d462a --- /dev/null +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table for `ARDUINO_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ARDUINO_DEVICE ( + ARDUINO_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ARDUINO_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..e966d462a --- /dev/null +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table for `ARDUINO_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ARDUINO_DEVICE ( + ARDUINO_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ARDUINO_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..e966d462a --- /dev/null +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table for `ARDUINO_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS ARDUINO_DEVICE ( + ARDUINO_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (ARDUINO_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/h2.sql index 5bf6884c5..ab31bf6e1 100644 --- a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/h2.sql @@ -6,6 +6,3 @@ CREATE TABLE IF NOT EXISTS `DIGITAL_DISPLAY_DEVICE` ( `DIGITAL_DISPLAY_DEVICE_ID` VARCHAR(45) NOT NULL , `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DIGITAL_DISPLAY_DEVICE_ID`) ); - - - diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..3828224d0 --- /dev/null +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `DIGITAL_DISPLAY_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DIGITAL_DISPLAY_DEVICE ( + DIGITAL_DISPLAY_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DIGITAL_DISPLAY_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..3828224d0 --- /dev/null +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `DIGITAL_DISPLAY_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DIGITAL_DISPLAY_DEVICE ( + DIGITAL_DISPLAY_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DIGITAL_DISPLAY_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..3828224d0 --- /dev/null +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `DIGITAL_DISPLAY_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DIGITAL_DISPLAY_DEVICE ( + DIGITAL_DISPLAY_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DIGITAL_DISPLAY_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/h2.sql index f7dac408b..5dc50ce21 100644 --- a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/h2.sql @@ -7,5 +7,3 @@ CREATE TABLE IF NOT EXISTS `DRONE_DEVICE` ( `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DRONE_DEVICE_ID`) ); - - diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..4dca78f70 --- /dev/null +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `DRONE_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DRONE_DEVICE ( + DRONE_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DRONE_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..4dca78f70 --- /dev/null +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `DRONE_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DRONE_DEVICE ( + DRONE_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DRONE_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..4dca78f70 --- /dev/null +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `DRONE_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS DRONE_DEVICE ( + DRONE_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (DRONE_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/h2.sql index aead055a4..67e702ec9 100644 --- a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/h2.sql @@ -7,5 +7,3 @@ CREATE TABLE IF NOT EXISTS `RASPBERRYPI_DEVICE` ( `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`RASPBERRYPI_DEVICE_ID`) ); - - diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..a944f4cb2 --- /dev/null +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `RASPBERRYPI_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS RASPBERRYPI_DEVICE ( + RASPBERRYPI_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (RASPBERRYPI_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..a944f4cb2 --- /dev/null +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `RASPBERRYPI_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS RASPBERRYPI_DEVICE ( + RASPBERRYPI_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (RASPBERRYPI_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..a944f4cb2 --- /dev/null +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,9 @@ + +-- ----------------------------------------------------- +-- Table `RASPBERRYPI_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS RASPBERRYPI_DEVICE ( + RASPBERRYPI_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (RASPBERRYPI_DEVICE_ID) ); + diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/h2.sql b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/h2.sql index 340ba6a70..160b437cb 100644 --- a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/h2.sql +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/h2.sql @@ -6,6 +6,3 @@ CREATE TABLE IF NOT EXISTS `VIRTUAL_FIREALARM_DEVICE` ( `VIRTUAL_FIREALARM_DEVICE_ID` VARCHAR(45) NOT NULL , `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`VIRTUAL_FIREALARM_DEVICE_ID`) ); - - - diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/mssql.sql b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/mssql.sql new file mode 100644 index 000000000..41b7e4848 --- /dev/null +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/mssql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `FIREALARM_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS VIRTUAL_FIREALARM_DEVICE ( + VIRTUAL_FIREALARM_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (VIRTUAL_FIREALARM_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/oracle.sql b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/oracle.sql new file mode 100644 index 000000000..41b7e4848 --- /dev/null +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/oracle.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `FIREALARM_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS VIRTUAL_FIREALARM_DEVICE ( + VIRTUAL_FIREALARM_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (VIRTUAL_FIREALARM_DEVICE_ID) ); diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/postgresql.sql b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/postgresql.sql new file mode 100644 index 000000000..41b7e4848 --- /dev/null +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/dbscripts/postgresql.sql @@ -0,0 +1,8 @@ + +-- ----------------------------------------------------- +-- Table `FIREALARM_DEVICE` +-- ----------------------------------------------------- +CREATE TABLE IF NOT EXISTS VIRTUAL_FIREALARM_DEVICE ( + VIRTUAL_FIREALARM_DEVICE_ID VARCHAR(45) NOT NULL , + DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + PRIMARY KEY (VIRTUAL_FIREALARM_DEVICE_ID) ); From 273305a67cc6880e7b9df8e45556de03f43e7afa Mon Sep 17 00:00:00 2001 From: NuwanSameera Date: Mon, 11 Apr 2016 16:02:53 +0530 Subject: [PATCH 2/2] Add feature Uninstall to all device types. --- .../pom.xml | 2 +- .../src/main/resources/p2.inf | 10 ++++++++++ .../pom.xml | 2 +- .../src/main/resources/p2.inf | 11 +++++++++++ .../pom.xml | 2 +- .../src/main/resources/p2.inf | 11 +++++++++++ .../pom.xml | 2 +- .../src/main/resources/p2.inf | 12 ++++++++++++ .../pom.xml | 2 +- .../src/main/resources/p2.inf | 11 +++++++++++ .../pom.xml | 2 +- .../src/main/resources/p2.inf | 14 ++++++++++++++ 12 files changed, 75 insertions(+), 6 deletions(-) diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/pom.xml b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/pom.xml index d5e1b378f..ee4ae5ddd 100644 --- a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/pom.xml +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/pom.xml @@ -197,7 +197,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/p2.inf index 840e414d6..7790b5b36 100644 --- a/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/androidsense-plugin-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/p2.inf @@ -15,3 +15,13 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.androidsense_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/android_sense.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/android_sense.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/android_sense);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/android_sense);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/android_sense);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/androidsense-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/AndroidSenseDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android_sense.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android_sense.type-view);\ diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/pom.xml b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/pom.xml index a3c706701..be2c6a848 100644 --- a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/pom.xml +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/pom.xml @@ -198,7 +198,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/p2.inf index ef0ff6ae9..557c3872d 100644 --- a/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/arduino-plugin-feature/org.wso2.carbon.device.mgt.iot.arduino.feature/src/main/resources/p2.inf @@ -12,3 +12,14 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.arduino_${feature.version}/datasources/,target:${installFolder}/../../conf/datasources/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.arduino_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ + +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/arduino.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/arduino.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/arduino);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/arduino);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/arduino);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/arduino-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/ArduinoDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.arduino.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.arduino.type-view);\ diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/pom.xml b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/pom.xml index 9501c2e37..32648f135 100644 --- a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/pom.xml +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/pom.xml @@ -188,7 +188,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/p2.inf index d248d6295..9058c8508 100644 --- a/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/digital-display-plugin-feature/org.wso2.carbon.device.mgt.iot.digitaldisplay.feature/src/main/resources/p2.inf @@ -12,3 +12,14 @@ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../depl org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.digitaldisplay_${feature.version}/jaggeryapps/,target:${installFolder}/../../deployment/server/jaggeryapps/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.digitaldisplay_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ + +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/digital_display.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/digital_display.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/digital_display);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/digital_display);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/digital_display);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/digitaldisplay-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/DigitalDisplayDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.digital_display.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.digital_display.type-view);\ diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/pom.xml b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/pom.xml index 03a1dbf1c..6d6192e7c 100644 --- a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/pom.xml +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/pom.xml @@ -185,7 +185,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/p2.inf index 420a62ee2..f7a86fb71 100644 --- a/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/drone-analyzer-plugin-feature/org.wso2.carbon.device.mgt.iot.droneanalyzer.feature/src/main/resources/p2.inf @@ -12,3 +12,15 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.droneanalyzer_${feature.version}/datasources/,target:${installFolder}/../../conf/datasources/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.droneanalyzer_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ + +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/drone_analyzer.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/drone_analyzer.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/drone_analyzer.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/drone_analyzer);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/drone_analyzer);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/drone_analyzer);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/drone_analyzer-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/DroneAnalyzerDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.drone_analyzer.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.drone_analyzer.type-view);\ diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/pom.xml b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/pom.xml index 5c6f210e0..73b04661b 100644 --- a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/pom.xml +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/pom.xml @@ -197,7 +197,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/p2.inf index 97d22ac40..f1eefb1a9 100644 --- a/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/raspberrypi-plugin-feature/org.wso2.carbon.device.mgt.iot.raspberrypi.feature/src/main/resources/p2.inf @@ -12,3 +12,14 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.raspberrypi_${feature.version}/datasources/,target:${installFolder}/../../conf/datasources/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.raspberrypi_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ + +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/raspberrypi.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/raspberrypi.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/raspberrypi);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/raspberrypi);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/raspberrypi);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/raspberrypi-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/RaspberryPiDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.raspberrypi.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.raspberrypi.type-view);\ diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/pom.xml b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/pom.xml index a64bb38ba..7a8fe13d1 100644 --- a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/pom.xml +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/pom.xml @@ -226,7 +226,7 @@ org.wso2.carbon.p2.category.type:server - org.eclipse.equinox.p2.type.group:false + org.eclipse.equinox.p2.type.group:true diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf index 7711271ef..a229ebc62 100644 --- a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf @@ -16,3 +16,17 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.virtualfirealarm_${feature.version}/datasources/,target:${installFolder}/../../conf/datasources/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.virtualfirealarm_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ + +instructions.unconfigure = \ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/virtual_firealarm.json);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/virtual_firealarm.war);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/webapps/virtual_firealarm);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../../dbscripts/cdm/plugins/virtual_firealarm);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/virtual_firealarm);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/sketches/virtual_firealarm_advanced);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/datasources/virtual_firealarm-datasources.xml);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../database/VirtualFireAlarmDM_DB.h2.db);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.device-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.type-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.policy-edit);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.policy-view);\