Changes to IoT Analytic artifacts

revert-dabc3590
Rasika Perera 8 years ago
parent 54e5994b0b
commit 9d3f1a40d6

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<artifact name="Geo-EventSink-FusedStream" version="1.0.0" type="analytics/eventstore" serverRole="GeoDashboard">
<file>org_wso2_geo_FusedSpatialEvent.xml</file>
</artifact>

@ -11,10 +11,10 @@
@Import('org.wso2.geo.ProcessedSpatialEvents:1.0.0') @Import('org.wso2.geo.ProcessedSpatialEvents:1.0.0')
define stream dataIn (id string, latitude double, longitude double, timeStamp long, type string, speed float, heading float, eventId string, state string, information string ); define stream dataIn (id string, latitude double, longitude double, timeStamp long, type string, speed float, heading float, eventId string, state string, information string );
@Export('org.wso2.geo.AlertsNotifications:1.0.0') @Export('iot.per.device.stream.geo.AlertNotifications:1.0.0')
define stream alertsOut ( id string, state string, information string, timeStamp long, latitude double, longitude double, type string); define stream alertsOut ( id string, state string, information string, timeStamp long, latitude double, longitude double, type string);
@Export('org.wso2.geo.FusedSpatialEvent:1.0.0') @Export('iot.per.device.stream.geo.FusedSpatialEvent:1.0.0')
define stream dataOut ( id string, latitude double, longitude double, timeStamp long, type string, speed float, heading float, state string, information string, notify bool ); define stream dataOut ( id string, latitude double, longitude double, timeStamp long, type string, speed float, heading float, state string, information string, notify bool );
from dataIn#window.geodashboard:eventsFusion(eventId, state, information) from dataIn#window.geodashboard:eventsFusion(eventId, state, information)

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<eventPublisher name="Geo-Publisher-WebSocketLocal-FusedSpacialEvent" <eventPublisher name="Geo-Publisher-WebSocketLocal-FusedSpacialEvent"
statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventpublisher"> statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventpublisher">
<from streamName="org.wso2.geo.FusedSpatialEvent" version="1.0.0"/> <from streamName="iot.per.device.stream.geo.FusedSpatialEvent" version="1.0.0"/>
<mapping customMapping="enable" type="json"> <mapping customMapping="enable" type="json">
<inline>{ <inline>{
"messageType" : "Point", "messageType" : "Point",

@ -2,7 +2,7 @@
<eventPublisher <eventPublisher
name="Geo-Publisher-WebSocketLocal-GeoAlertNotifications" name="Geo-Publisher-WebSocketLocal-GeoAlertNotifications"
statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventpublisher"> statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventpublisher">
<from streamName="org.wso2.geo.AlertsNotifications" version="1.0.0"/> <from streamName="iot.per.device.stream.geo.AlertNotifications" version="1.0.0"/>
<mapping customMapping="enable" type="json"> <mapping customMapping="enable" type="json">
<inline>{ <inline>{
"messageType" : "Alert", "messageType" : "Alert",

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<artifact name="WSO2IoT-EventSink-FusedStream" version="1.0.0" type="analytics/eventstore" serverRole="GeoDashboard">
<file>iot_per_device_stream_geo_FusedSpatialEvent.xml</file>
</artifact>

@ -83,7 +83,7 @@
</ColumnDefinition> </ColumnDefinition>
</TableSchema> </TableSchema>
<Source> <Source>
<StreamId>org.wso2.geo.FusedSpatialEvent:1.0.0</StreamId> <StreamId>iot.per.device.stream.geo.FusedSpatialEvent:1.0.0</StreamId>
</Source> </Source>
<MergeSchema>false</MergeSchema> <MergeSchema>false</MergeSchema>
<RecordStoreName>EVENT_STORE</RecordStoreName> <RecordStoreName>EVENT_STORE</RecordStoreName>

@ -16,6 +16,6 @@
~ under the License. ~ under the License.
--> -->
<artifact name="Geo-Publisher-RDBMS-GeoAlertNotifications" version="1.0.0" type="analytics/eventstore" serverRole="GeoDashboard"> <artifact name="WSO2IoT-Geo-AlertNotifications" version="1.0.0" type="analytics/eventstore" serverRole="GeoDashboard">
<file>Geo-Publisher-RDBMS-GeoAlertNotifications.xml</file> <file>iot_per_device_stream_geo_AlertNotifications.xml</file>
</artifact> </artifact>

@ -59,7 +59,7 @@
</ColumnDefinition> </ColumnDefinition>
</TableSchema> </TableSchema>
<Source> <Source>
<StreamId>Geo-Publisher-RDBMS-GeoAlertNotifications:1.0.0</StreamId> <StreamId>iot.per.device.stream.geo.AlertNotifications:1.0.0</StreamId>
</Source> </Source>
<MergeSchema>false</MergeSchema> <MergeSchema>false</MergeSchema>
<RecordStoreName>EVENT_STORE</RecordStoreName> <RecordStoreName>EVENT_STORE</RecordStoreName>

@ -0,0 +1,27 @@
<?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="WSO2IoT-Geo-Event-Receiver"
trace="disable" xmlns="http://wso2.org/carbon/eventreceiver">
<from eventAdapterType="iot-event">
<property name="events.duplicated.in.cluster">false</property>
</from>
<mapping customMapping="disable" type="wso2event"/>
<to streamName="org.wso2.iot.LocationStream" version="1.0.0"/>
</eventReceiver>

@ -16,6 +16,6 @@
~ under the License. ~ under the License.
--> -->
<artifact name="org.wso2.geo.FusedSpatialEvent" version="1.0.0" type="event/stream" serverRole="GeoDashboard"> <artifact name="WSO2IoT-Geo-Event-Receiver" version="1.0.0" type="event/receiver" serverRole="GeoDashboard">
<file>org.wso2.geo.FusedSpatialEvent-1.0.0.json</file> <file>WSO2IoT-Geo-Event-Receiver.xml</file>
</artifact> </artifact>

@ -0,0 +1,19 @@
/* Enter a unique ExecutionPlan */
@Plan:name('WSO2IoT-Geo-ExecutionPlan')
/* Enter a unique description for ExecutionPlan */
@Plan:description('To convert the WSO2 IoT event incoming stream to relavant streams')
/* define streams/tables and write queries here ... */
@Plan:trace('false')
@Import('org.wso2.iot.LocationStream:1.0.0')
define stream dataIn (meta_deviceId string, meta_deviceType string, timeStamp long, latitude double, longitude double);
@Export('org.wso2.geo.StandardSpatialEvents:1.0.0')
define stream dataOut ( id string, latitude double, longitude double, timeStamp long, type string, speed float, heading float, eventId string );
from dataIn
select meta_deviceId as id, latitude, longitude, timeStamp,
meta_deviceType as type, 0.0f as speed, 0.0f as heading, UUID() as eventId insert into dataOut

@ -0,0 +1,23 @@
<?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= "WSO2IoT-Geo-ExecutionPlan" version="1.0.0" type="event/execution-plan" serverRole="DataAnalyticsServer">
<file>WSO2IoT-Geo-ExecutionPlan.siddhiql</file>
</artifact>

@ -26,18 +26,17 @@
<!-- Theme --> <!-- Theme -->
<dependency artifact="ThemeGeoDashboard" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="ThemeGeoDashboard" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<!-- CEP Artifacts --> <!-- CEP Artifacts -->
<dependency artifact="Geo-Dashboard-Http-Receiver" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="WSO2IoT-Geo-Event-Receiver" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-Dashboard-WSO2Event-Receiver" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="WSO2IoT-EventSink-FusedStream" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-EventSink-FusedStream" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-ExecutionPlan-EventsFusionGenerateNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="Geo-ExecutionPlan-EventsFusionGenerateNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-ExecutionPlan-InputStandardizer" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-ExecutionPlan-Pass_through" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="Geo-ExecutionPlan-Pass_through" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-Publisher-RDBMS-GeoAlertNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="WSO2IoT-Geo-ExecutionPlan" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="WSO2IoT-Geo-AlertNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-Publisher-WebSocketLocal-FusedSpacialEvent" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="Geo-Publisher-WebSocketLocal-FusedSpacialEvent" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="Geo-Publisher-WebSocketLocal-GeoAlertNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="Geo-Publisher-WebSocketLocal-GeoAlertNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="org.wso2.geo.AlertsNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="iot.per.device.stream.geo.AlertNotifications" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="org.wso2.geo.FusedSpatialEvent" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="iot.per.device.stream.geo.FusedSpatialEvent" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="org.wso2.geo.LocationStream" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="org.wso2.iot.LocationStream" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="org.wso2.geo.ProcessedSpatialEvents" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="org.wso2.geo.ProcessedSpatialEvents" version="1.0.0" include="true" serverRole="GeoDashboard"/>
<dependency artifact="org.wso2.geo.StandardSpatialEvents" version="1.0.0" include="true" serverRole="GeoDashboard"/> <dependency artifact="org.wso2.geo.StandardSpatialEvents" version="1.0.0" include="true" serverRole="GeoDashboard"/>
</artifact> </artifact>

@ -0,0 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?><artifact name="iot.per.device.stream.geo.AlertNotifications" version="1.0.0" type="event/stream" serverRole="GeoDashboard">
<file>iot.per.device.stream.geo.AlertNotifications-1.0.0.json</file>
</artifact>

@ -1,5 +1,5 @@
{ {
"name": "org.wso2.geo.AlertsNotifications", "name": "iot.per.device.stream.geo.AlertNotifications",
"version": "1.0.0", "version": "1.0.0",
"nickName": "", "nickName": "",
"description": "Alerts which need to be notified to the user, output only when the alert information is changed.", "description": "Alerts which need to be notified to the user, output only when the alert information is changed.",

@ -16,6 +16,6 @@
~ under the License. ~ under the License.
--> -->
<artifact name="Geo-ExecutionPlan-InputStandardizer" version="1.0.0" type="event/execution-plan" serverRole="GeoDashboard"> <artifact name="iot.per.device.stream.geo.FusedSpatialEvent" version="1.0.0" type="event/stream" serverRole="GeoDashboard">
<file>Geo-ExecutionPlan-InputStandardizer-1.0.0.siddhiql</file> <file>iot.per.device.stream.geo.FusedSpatialEvent-1.0.0.json</file>
</artifact> </artifact>

@ -1,3 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><artifact name="org.wso2.geo.AlertsNotifications" version="1.0.0" type="event/stream" serverRole="GeoDashboard">
<file>org.wso2.geo.AlertsNotifications-1.0.0.json</file>
</artifact>

@ -16,6 +16,6 @@
~ under the License. ~ under the License.
--> -->
<artifact name="org.wso2.geo.LocationStream" version="1.0.0" type="event/stream" serverRole="GeoDashboard"> <artifact name="org.wso2.iot.LocationStream" version="1.0.0" type="event/stream" serverRole="GeoDashboard">
<file>org.wso2.geo.LocationStream-1.0.0.json</file> <file>org.wso2.iot.LocationStream-1.0.0.json</file>
</artifact> </artifact>

@ -0,0 +1,30 @@
{
"name": "org.wso2.iot.LocationStream",
"version": "1.0.0",
"nickName": "",
"description": "IoT Server Location Stream",
"metaData": [
{
"name": "deviceId",
"type": "STRING"
},
{
"name": "deviceType",
"type": "STRING"
}
],
"payloadData": [
{
"name": "timeStamp",
"type": "LONG"
},
{
"name": "latitude",
"type": "DOUBLE"
},
{
"name": "longitude",
"type": "DOUBLE"
}
]
}
Loading…
Cancel
Save