mirror of
https://repository.entgra.net/community/product-iots.git
synced 2025-09-16 23:32:19 +00:00
Adding some fixes for android analytics.
This commit is contained in:
parent
9e5b8d66cb
commit
0b86f76362
@ -247,6 +247,15 @@
|
||||
</includes>
|
||||
</fileSet>
|
||||
|
||||
<fileSet>
|
||||
<directory>
|
||||
src/repository/resources/portal/libs/
|
||||
</directory>
|
||||
<outputDirectory>${pom.artifactId}-${pom.version}/repository/deployment/server/jaggeryapps/portal/libs/analytics-wso2-2.0.0</outputDirectory>
|
||||
<includes>
|
||||
<include>**/*</include>
|
||||
</includes>
|
||||
</fileSet>
|
||||
|
||||
</fileSets>
|
||||
<files>
|
||||
@ -706,6 +715,10 @@
|
||||
<source>src/repository/conf/etc/jwt.properties</source>
|
||||
<outputDirectory>${pom.artifactId}-${pom.version}/repository/conf/etc</outputDirectory>
|
||||
</file>
|
||||
<file>
|
||||
<source>src/repository/conf/analytics/spark/spark-udf-config.xml</source>
|
||||
<outputDirectory>${pom.artifactId}-${pom.version}/repository/conf/analytics/spark</outputDirectory>
|
||||
</file>
|
||||
|
||||
<!-- Copying metrics feature related files -->
|
||||
<file>
|
||||
|
||||
@ -0,0 +1,38 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<!--
|
||||
~ 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.
|
||||
-->
|
||||
|
||||
<udf-configuration>
|
||||
<custom-udf-classes>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udf.defaults.StringConcatenator</class-name>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udf.defaults.TimestampUDF</class-name>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udf.defaults.TimeNowUDF</class-name>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udf.facets.FacetUDF</class-name>
|
||||
<class-name>org.wso2.carbon.analytics.shared.common.udf.DateTimeUDF</class-name>
|
||||
</custom-udf-classes>
|
||||
<custom-udaf-classes>
|
||||
<custom-udaf>
|
||||
<alias>geometricMean</alias>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udaf.defaults.GeometricMeanUDAF</class-name>
|
||||
</custom-udaf>
|
||||
<custom-udaf>
|
||||
<alias>harmonicMean</alias>
|
||||
<class-name>org.wso2.carbon.analytics.spark.core.udaf.defaults.HarmonicMeanUDAF</class-name>
|
||||
</custom-udaf>
|
||||
</custom-udaf-classes>
|
||||
</udf-configuration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright (c) 2016, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
|
||||
*
|
||||
* Licensed 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.
|
||||
*/
|
||||
|
||||
var getDateString, getDuration;
|
||||
|
||||
(function() {
|
||||
|
||||
getDateString = function (timestamp) {
|
||||
var date = new Date();
|
||||
date.setTime(timestamp);
|
||||
return date.toString();
|
||||
};
|
||||
|
||||
getDuration = function (durationInMS) {
|
||||
var time = '';
|
||||
var date = new Date();
|
||||
date.setTime(durationInMS);
|
||||
|
||||
var day = Math.floor(durationInMS/86400000);
|
||||
if (day > 0){
|
||||
//More than 1 day
|
||||
time = day +' day : ';
|
||||
durationInMS = durationInMS - (day * 86400000);
|
||||
}
|
||||
var hour = Math.floor(durationInMS/3600000);
|
||||
if (hour > 0){
|
||||
//More than 1 hour
|
||||
time = time + hour + ' hour : ';
|
||||
durationInMS = durationInMS - (hour * 3600000);
|
||||
}
|
||||
|
||||
var minutes = Math.floor(durationInMS/60000);
|
||||
if (minutes > 0){
|
||||
//More than 1 minute
|
||||
time = time + minutes + ' minutes : ';
|
||||
durationInMS = durationInMS - (minutes * 60000);
|
||||
}
|
||||
|
||||
var seconds = Math.ceil(durationInMS/1000);
|
||||
if (seconds > 0){
|
||||
//More than 1 minute
|
||||
time = time + seconds + ' seconds : ';
|
||||
}
|
||||
time = time.slice(0, -2);
|
||||
return time;
|
||||
};
|
||||
}());
|
||||
@ -388,6 +388,9 @@
|
||||
<featureArtifactDef>
|
||||
org.wso2.carbon.event-processing:org.wso2.carbon.geo.dashboard.feature:${carbon.event-processing.version}
|
||||
</featureArtifactDef>
|
||||
<featureArtifactDef>
|
||||
org.wso2.carbon.analytics.shared:org.wso2.carbon.analytics.shared.spark.common.udf.feature:${analytics.shared.version}
|
||||
</featureArtifactDef>
|
||||
</featureArtifacts>
|
||||
</configuration>
|
||||
</execution>
|
||||
@ -489,6 +492,10 @@
|
||||
<id>org.wso2.das.styles.feature.group</id>
|
||||
<version>${product.das.version}</version>
|
||||
</feature>
|
||||
<feature>
|
||||
<id>org.wso2.carbon.analytics.shared.spark.common.udf.feature.group</id>
|
||||
<version>${analytics.shared.version}</version>
|
||||
</feature>
|
||||
|
||||
<!-- ********* START - Registry related *********** -->
|
||||
<feature>
|
||||
|
||||
@ -126,6 +126,11 @@
|
||||
<include name="*.car"/>
|
||||
</fileset>
|
||||
</copy>
|
||||
<copy todir="../analytics/repository/deployment/server/">
|
||||
<fileset dir="resources/analytics">
|
||||
<include name="**/*"/>
|
||||
</fileset>
|
||||
</copy>
|
||||
</tasks>
|
||||
</configuration>
|
||||
<goals>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>activity_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.activity:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>audio_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.audio:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>battery_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.battery:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>call_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.call:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>location_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.location:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>network_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.data:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>screen_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.screen:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<streamConfiguration type="csv">
|
||||
<file>sms_data.csv</file>
|
||||
<streamID>org.wso2.iot.android.sms:1.0.0</streamID>
|
||||
<separateChar>,</separateChar>
|
||||
<delayBetweenEventsInMilies>1000</delayBetweenEventsInMilies>
|
||||
</streamConfiguration>
|
||||
6
pom.xml
6
pom.xml
@ -1559,7 +1559,7 @@
|
||||
<carbon.mediation.version>4.6.6</carbon.mediation.version>
|
||||
|
||||
<!-- Carbon Analytics Common (DAS) -->
|
||||
<carbon.analytics.common.version>5.1.4</carbon.analytics.common.version>
|
||||
<carbon.analytics.common.version>5.1.5-SNAPSHOT</carbon.analytics.common.version>
|
||||
<carbon.analytics.version>1.3.0</carbon.analytics.version>
|
||||
<carbon.analytics.das.version>1.2.7</carbon.analytics.das.version>
|
||||
<product.iot.analytics.version>${product.iot.version}</product.iot.analytics.version>
|
||||
@ -1597,7 +1597,7 @@
|
||||
<shindig.version>2.0.2</shindig.version>
|
||||
<carbon.data.version>4.3.6</carbon.data.version>
|
||||
<equinox.osgi.version>3.8.1.v20120830-144521</equinox.osgi.version>
|
||||
<analytics.shared.version>1.0.1</analytics.shared.version>
|
||||
<analytics.shared.version>1.0.3</analytics.shared.version>
|
||||
|
||||
<orbit.version.commons-httpclient>3.1.0.wso2v2</orbit.version.commons-httpclient>
|
||||
<wss4j.security.version>1.6.17</wss4j.security.version>
|
||||
@ -1647,7 +1647,7 @@
|
||||
<orbit.version.h2>1.2.140.wso2v3</orbit.version.h2>
|
||||
<orbit.version.joda-time>2.8.2.wso2v1</orbit.version.joda-time>
|
||||
<orbit.version.json>2.0.0.wso2v1</orbit.version.json>
|
||||
<carbon.dashboard.version>2.0.1</carbon.dashboard.version>
|
||||
<carbon.dashboard.version>2.0.3</carbon.dashboard.version>
|
||||
<carbon.event-processing.version>2.1.4</carbon.event-processing.version>
|
||||
<imp.pkg.version.javax.servlet>[2.6.0,3.0.0)</imp.pkg.version.javax.servlet>
|
||||
<akka.version>2.3.4-spark</akka.version>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user