forked from community/device-mgt-plugins
parent
657178a829
commit
b2d283eb8f
@ -1,28 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!--
|
|
||||||
~ Copyright (c) 2016, 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.
|
|
||||||
-->
|
|
||||||
|
|
||||||
<artifacts>
|
|
||||||
<artifact name="temperature" version="1.0.0" type="carbon/application">
|
|
||||||
<dependency artifact="temperature_stream" version="1.0.0" include="true" serverRole="DataAnalyticsServer"/>
|
|
||||||
<dependency artifact="temperature_store" version="1.0.0" include="true" serverRole="DataAnalyticsServer"/>
|
|
||||||
<dependency artifact="temperature_receiver" version="1.0.0" include="true" serverRole="DataAnalyticsServer"/>
|
|
||||||
<dependency artifact="temperature_publisher" version="1.0.0" include="true" serverRole="DataAnalyticsServer"/>
|
|
||||||
<dependency artifact="temperature_script" version="1.0.0" include="true" serverRole="DataAnalyticsServer"/>
|
|
||||||
</artifact>
|
|
||||||
</artifacts>
|
|
@ -1,22 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!--
|
|
||||||
~ Copyright (c) 2016, 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.
|
|
||||||
-->
|
|
||||||
|
|
||||||
<artifact name="temperature_receiver" version="1.0.0" type="event/receiver" serverRole="DataAnalyticsServer">
|
|
||||||
<file>temperature_receiver.xml</file>
|
|
||||||
</artifact>
|
|
@ -1,26 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!--
|
|
||||||
~ Copyright (c) 2016, 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.
|
|
||||||
-->
|
|
||||||
|
|
||||||
<eventReceiver name="temperature_receiver" statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventreceiver">
|
|
||||||
<from eventAdapterType="wso2event">
|
|
||||||
<property name="events.duplicated.in.cluster">false</property>
|
|
||||||
</from>
|
|
||||||
<mapping customMapping="disable" type="wso2event"/>
|
|
||||||
<to streamName="org.wso2.iot.devices.temperature" version="1.0.0"/>
|
|
||||||
</eventReceiver>
|
|
@ -1,22 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!--
|
|
||||||
~ Copyright (c) 2016, 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.
|
|
||||||
-->
|
|
||||||
|
|
||||||
<artifact name="temperature_script" version="1.0.0" type="analytics/spark" serverRole="DataAnalyticsServer">
|
|
||||||
<file>temperature_script.xml</file>
|
|
||||||
</artifact>
|
|
@ -1,30 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
||||||
<!--
|
|
||||||
~ Copyright (c) 2016, 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.
|
|
||||||
-->
|
|
||||||
|
|
||||||
<Analytics>
|
|
||||||
<Name>temperature_script</Name>
|
|
||||||
<Script>
|
|
||||||
CREATE TEMPORARY TABLE DeviceTemperatureData USING CarbonAnalytics OPTIONS(tableName "ORG_WSO2_IOT_DEVICES_TEMPERATURE");
|
|
||||||
|
|
||||||
CREATE TEMPORARY TABLE DeviceTemperatureSummaryData USING CarbonAnalytics OPTIONS (tableName "DEVICE_TEMPERATURE_SUMMARY", schema "temperature FLOAT, deviceType STRING -i, deviceId STRING -i, owner STRING -i, time LONG -i",primaryKeys "deviceType, deviceId, owner, time");
|
|
||||||
|
|
||||||
insert into table DeviceTemperatureSummaryData select temperature, meta_deviceType as deviceType, meta_deviceId as deviceId, meta_owner as owner, cast(meta_time/1000 as BIGINT)as time from DeviceTemperatureData group by temperature, meta_deviceType, meta_deviceId, meta_owner, cast(meta_time/1000 as BIGINT);
|
|
||||||
</Script>
|
|
||||||
<CronExpression>0 0/5 * * * ?</CronExpression>
|
|
||||||
</Analytics>
|
|
0
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_publisher/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_publisher/artifact.xml
0
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_publisher/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_publisher/artifact.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_publisher/temperature_publisher.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_publisher/temperature_publisher.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_publisher/temperature_publisher.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_publisher/temperature_publisher.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_store/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_store/artifact.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_store/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_store/artifact.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_store/org_wso2_iot_devices_temperature.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_store/iot_per_device_stream_virtualfirealarm_temperature.xml
2
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_store/org_wso2_iot_devices_temperature.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_store/iot_per_device_stream_virtualfirealarm_temperature.xml
3
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_stream/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_stream/artifact.xml
3
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_stream/artifact.xml → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_stream/artifact.xml
4
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_stream/org.wso2.iot.devices.temperature_1.0.0.json → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_stream/iot.per.device.stream.virtualfirealarm.temperature_1.0.0.json
4
components/analytics/iot-analytics/org.wso2.carbon.device.mgt.iot.analytics/src/main/resources/carbonapps/temperature_sensor/temperature_stream/org.wso2.iot.devices.temperature_1.0.0.json → components/device-types/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics/src/main/resources/carbonapps/virtualfirealarm/temperature_stream/iot.per.device.stream.virtualfirealarm.temperature_1.0.0.json
@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"name": "org.wso2.iot.devices.temperature",
|
"name": "iot.per.device.stream.virtualfirealarm.temperature",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"nickName": "Temperature Data",
|
"nickName": "Temperature Data",
|
||||||
"description": "Temperature data received from the Device",
|
"description": "Temperature data received from Virtual Fire Alarm",
|
||||||
"metaData": [
|
"metaData": [
|
||||||
{"name":"owner","type":"STRING"},
|
{"name":"owner","type":"STRING"},
|
||||||
{"name":"deviceType","type":"STRING"},
|
{"name":"deviceType","type":"STRING"},
|
2
features/device-types-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics.feature/src/main/resources/streams/org.wso2.iot.virtualfirealarm_1.0.0.json → features/device-types-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics.feature/src/main/resources/streams/iot.per.device.stream.virtualfirealarm_1.0.0.json
2
features/device-types-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics.feature/src/main/resources/streams/org.wso2.iot.virtualfirealarm_1.0.0.json → features/device-types-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.analytics.feature/src/main/resources/streams/iot.per.device.stream.virtualfirealarm_1.0.0.json
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "org.wso2.iot.virtualfirealarm",
|
"name": "iot.per.device.stream.virtualfirealarm",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"nickName": "virtual_firealarm",
|
"nickName": "virtual_firealarm",
|
||||||
"description": "Temperature data received from the virtual_firealarm",
|
"description": "Temperature data received from the virtual_firealarm",
|
Loading…
Reference in new issue