Re: [Dev] [Siddhi] Partition with two attributes of same stream

2017-09-28 Thread Gobinath
Thank you very much.
Your solution works.


Thanks & Regards,
Gobinath

On Thu, Sep 28, 2017 at 3:09 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Apparently, it does not support multiple attributes as partition keys.
> but you can use
> partition with ( str: concat(srcIp,'-', dstIp) of PacketStream ) ...
>
> or use a previous query to content and send as one data.
>
>
>
> On Thu, Sep 28, 2017 at 10:41 PM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi,
>>
>> During my recent testing, Siddhi does not allow partition with two
>> attributes of the same stream. For example, the following query throws
>> *SiddhiAppValidationException* with a message partition already exists
>> because the streamId is used to uniquely identify the partition [1].
>>
>> define stream PacketStream (srcIp string, dstIp string, packets int);
>>
>> partition with (srcIp of PacketStream, dstIp of PacketStream)
>> begin
>>   from PacketStream
>>   select srcIp, dstIp, count(packets) as count
>>   insert into OutputStream;
>> end;
>>
>> I wonder whether it is not supported due to any constraints. If there is
>> nothing like that, I can have a look at it.
>>
>> FYI: I tried to change the partition id as a combination of stream id and
>> the attribute name but it does not register a PartitionReceiver for the
>> later one.
>>
>> [1] https://github.com/slgobinath/siddhi/blob/master/modules/sid
>> dhi-query-api/src/main/java/org/wso2/siddhi/query/api/execut
>> ion/partition/Partition.java#L101
>>
>> Thanks & Regards,
>> Gobinath
>>
>> --
>> *Gobinath** Loganathan*
>> Graduate Student,
>> Electrical and Computer Engineering,
>> Western University.
>> Email  : slgobin...@gmail.com
>> Blog: javahelps.com <http://www.javahelps.com/>
>>
>>
>
>
>
> --
>
> *S. Suhothayan*
> Associate Director / Architect
> *WSO2 Inc. *http://wso2.com
> * <http://wso2.com/>*
> lean . enterprise . middleware
>
>
> *cell: (+94) 779 756 757 <077%20975%206757> | blog:
> http://suhothayan.blogspot.com/ <http://suhothayan.blogspot.com/>twitter:
> http://twitter.com/suhothayan <http://twitter.com/suhothayan> | linked-in:
> http://lk.linkedin.com/in/suhothayan <http://lk.linkedin.com/in/suhothayan>*
>



-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [Siddhi] Partition with two attributes of same stream

2017-09-28 Thread Gobinath
Hi,

During my recent testing, Siddhi does not allow partition with two
attributes of the same stream. For example, the following query throws
*SiddhiAppValidationException* with a message partition already exists
because the streamId is used to uniquely identify the partition [1].

define stream PacketStream (srcIp string, dstIp string, packets int);

partition with (srcIp of PacketStream, dstIp of PacketStream)
begin
  from PacketStream
  select srcIp, dstIp, count(packets) as count
  insert into OutputStream;
end;

I wonder whether it is not supported due to any constraints. If there is
nothing like that, I can have a look at it.

FYI: I tried to change the partition id as a combination of stream id and
the attribute name but it does not register a PartitionReceiver for the
later one.

[1]
https://github.com/slgobinath/siddhi/blob/master/modules/siddhi-query-api/src/main/java/org/wso2/siddhi/query/api/execution/partition/Partition.java#L101

Thanks & Regards,
Gobinath

-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Siddhi] non-matched or expired events in pattern query

2017-09-27 Thread Gobinath
Hi,

If you can use Siddhi 4 snapshot release, it can be done using the new
feature 'Absent Pattern' added to Siddhi 4. The query to detect the events
that do not match the condition within 10 seconds is given below:

from every e1=publisher -> not subscriber[e1.pid == pid] for 10 sec
select e1.pid
insert into not_completed_jobs_in_time;

The above query waits for 10 seconds from the arrival of every publisher
event and if there is no subscriber event with an id satisfying the
condition arrived within that waiting period, the id of the publisher event
will be inserted into the not_completed_jobs_in_time stream.

I guess the official document for Siddhi 4 is under construction. So you
can find more details about absent pattern at [1]

Still, Siddhi 4 is not production ready so I wonder whether you can use
this feature or not.

[1]
http://www.javahelps.com/2017/08/detect-absence-of-events-wso2-siddhi.html




On Tue, Sep 26, 2017 at 10:05 PM, Jayesh Senjaliya <jhsonl...@gmail.com>
wrote:

> Hi Grainier,
>
> ya, i came across that example page, but i think that does not work in my
> use-case which is as follow.
>
> i have a publish event followed by multiple subscribe event for the same
> publish job.
> now i want to catch if certain jobs (publish -> subscribe) has been
> finished with 10 sec.
> I have all the registered jobs in db table, which i use to gather all the
> required publish-subscribe job events.
>
> define table jobTable( pid string, sid string);
> define stream pubStream (pid int, status string);
> define stream subStream (pid int, sid int, status string);
>
> -- this will get all the publish-> subscribe jobs events as master list
> from pubStream as p join jobTable as t
> on p.pid == t.pid
> select p.pid, t.sid insert into allPSJobs;
>
> -- this is where i need to do intersection where if subStream event is
> seen within 2 sec then remove that from master list ( allPSJobs ) if not
> include that in not_completed_jobs_in_time
>
> from every ( a=allPSJobs ) -> s= subStream[sid == a.sid and pid==a.pid ]
> within 2 sec
> select s.pid, s.sid insert into completed_jobs_in_time;
>
>
> hope that make sense from what i am trying to do.
>
> Thanks
> Jayesh
>
>
>
>
>
>
>
>
>
>
>
> On Mon, Sep 25, 2017 at 8:39 AM, Grainier Perera <grain...@wso2.com>
> wrote:
>
>> Hi Jay,
>>
>> You can try something similar to this to get non-matched events during
>> last 10 secs; You can find some documentation on this as well; link
>> <https://docs.wso2.com/display/CEP420/Sample+0111+-+Detecting+non-occurrences+with+Patterns>
>>
>>
>>
>>> define stream publisher (pid string, time string);
>>> define stream subscriber (pid string, sid string, time string);
>>
>>
>>> from publisher#window.time(10 sec)
>>> select *
>>> insert expired events into expired_publisher;
>>
>>
>>> from every pub=publisher -> sub=subscriber[pub.pid == pid] or
>>> exp=expired_publisher[pub.pid == pid]
>>> select pub.pid as pid, pub.time as time, sub.pid as subPid
>>> insert into filter_stream;
>>
>>
>>> from filter_stream [(subPid is null)]
>>> select pid, time
>>> insert into not_seen_in_last_10_sec_events;
>>
>>
>> Moreover, I didn't get what you meant by "also is there a way to perform
>> intersection of events based on grouping or time window ?" can you please
>> elaborate on this?
>>
>> Regards,
>>
>> On Mon, Sep 25, 2017 at 11:02 AM, Jayesh Senjaliya <jhsonl...@gmail.com>
>> wrote:
>>
>>> Hi,
>>>
>>> is there a way to get events that didnt match within the given time
>>> frame.
>>>
>>> for example:
>>>
>>> define stream publisher (pid string, time string);
>>> define stream subscriber (pid string, sid string, time string);
>>>
>>> from every (e1=publisher) -> e2=subscriber[e1.pid == pid]
>>> within 10 sec
>>> select e1.pid, e2.sid
>>> insert into seen_in_last_10_sec_events;
>>>
>>>
>>> so if i have matching event above, i will see it in
>>> seen_in_last_10_sec_events, but is there a way to get all events or non
>>> matched events during that last 10 seconds from publisher or subscriber ?
>>>
>>> also is there a way to perform intersection of events based on grouping
>>> or time window ?
>>>
>>>
>>> Thanks
>>> Jay
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Grainier Perera
>> Senior Software Engineer
>> Mobile : +94716122384 <+94%2071%20612%202384>
>> WSO2 Inc. | http://wso2.com
>> lean.enterprise.middleware
>>
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Siddhi] TestUtility to throw Assertion Errors from main thread

2017-09-15 Thread Gobinath
Hi,

My last PR contains a check-style issue which causes to Sidhhi build
failure. Please merge my new PR #526
<https://github.com/wso2/siddhi/pull/526> which fixes the check-style issue
and also includes your suggestion.

Sorry for the check-style issue. I sent that PR just to make sure the
design so I didn't check the style.

Thanks & Regards,
Gobinath

On Fri, Sep 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Thanks for the improvement it looks good.
> I have merged.
>
> But I think it should be called as Test*Callback *with a simple b.
>
> Can you fix that.
>
> Thanks
> Suho
>
>
> On Mon, Sep 4, 2017 at 5:18 PM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi,
>>
>> As per my experience during my GSoC project, the assertion errors thrown
>> by worker threads in the unit test callbacks do not interrupt the compiling
>> process.
>>
>> I discussed with Suho during a code review and come up with a solution by
>> storing the assertion errors in a java.util.List and throw them later in
>> the main thread. I have sent a PR containing the prototype of my
>> implementation and a sample application of it [1]. Could you please check
>> the design, class name and the location.
>>
>> I am thinking about adding overloaded methods with Predicates as shown
>> below but it can be used only in combined with Assert.assertTrue. WDYT?
>>
>> public static TestCallBack addQueryCallback(SiddhiAppRuntime
>> siddhiAppRuntime, String queryName, Predicate... predicates) {
>> // ...
>> }
>>
>> [1] https://github.com/wso2/siddhi/pull/510
>>
>> PS: @Suho & @Nirmal please ignore my previous mail which has an incorrect
>> dev mail address.
>>
>> Thanks & Regards,
>> Gobinath
>>
>> --
>> *Gobinath** Loganathan*
>> Graduate Student,
>> Electrical and Computer Engineering,
>> Western University.
>> Email  : slgobin...@gmail.com
>> Blog: javahelps.com <http://www.javahelps.com/>
>>
>>
>
>
>
> --
>
> *S. Suhothayan*
> Associate Director / Architect
> *WSO2 Inc. *http://wso2.com
> * <http://wso2.com/>*
> lean . enterprise . middleware
>
>
> *cell: (+94) 779 756 757 | blog: http://suhothayan.blogspot.com/
> <http://suhothayan.blogspot.com/>twitter: http://twitter.com/suhothayan
> <http://twitter.com/suhothayan> | linked-in:
> http://lk.linkedin.com/in/suhothayan <http://lk.linkedin.com/in/suhothayan>*
>



-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [Siddhi] TestUtility to throw Assertion Errors from main thread

2017-09-04 Thread Gobinath
Hi,

As per my experience during my GSoC project, the assertion errors thrown by
worker threads in the unit test callbacks do not interrupt the compiling
process.

I discussed with Suho during a code review and come up with a solution by
storing the assertion errors in a java.util.List and throw them later in
the main thread. I have sent a PR containing the prototype of my
implementation and a sample application of it [1]. Could you please check
the design, class name and the location.

I am thinking about adding overloaded methods with Predicates as shown
below but it can be used only in combined with Assert.assertTrue. WDYT?

public static TestCallBack addQueryCallback(SiddhiAppRuntime
siddhiAppRuntime, String queryName, Predicate... predicates) {
// ...
}

[1] https://github.com/wso2/siddhi/pull/510

PS: @Suho & @Nirmal please ignore my previous mail which has an incorrect
dev mail address.

Thanks & Regards,
Gobinath

-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-11 Thread Gobinath
Hi,
I defined the number of operands as the number of LogicalStreamProcessors
that can be partners. Not is handled by one LogicalStreamProcessor so it
can be partner with another LogicalStreamProcessor.

Does it make sense?

Thanks and Regards,
Gobinath

On Jul 11, 2017 3:06 PM, "Sriskandarajah Suhothayan" <s...@wso2.com> wrote:

> Can you please elaborate on "more than two pattern operands is not
> supported by Siddhi"
> I thought (not C and D) is still one operand as we can't access C.
>
> On Tue, Jul 11, 2017 at 1:42 AM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi Suho,
>>
>> I have added the test cases to all the cases you have mentioned except
>> the four listed below because having more than two pattern operands is not
>> supported by Siddhi. I hope it is okay to skip those test cases. WDYT?
>>
>>
>>- every ( (not C and D) and B ) -> A
>>- every ((not C and D) or B ) -> A
>>- every (B and (not C and D) ) -> A
>>- every (B or (not C and D) ) -> A
>>
>>
>> If there are no more cases to test, may I start with the SEQUENCE?
>>
>>
>> Thanks & Regards,
>> Gobinath
>>
>> On Mon, Jul 3, 2017 at 2:32 PM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>> Sure. I will add test cases for each of these cases.
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Mon, Jul 3, 2017 at 2:23 PM, Sriskandarajah Suhothayan <s...@wso2.com
>>> > wrote:
>>>
>>>>
>>>>
>>>> On Mon, Jul 3, 2017 at 5:18 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> The following absent event cases are implemented and tested so far and
>>>>> now I am focusing on testing these patterns in the form of *Sequence*.
>>>>> If you find any cases that I missed or any improvements, please share 
>>>>> them.
>>>>>
>>>>>
>>>>>
>>>>> A not B for 1sec
>>>>>
>>>>> After the arrival of A, wait for 1 sec & B not arrived
>>>>>
>>>>> A → not B and C
>>>>>
>>>>> When C arrive if B is not available
>>>>>
>>>>> A → (not B and C) within 1sec
>>>>>
>>>>> If B not arrived but C arrived within 1 sec from A
>>>>>
>>>>> A → (not B for 1sec  and C) within 2sec
>>>>>
>>>>> Wait for 1 sec from the arrival of A; if B not arrived and C arrived
>>>>> and both happened within 2 sec from A
>>>>>
>>>>> not A for 1sec → B
>>>>>
>>>>> Wait for 1 sec; if A not arrived but B arrived after 1sec
>>>>>
>>>>> not A and B → C
>>>>>
>>>>> When B arrive if A is not available followed by C
>>>>>
>>>>> every ( not B and  A)  → C
>>>>>
>>>>> Every combination of the previous case
>>>>>
>>>>> every ( not B for 1sec) → C
>>>>>
>>>>> Check and emit C every second, if B not arrive
>>>>>
>>>>> A → not B  for 1 sec and not C for 1 sec
>>>>>
>>>>> After A, both B and C are not received within 1 sec
>>>>>
>>>>> not A  for 1 sec and not B for 1 sec → C
>>>>>
>>>>> A and B are not received for 1 sec and then C
>>>>>
>>>>> A → not B   for 1 sec or not C for 1 sec
>>>>>
>>>>> After A, wait for 1 sec B or C not received
>>>>>
>>>>> not A  for 1 sec or not B for 1 sec → C
>>>>>
>>>>> Wait for 1 sec; A or B not received followed by C
>>>>>
>>>>> A → not B for 1 sec or C
>>>>>
>>>>> After A, if C arrives, emit it otherwise emit after 1 sec if B not
>>>>> arrived
>>>>>
>>>>> not A for 1 sec or B → C
>>>>>
>>>>> Same as previous but the other way around
>>>>>
>>>>> I think these will also work but better if you can check them too via
>>>> testcase.
>>>>
>>>> A → C or not B for 1 sec
>>>>
>>>> B or not A for 1 sec → C
>>>>
>>>> every (not B  for 1 sec and not C for 1 sec ) -> A
>>>>
>>>> every (not B  

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-10 Thread Gobinath
Hi Suho,

I have added the test cases to all the cases you have mentioned except the
four listed below because having more than two pattern operands is not
supported by Siddhi. I hope it is okay to skip those test cases. WDYT?


   - every ( (not C and D) and B ) -> A
   - every ((not C and D) or B ) -> A
   - every (B and (not C and D) ) -> A
   - every (B or (not C and D) ) -> A


If there are no more cases to test, may I start with the SEQUENCE?


Thanks & Regards,
Gobinath

On Mon, Jul 3, 2017 at 2:32 PM, Gobinath <slgobin...@gmail.com> wrote:

> Hi,
> Sure. I will add test cases for each of these cases.
>
>
> Thanks & Regards,
> Gobinath
>
> On Mon, Jul 3, 2017 at 2:23 PM, Sriskandarajah Suhothayan <s...@wso2.com>
> wrote:
>
>>
>>
>> On Mon, Jul 3, 2017 at 5:18 PM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> The following absent event cases are implemented and tested so far and
>>> now I am focusing on testing these patterns in the form of *Sequence*.
>>> If you find any cases that I missed or any improvements, please share them.
>>>
>>>
>>>
>>> A not B for 1sec
>>>
>>> After the arrival of A, wait for 1 sec & B not arrived
>>>
>>> A → not B and C
>>>
>>> When C arrive if B is not available
>>>
>>> A → (not B and C) within 1sec
>>>
>>> If B not arrived but C arrived within 1 sec from A
>>>
>>> A → (not B for 1sec  and C) within 2sec
>>>
>>> Wait for 1 sec from the arrival of A; if B not arrived and C arrived and
>>> both happened within 2 sec from A
>>>
>>> not A for 1sec → B
>>>
>>> Wait for 1 sec; if A not arrived but B arrived after 1sec
>>>
>>> not A and B → C
>>>
>>> When B arrive if A is not available followed by C
>>>
>>> every ( not B and  A)  → C
>>>
>>> Every combination of the previous case
>>>
>>> every ( not B for 1sec) → C
>>>
>>> Check and emit C every second, if B not arrive
>>>
>>> A → not B  for 1 sec and not C for 1 sec
>>>
>>> After A, both B and C are not received within 1 sec
>>>
>>> not A  for 1 sec and not B for 1 sec → C
>>>
>>> A and B are not received for 1 sec and then C
>>>
>>> A → not B   for 1 sec or not C for 1 sec
>>>
>>> After A, wait for 1 sec B or C not received
>>>
>>> not A  for 1 sec or not B for 1 sec → C
>>>
>>> Wait for 1 sec; A or B not received followed by C
>>>
>>> A → not B for 1 sec or C
>>>
>>> After A, if C arrives, emit it otherwise emit after 1 sec if B not
>>> arrived
>>>
>>> not A for 1 sec or B → C
>>>
>>> Same as previous but the other way around
>>>
>>> I think these will also work but better if you can check them too via
>> testcase.
>>
>> A → C or not B for 1 sec
>>
>> B or not A for 1 sec → C
>>
>> every (not B  for 1 sec and not C for 1 sec ) -> A
>>
>> every (not B  for 1 sec or not C for 1 sec ) -> A
>>
>> every (B *and* not C for 1 sec ) -> A
>>
>> every (not C for 1 sec *and* B ) -> A
>>
>> every (B *or* not C for 1 sec ) -> A
>>
>> every (not C for 1 sec *or* B ) -> A
>>
>> every (B *and* (not C and D) ) -> A
>>
>> every ( (not C and D) *and* B ) -> A
>>
>> every (B *or* (not C and D) ) -> A
>>
>> every ((not C and D) *or* B ) -> A
>>
>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Sun, Jul 2, 2017 at 6:34 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Thanks, Suho.
>>>>
>>>> Sure I will.
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Sun, Jul 2, 2017 at 6:32 AM, Sriskandarajah Suhothayan <
>>>> s...@wso2.com> wrote:
>>>>
>>>>> Thanks merged the PR.
>>>>>
>>>>> Can you inform in SOF that you have fixed this issue, and this is the
>>>>> PR.
>>>>>
>>>>> Thanks
>>>>> Suho
>>>>>
>>>>> On Sun, Jul 2, 2017 at 6:21 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Please find the PR [1] fixing t

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-03 Thread Gobinath
Hi,
Sure. I will add test cases for each of these cases.


Thanks & Regards,
Gobinath

On Mon, Jul 3, 2017 at 2:23 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

>
>
> On Mon, Jul 3, 2017 at 5:18 PM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi,
>>
>> The following absent event cases are implemented and tested so far and
>> now I am focusing on testing these patterns in the form of *Sequence*.
>> If you find any cases that I missed or any improvements, please share them.
>>
>>
>>
>> A not B for 1sec
>>
>> After the arrival of A, wait for 1 sec & B not arrived
>>
>> A → not B and C
>>
>> When C arrive if B is not available
>>
>> A → (not B and C) within 1sec
>>
>> If B not arrived but C arrived within 1 sec from A
>>
>> A → (not B for 1sec  and C) within 2sec
>>
>> Wait for 1 sec from the arrival of A; if B not arrived and C arrived and
>> both happened within 2 sec from A
>>
>> not A for 1sec → B
>>
>> Wait for 1 sec; if A not arrived but B arrived after 1sec
>>
>> not A and B → C
>>
>> When B arrive if A is not available followed by C
>>
>> every ( not B and  A)  → C
>>
>> Every combination of the previous case
>>
>> every ( not B for 1sec) → C
>>
>> Check and emit C every second, if B not arrive
>>
>> A → not B  for 1 sec and not C for 1 sec
>>
>> After A, both B and C are not received within 1 sec
>>
>> not A  for 1 sec and not B for 1 sec → C
>>
>> A and B are not received for 1 sec and then C
>>
>> A → not B   for 1 sec or not C for 1 sec
>>
>> After A, wait for 1 sec B or C not received
>>
>> not A  for 1 sec or not B for 1 sec → C
>>
>> Wait for 1 sec; A or B not received followed by C
>>
>> A → not B for 1 sec or C
>>
>> After A, if C arrives, emit it otherwise emit after 1 sec if B not arrived
>>
>> not A for 1 sec or B → C
>>
>> Same as previous but the other way around
>>
>> I think these will also work but better if you can check them too via
> testcase.
>
> A → C or not B for 1 sec
>
> B or not A for 1 sec → C
>
> every (not B  for 1 sec and not C for 1 sec ) -> A
>
> every (not B  for 1 sec or not C for 1 sec ) -> A
>
> every (B *and* not C for 1 sec ) -> A
>
> every (not C for 1 sec *and* B ) -> A
>
> every (B *or* not C for 1 sec ) -> A
>
> every (not C for 1 sec *or* B ) -> A
>
> every (B *and* (not C and D) ) -> A
>
> every ( (not C and D) *and* B ) -> A
>
> every (B *or* (not C and D) ) -> A
>
> every ((not C and D) *or* B ) -> A
>
>
>>
>> Thanks & Regards,
>> Gobinath
>>
>> On Sun, Jul 2, 2017 at 6:34 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Thanks, Suho.
>>>
>>> Sure I will.
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Sun, Jul 2, 2017 at 6:32 AM, Sriskandarajah Suhothayan <s...@wso2.com
>>> > wrote:
>>>
>>>> Thanks merged the PR.
>>>>
>>>> Can you inform in SOF that you have fixed this issue, and this is the
>>>> PR.
>>>>
>>>> Thanks
>>>> Suho
>>>>
>>>> On Sun, Jul 2, 2017 at 6:21 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Please find the PR [1] fixing the following issues in Siddhi.
>>>>>
>>>>> 1. Logical pattern not obeying the '*within*' keyword
>>>>>
>>>>> 2. Sequence not obeying the '*every*' keyword
>>>>>
>>>>> 3. Logical pattern '*from* *A or B select...*' not producing the
>>>>> output
>>>>>
>>>>> With this fix, the problems asked in Stack Overflow [2] are resolved.
>>>>>
>>>>>
>>>>> [1] https://github.com/wso2/siddhi/pull/436
>>>>>
>>>>> [2] https://stackoverflow.com/questions/41557227/siddhi-logi
>>>>> cal-and-with-within-executes-callback-unexpectedly
>>>>>
>>>>>
>>>>> Thanks & Regards,
>>>>> Gobinath
>>>>>
>>>>>
>>>>> On Sat, May 13, 2017 at 8:02 AM, Gobinath <slgobin...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> I've fixed the duplicate ou

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-03 Thread Gobinath
Hi,

The following absent event cases are implemented and tested so far and now
I am focusing on testing these patterns in the form of *Sequence*. If you
find any cases that I missed or any improvements, please share them.



A not B for 1sec

After the arrival of A, wait for 1 sec & B not arrived

A → not B and C

When C arrive if B is not available

A → (not B and C) within 1sec

If B not arrived but C arrived within 1 sec from A

A → (not B for 1sec  and C) within 2sec

Wait for 1 sec from the arrival of A; if B not arrived and C arrived and
both happened within 2 sec from A

not A for 1sec → B

Wait for 1 sec; if A not arrived but B arrived after 1sec

not A and B → C

When B arrive if A is not available followed by C

every ( not B and  A)  → C

Every combination of the previous case

every ( not B for 1sec) → C

Check and emit C every second, if B not arrive

A → not B  for 1 sec and not C for 1 sec

After A, both B and C are not received within 1 sec

not A  for 1 sec and not B for 1 sec → C

A and B are not received for 1 sec and then C

A → not B   for 1 sec or not C for 1 sec

After A, wait for 1 sec B or C not received

not A  for 1 sec or not B for 1 sec → C

Wait for 1 sec; A or B not received followed by C

A → not B for 1 sec or C

After A, if C arrives, emit it otherwise emit after 1 sec if B not arrived

not A for 1 sec or B → C

Same as previous but the other way around



Thanks & Regards,
Gobinath

On Sun, Jul 2, 2017 at 6:34 AM, Gobinath <slgobin...@gmail.com> wrote:

> Thanks, Suho.
>
> Sure I will.
>
>
> Thanks & Regards,
> Gobinath
>
> On Sun, Jul 2, 2017 at 6:32 AM, Sriskandarajah Suhothayan <s...@wso2.com>
> wrote:
>
>> Thanks merged the PR.
>>
>> Can you inform in SOF that you have fixed this issue, and this is the PR.
>>
>> Thanks
>> Suho
>>
>> On Sun, Jul 2, 2017 at 6:21 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> Please find the PR [1] fixing the following issues in Siddhi.
>>>
>>> 1. Logical pattern not obeying the '*within*' keyword
>>>
>>> 2. Sequence not obeying the '*every*' keyword
>>>
>>> 3. Logical pattern '*from* *A or B select...*' not producing the output
>>>
>>> With this fix, the problems asked in Stack Overflow [2] are resolved.
>>>
>>>
>>> [1] https://github.com/wso2/siddhi/pull/436
>>>
>>> [2] https://stackoverflow.com/questions/41557227/siddhi-logi
>>> cal-and-with-within-executes-callback-unexpectedly
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>>
>>> On Sat, May 13, 2017 at 8:02 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> I've fixed the duplicate output with 'OR' in the PR #354 [1]. According
>>>> to this fix, the *addState* method of *LogicalPreStateProcessor*
>>>> treats both PATTERN and SEQUENCE in the same way [2]. It does not break any
>>>> existing tests but please check whether it makes sense or not.
>>>>
>>>>
>>>> [1] https://github.com/wso2/siddhi/pull/354
>>>>
>>>> [2] https://github.com/wso2/siddhi/pull/354/commits/803e4d0f
>>>> 486d7268af117bcfe42f4c704f98b3b5#diff-32293ae88907e099f28593
>>>> e5496e1e67R62
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Mon, May 8, 2017 at 1:24 AM, Sriskandarajah Suhothayan <
>>>> s...@wso2.com> wrote:
>>>>
>>>>> I have merged that. +1 this also should give 1 output.
>>>>>
>>>>> Thanks for the fixes.
>>>>>
>>>>> Regards
>>>>> Suho
>>>>>
>>>>> On Mon, May 8, 2017 at 10:18 AM, Nirmal Fernando <nir...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Again, I'd only expect one o/p;
>>>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7],
>>>>>> isExpired=false}
>>>>>>
>>>>>> On Mon, May 8, 2017 at 6:25 AM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> I've found a minor bug and sent the PR [1] with the fix. Similar
>>>>>>> behavior is noticed with *or* operator as well (Even after the
>>>>>>> fix). I have given the code and the output below for your concern.
>>>>>>>
>>>>>>> // Query: e1

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-02 Thread Gobinath
Thanks, Suho.

Sure I will.


Thanks & Regards,
Gobinath

On Sun, Jul 2, 2017 at 6:32 AM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Thanks merged the PR.
>
> Can you inform in SOF that you have fixed this issue, and this is the PR.
>
> Thanks
> Suho
>
> On Sun, Jul 2, 2017 at 6:21 AM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi,
>>
>> Please find the PR [1] fixing the following issues in Siddhi.
>>
>> 1. Logical pattern not obeying the '*within*' keyword
>>
>> 2. Sequence not obeying the '*every*' keyword
>>
>> 3. Logical pattern '*from* *A or B select...*' not producing the output
>>
>> With this fix, the problems asked in Stack Overflow [2] are resolved.
>>
>>
>> [1] https://github.com/wso2/siddhi/pull/436
>>
>> [2] https://stackoverflow.com/questions/41557227/siddhi-logi
>> cal-and-with-within-executes-callback-unexpectedly
>>
>>
>> Thanks & Regards,
>> Gobinath
>>
>>
>> On Sat, May 13, 2017 at 8:02 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> I've fixed the duplicate output with 'OR' in the PR #354 [1]. According
>>> to this fix, the *addState* method of *LogicalPreStateProcessor* treats
>>> both PATTERN and SEQUENCE in the same way [2]. It does not break any
>>> existing tests but please check whether it makes sense or not.
>>>
>>>
>>> [1] https://github.com/wso2/siddhi/pull/354
>>>
>>> [2] https://github.com/wso2/siddhi/pull/354/commits/803e4d0f
>>> 486d7268af117bcfe42f4c704f98b3b5#diff-32293ae88907e099f28593
>>> e5496e1e67R62
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Mon, May 8, 2017 at 1:24 AM, Sriskandarajah Suhothayan <s...@wso2.com
>>> > wrote:
>>>
>>>> I have merged that. +1 this also should give 1 output.
>>>>
>>>> Thanks for the fixes.
>>>>
>>>> Regards
>>>> Suho
>>>>
>>>> On Mon, May 8, 2017 at 10:18 AM, Nirmal Fernando <nir...@wso2.com>
>>>> wrote:
>>>>
>>>>> Again, I'd only expect one o/p;
>>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>>>>
>>>>> On Mon, May 8, 2017 at 6:25 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> I've found a minor bug and sent the PR [1] with the fix. Similar
>>>>>> behavior is noticed with *or* operator as well (Even after the fix).
>>>>>> I have given the code and the output below for your concern.
>>>>>>
>>>>>> // Query: e1 or e2 -> e3
>>>>>>
>>>>>> define stream Stream1 (symbol string, price float, volume int);
>>>>>> define stream Stream2 (symbol string, price float, volume int);
>>>>>>
>>>>>> @info(name = 'query1')
>>>>>> from e1=Stream1[price > 20] or e2=Stream2[price >30] ->
>>>>>> e3=Stream2['IBM' == symbol]
>>>>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>>>>> insert into OutputStream;
>>>>>>
>>>>>> // Input
>>>>>> Stream1.send(new Object[]{"WSO2", 55.6f, 100});
>>>>>> Stream2.send(new Object[]{"GOOG", 72.7f, 100});
>>>>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>>>>>
>>>>>> // Output
>>>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7],
>>>>>> isExpired=false}
>>>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7],
>>>>>> isExpired=false}
>>>>>>
>>>>>> If it is also a bug, please do let me know without merging the PR. I
>>>>>> will fix it under the same PR.
>>>>>>
>>>>>> [1] https://github.com/wso2/siddhi/pull/345
>>>>>>
>>>>>>
>>>>>> Thanks & Regards,
>>>>>> Gobinath
>>>>>>
>>>>>> On Sun, May 7, 2017 at 2:06 PM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Sure. I'll check the issue and send a separate PR with the fix.
>>>>>>>
>>>>>>>
>>>>>>&g

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-07-01 Thread Gobinath
Hi,

Please find the PR [1] fixing the following issues in Siddhi.

1. Logical pattern not obeying the '*within*' keyword

2. Sequence not obeying the '*every*' keyword

3. Logical pattern '*from* *A or B select...*' not producing the output

With this fix, the problems asked in Stack Overflow [2] are resolved.


[1] https://github.com/wso2/siddhi/pull/436

[2]
https://stackoverflow.com/questions/41557227/siddhi-logical-and-with-within-executes-callback-unexpectedly


Thanks & Regards,
Gobinath


On Sat, May 13, 2017 at 8:02 AM, Gobinath <slgobin...@gmail.com> wrote:

> Hi,
>
> I've fixed the duplicate output with 'OR' in the PR #354 [1]. According to
> this fix, the *addState* method of *LogicalPreStateProcessor* treats both
> PATTERN and SEQUENCE in the same way [2]. It does not break any existing
> tests but please check whether it makes sense or not.
>
>
> [1] https://github.com/wso2/siddhi/pull/354
>
> [2] https://github.com/wso2/siddhi/pull/354/commits/
> 803e4d0f486d7268af117bcfe42f4c704f98b3b5#diff-
> 32293ae88907e099f28593e5496e1e67R62
>
>
> Thanks & Regards,
> Gobinath
>
> On Mon, May 8, 2017 at 1:24 AM, Sriskandarajah Suhothayan <s...@wso2.com>
> wrote:
>
>> I have merged that. +1 this also should give 1 output.
>>
>> Thanks for the fixes.
>>
>> Regards
>> Suho
>>
>> On Mon, May 8, 2017 at 10:18 AM, Nirmal Fernando <nir...@wso2.com> wrote:
>>
>>> Again, I'd only expect one o/p;
>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>>
>>> On Mon, May 8, 2017 at 6:25 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> I've found a minor bug and sent the PR [1] with the fix. Similar
>>>> behavior is noticed with *or* operator as well (Even after the fix). I
>>>> have given the code and the output below for your concern.
>>>>
>>>> // Query: e1 or e2 -> e3
>>>>
>>>> define stream Stream1 (symbol string, price float, volume int);
>>>> define stream Stream2 (symbol string, price float, volume int);
>>>>
>>>> @info(name = 'query1')
>>>> from e1=Stream1[price > 20] or e2=Stream2[price >30] ->
>>>> e3=Stream2['IBM' == symbol]
>>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>>> insert into OutputStream;
>>>>
>>>> // Input
>>>> Stream1.send(new Object[]{"WSO2", 55.6f, 100});
>>>> Stream2.send(new Object[]{"GOOG", 72.7f, 100});
>>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>>>
>>>> // Output
>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>>>
>>>> If it is also a bug, please do let me know without merging the PR. I
>>>> will fix it under the same PR.
>>>>
>>>> [1] https://github.com/wso2/siddhi/pull/345
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Sun, May 7, 2017 at 2:06 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Sure. I'll check the issue and send a separate PR with the fix.
>>>>>
>>>>>
>>>>> Thanks & Regards,
>>>>> Gobinath
>>>>>
>>>>> On Sun, May 7, 2017 at 1:51 PM, Sriskandarajah Suhothayan <
>>>>> s...@wso2.com> wrote:
>>>>>
>>>>>> Yes, it looks like a bug to me, can you check why it's happening.
>>>>>>
>>>>>> Regards
>>>>>> Suho
>>>>>>
>>>>>> On Sun, May 7, 2017 at 8:56 PM, Nirmal Fernando <nir...@wso2.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Looks like a bug to me. I would expect only 1 event.
>>>>>>>
>>>>>>> On Sun, May 7, 2017 at 8:49 PM, Gobinath <slgobin...@gmail.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> Thanks for accepting my proposal. I have a question regarding the
>>>>>>>> behavior of *and* in a pattern.
>>>>>>>>
>>>>>>>> // Query: e1 and e2 -> e3
>>>>>>>>
>>>>>>>> define stream Stream1 (symbol string, pr

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-05-13 Thread Gobinath
Hi,

I've fixed the duplicate output with 'OR' in the PR #354 [1]. According to
this fix, the *addState* method of *LogicalPreStateProcessor* treats both
PATTERN and SEQUENCE in the same way [2]. It does not break any existing
tests but please check whether it makes sense or not.


[1] https://github.com/wso2/siddhi/pull/354

[2]
https://github.com/wso2/siddhi/pull/354/commits/803e4d0f486d7268af117bcfe42f4c704f98b3b5#diff-32293ae88907e099f28593e5496e1e67R62


Thanks & Regards,
Gobinath

On Mon, May 8, 2017 at 1:24 AM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> I have merged that. +1 this also should give 1 output.
>
> Thanks for the fixes.
>
> Regards
> Suho
>
> On Mon, May 8, 2017 at 10:18 AM, Nirmal Fernando <nir...@wso2.com> wrote:
>
>> Again, I'd only expect one o/p;
>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>
>> On Mon, May 8, 2017 at 6:25 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> I've found a minor bug and sent the PR [1] with the fix. Similar
>>> behavior is noticed with *or* operator as well (Even after the fix). I
>>> have given the code and the output below for your concern.
>>>
>>> // Query: e1 or e2 -> e3
>>>
>>> define stream Stream1 (symbol string, price float, volume int);
>>> define stream Stream2 (symbol string, price float, volume int);
>>>
>>> @info(name = 'query1')
>>> from e1=Stream1[price > 20] or e2=Stream2[price >30] -> e3=Stream2['IBM'
>>> == symbol]
>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>> insert into OutputStream;
>>>
>>> // Input
>>> Stream1.send(new Object[]{"WSO2", 55.6f, 100});
>>> Stream2.send(new Object[]{"GOOG", 72.7f, 100});
>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>>
>>> // Output
>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>> Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
>>>
>>> If it is also a bug, please do let me know without merging the PR. I
>>> will fix it under the same PR.
>>>
>>> [1] https://github.com/wso2/siddhi/pull/345
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Sun, May 7, 2017 at 2:06 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Sure. I'll check the issue and send a separate PR with the fix.
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Sun, May 7, 2017 at 1:51 PM, Sriskandarajah Suhothayan <
>>>> s...@wso2.com> wrote:
>>>>
>>>>> Yes, it looks like a bug to me, can you check why it's happening.
>>>>>
>>>>> Regards
>>>>> Suho
>>>>>
>>>>> On Sun, May 7, 2017 at 8:56 PM, Nirmal Fernando <nir...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Looks like a bug to me. I would expect only 1 event.
>>>>>>
>>>>>> On Sun, May 7, 2017 at 8:49 PM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> Thanks for accepting my proposal. I have a question regarding the
>>>>>>> behavior of *and* in a pattern.
>>>>>>>
>>>>>>> // Query: e1 and e2 -> e3
>>>>>>>
>>>>>>> define stream Stream1 (symbol string, price float, volume int);
>>>>>>> define stream Stream2 (symbol string, price float, volume int);
>>>>>>>
>>>>>>> @info(name = 'query1')
>>>>>>> from e1=Stream1[price > 50.0f] and e2=Stream2['IBM' == symbol] ->
>>>>>>> e3=Stream2[price > 20]
>>>>>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>>>>>> insert into OutputStream;
>>>>>>>
>>>>>>> // Input
>>>>>>> Stream1.send(new Object[]{"GOOGLE", 72.7f, 100});
>>>>>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>>>>>> Stream2.send(new Object[]{"WSO2", 55.6f, 100});
>>>>>>>
>>>>>>>
>>>>>>> // Output
>>>>>>> Event{timestamp=1494169305631, data=[GOOGLE, 4.7,

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-05-07 Thread Gobinath
Hi,

I've found a minor bug and sent the PR [1] with the fix. Similar behavior
is noticed with *or* operator as well (Even after the fix). I have given
the code and the output below for your concern.

// Query: e1 or e2 -> e3

define stream Stream1 (symbol string, price float, volume int);
define stream Stream2 (symbol string, price float, volume int);

@info(name = 'query1')
from e1=Stream1[price > 20] or e2=Stream2[price >30] -> e3=Stream2['IBM' ==
symbol]
select e1.symbol as symbol1, e2.price as price2, e3.price as price3
insert into OutputStream;

// Input
Stream1.send(new Object[]{"WSO2", 55.6f, 100});
Stream2.send(new Object[]{"GOOG", 72.7f, 100});
Stream2.send(new Object[]{"IBM", 4.7f, 100});

// Output
Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}
Event{timestamp=1494203709496, data=[WSO2, null, 4.7], isExpired=false}

If it is also a bug, please do let me know without merging the PR. I will
fix it under the same PR.

[1] https://github.com/wso2/siddhi/pull/345


Thanks & Regards,
Gobinath

On Sun, May 7, 2017 at 2:06 PM, Gobinath <slgobin...@gmail.com> wrote:

> Sure. I'll check the issue and send a separate PR with the fix.
>
>
> Thanks & Regards,
> Gobinath
>
> On Sun, May 7, 2017 at 1:51 PM, Sriskandarajah Suhothayan <s...@wso2.com>
> wrote:
>
>> Yes, it looks like a bug to me, can you check why it's happening.
>>
>> Regards
>> Suho
>>
>> On Sun, May 7, 2017 at 8:56 PM, Nirmal Fernando <nir...@wso2.com> wrote:
>>
>>> Looks like a bug to me. I would expect only 1 event.
>>>
>>> On Sun, May 7, 2017 at 8:49 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> Thanks for accepting my proposal. I have a question regarding the
>>>> behavior of *and* in a pattern.
>>>>
>>>> // Query: e1 and e2 -> e3
>>>>
>>>> define stream Stream1 (symbol string, price float, volume int);
>>>> define stream Stream2 (symbol string, price float, volume int);
>>>>
>>>> @info(name = 'query1')
>>>> from e1=Stream1[price > 50.0f] and e2=Stream2['IBM' == symbol] ->
>>>> e3=Stream2[price > 20]
>>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>>> insert into OutputStream;
>>>>
>>>> // Input
>>>> Stream1.send(new Object[]{"GOOGLE", 72.7f, 100});
>>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>>> Stream2.send(new Object[]{"WSO2", 55.6f, 100});
>>>>
>>>>
>>>> // Output
>>>> Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6],
>>>> isExpired=false}
>>>> Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6],
>>>> isExpired=false}
>>>>
>>>> Is this the expected output?. Note that the output contains two exactly
>>>> similar events but the pattern *e1 -> e2 and e3* outputs a single
>>>> event [1].
>>>>
>>>> [1] https://github.com/wso2/siddhi/blob/master/modules/siddh
>>>> i-core/src/test/java/org/wso2/siddhi/core/query/pattern/Logi
>>>> calPatternTestCase.java#L98
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Mon, Apr 17, 2017 at 7:58 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Please see the PR at [1]. Please do not merge it.
>>>>>
>>>>>
>>>>> Thanks & Regards,
>>>>> Gobinath
>>>>>
>>>>> [1] https://github.com/wso2/siddhi/pull/313
>>>>>
>>>>>
>>>>> On Mon, Apr 17, 2017 at 7:44 AM, Sriskandarajah Suhothayan <
>>>>> s...@wso2.com> wrote:
>>>>>
>>>>>> Based on first look, it looks great.
>>>>>>
>>>>>> Can you send it as a PR so I can see the exact implementations and
>>>>>> also give comments.
>>>>>>
>>>>>> Regards
>>>>>> Suho
>>>>>>
>>>>>> On Mon, Apr 17, 2017 at 5:30 AM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> A prototype is implemented and available at [1]. Currently the query
>>>>>>> support for absent patterns and two simple pattern identifications (e

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-05-07 Thread Gobinath
Sure. I'll check the issue and send a separate PR with the fix.


Thanks & Regards,
Gobinath

On Sun, May 7, 2017 at 1:51 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Yes, it looks like a bug to me, can you check why it's happening.
>
> Regards
> Suho
>
> On Sun, May 7, 2017 at 8:56 PM, Nirmal Fernando <nir...@wso2.com> wrote:
>
>> Looks like a bug to me. I would expect only 1 event.
>>
>> On Sun, May 7, 2017 at 8:49 PM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> Thanks for accepting my proposal. I have a question regarding the
>>> behavior of *and* in a pattern.
>>>
>>> // Query: e1 and e2 -> e3
>>>
>>> define stream Stream1 (symbol string, price float, volume int);
>>> define stream Stream2 (symbol string, price float, volume int);
>>>
>>> @info(name = 'query1')
>>> from e1=Stream1[price > 50.0f] and e2=Stream2['IBM' == symbol] ->
>>> e3=Stream2[price > 20]
>>> select e1.symbol as symbol1, e2.price as price2, e3.price as price3
>>> insert into OutputStream;
>>>
>>> // Input
>>> Stream1.send(new Object[]{"GOOGLE", 72.7f, 100});
>>> Stream2.send(new Object[]{"IBM", 4.7f, 100});
>>> Stream2.send(new Object[]{"WSO2", 55.6f, 100});
>>>
>>>
>>> // Output
>>> Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6], isExpired=false}
>>> Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6], isExpired=false}
>>>
>>> Is this the expected output?. Note that the output contains two exactly
>>> similar events but the pattern *e1 -> e2 and e3* outputs a single event
>>> [1].
>>>
>>> [1] https://github.com/wso2/siddhi/blob/master/modules/siddh
>>> i-core/src/test/java/org/wso2/siddhi/core/query/pattern/Logi
>>> calPatternTestCase.java#L98
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Mon, Apr 17, 2017 at 7:58 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> Please see the PR at [1]. Please do not merge it.
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> [1] https://github.com/wso2/siddhi/pull/313
>>>>
>>>>
>>>> On Mon, Apr 17, 2017 at 7:44 AM, Sriskandarajah Suhothayan <
>>>> s...@wso2.com> wrote:
>>>>
>>>>> Based on first look, it looks great.
>>>>>
>>>>> Can you send it as a PR so I can see the exact implementations and
>>>>> also give comments.
>>>>>
>>>>> Regards
>>>>> Suho
>>>>>
>>>>> On Mon, Apr 17, 2017 at 5:30 AM, Gobinath <slgobin...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> A prototype is implemented and available at [1]. Currently the query
>>>>>> support for absent patterns and two simple pattern identifications (e1
>>>>>> -> not e2 and not e1 -> e2) are implemented. Please have a look at
>>>>>> the unit test [2] to get the idea. Class names and variable names are
>>>>>> subject to change (will finalize later). I am waiting for your feedback.
>>>>>>
>>>>>>
>>>>>> Thanks & Regards,
>>>>>> Gobinath
>>>>>>
>>>>>>
>>>>>> [1] https://github.com/lgobinath/siddhi/tree/feature-absent-
>>>>>> event-pattern
>>>>>> [2] https://github.com/lgobinath/siddhi/blob/feature-absent-
>>>>>> event-pattern/modules/siddhi-core/src/test/java/org/wso2/sid
>>>>>> dhi/core/query/pattern/EveryAbsentPatternTestCase.java
>>>>>>
>>>>>>
>>>>>> On Fri, Mar 31, 2017 at 6:28 AM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi all,
>>>>>>>
>>>>>>> Thanks Suho for your feedback. I have made the changes based on your
>>>>>>> suggestions and submitted the final proposal. Started working on a
>>>>>>> prototype and will update you soon with the results.
>>>>>>>
>>>>>>>
>>>>>>> Thanks & Regards,
>>>>>>> Gobinath
>>>

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-05-07 Thread Gobinath
Hi,

Thanks for accepting my proposal. I have a question regarding the behavior
of *and* in a pattern.

// Query: e1 and e2 -> e3

define stream Stream1 (symbol string, price float, volume int);
define stream Stream2 (symbol string, price float, volume int);

@info(name = 'query1')
from e1=Stream1[price > 50.0f] and e2=Stream2['IBM' == symbol] ->
e3=Stream2[price > 20]
select e1.symbol as symbol1, e2.price as price2, e3.price as price3
insert into OutputStream;

// Input
Stream1.send(new Object[]{"GOOGLE", 72.7f, 100});
Stream2.send(new Object[]{"IBM", 4.7f, 100});
Stream2.send(new Object[]{"WSO2", 55.6f, 100});


// Output
Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6], isExpired=false}
Event{timestamp=1494169305631, data=[GOOGLE, 4.7, 55.6], isExpired=false}

Is this the expected output?. Note that the output contains two exactly
similar events but the pattern *e1 -> e2 and e3* outputs a single event [1].

[1]
https://github.com/wso2/siddhi/blob/master/modules/siddhi-core/src/test/java/org/wso2/siddhi/core/query/pattern/LogicalPatternTestCase.java#L98


Thanks & Regards,
Gobinath

On Mon, Apr 17, 2017 at 7:58 AM, Gobinath <slgobin...@gmail.com> wrote:

> Hi,
>
> Please see the PR at [1]. Please do not merge it.
>
>
> Thanks & Regards,
> Gobinath
>
> [1] https://github.com/wso2/siddhi/pull/313
>
>
> On Mon, Apr 17, 2017 at 7:44 AM, Sriskandarajah Suhothayan <s...@wso2.com>
> wrote:
>
>> Based on first look, it looks great.
>>
>> Can you send it as a PR so I can see the exact implementations and also
>> give comments.
>>
>> Regards
>> Suho
>>
>> On Mon, Apr 17, 2017 at 5:30 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> A prototype is implemented and available at [1]. Currently the query
>>> support for absent patterns and two simple pattern identifications (e1
>>> -> not e2 and not e1 -> e2) are implemented. Please have a look at the
>>> unit test [2] to get the idea. Class names and variable names are subject
>>> to change (will finalize later). I am waiting for your feedback.
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>>
>>> [1] https://github.com/lgobinath/siddhi/tree/feature-absent-
>>> event-pattern
>>> [2] https://github.com/lgobinath/siddhi/blob/feature-absent-
>>> event-pattern/modules/siddhi-core/src/test/java/org/wso2/sid
>>> dhi/core/query/pattern/EveryAbsentPatternTestCase.java
>>>
>>>
>>> On Fri, Mar 31, 2017 at 6:28 AM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi all,
>>>>
>>>> Thanks Suho for your feedback. I have made the changes based on your
>>>> suggestions and submitted the final proposal. Started working on a
>>>> prototype and will update you soon with the results.
>>>>
>>>>
>>>> Thanks & Regards,
>>>> Gobinath
>>>>
>>>> On Thu, Mar 30, 2017 at 12:28 PM, Sriskandarajah Suhothayan <
>>>> s...@wso2.com> wrote:
>>>>
>>>>> I have given some feedback on the gsoc site.
>>>>>
>>>>> Suho
>>>>>
>>>>> On Mon, Mar 27, 2017 at 9:03 PM, Gobinath <slgobin...@gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> Thanks. I have shared the draft of my proposal titled "Non-Occurrence
>>>>>> of Events for Siddhi Patterns" with WSO2 through GSoC dashboard and
>>>>>> requesting your feedback on this.
>>>>>>
>>>>>>
>>>>>> Thanks & Regards,
>>>>>> Gobinath
>>>>>>
>>>>>> On Wed, Mar 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <
>>>>>> s...@wso2.com> wrote:
>>>>>>
>>>>>>> Thanks for the GSoC idea, I hope this will be a good way to improve
>>>>>>> the Siddhi language and make it more powerfull.
>>>>>>> If time permits we can also add other use-cases of patterns &
>>>>>>> sequences and improve it further.
>>>>>>>
>>>>>>> Since you are still not a commuter I hope these contributions will
>>>>>>> help you be a committer to Siddhi as well :)
>>>>>>> I'll make this as a formal idea, do work on a proposal as well.
>>>>>>>
>>>>>>> Regards
>>>>>

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-04-17 Thread Gobinath
Hi,

Please see the PR at [1]. Please do not merge it.


Thanks & Regards,
Gobinath

[1] https://github.com/wso2/siddhi/pull/313


On Mon, Apr 17, 2017 at 7:44 AM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Based on first look, it looks great.
>
> Can you send it as a PR so I can see the exact implementations and also
> give comments.
>
> Regards
> Suho
>
> On Mon, Apr 17, 2017 at 5:30 AM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi,
>>
>> A prototype is implemented and available at [1]. Currently the query
>> support for absent patterns and two simple pattern identifications (e1
>> -> not e2 and not e1 -> e2) are implemented. Please have a look at the
>> unit test [2] to get the idea. Class names and variable names are subject
>> to change (will finalize later). I am waiting for your feedback.
>>
>>
>> Thanks & Regards,
>> Gobinath
>>
>>
>> [1] https://github.com/lgobinath/siddhi/tree/feature-absent-event-pattern
>> [2] https://github.com/lgobinath/siddhi/blob/feature-absent-
>> event-pattern/modules/siddhi-core/src/test/java/org/wso2/
>> siddhi/core/query/pattern/EveryAbsentPatternTestCase.java
>>
>>
>> On Fri, Mar 31, 2017 at 6:28 AM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> Thanks Suho for your feedback. I have made the changes based on your
>>> suggestions and submitted the final proposal. Started working on a
>>> prototype and will update you soon with the results.
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Thu, Mar 30, 2017 at 12:28 PM, Sriskandarajah Suhothayan <
>>> s...@wso2.com> wrote:
>>>
>>>> I have given some feedback on the gsoc site.
>>>>
>>>> Suho
>>>>
>>>> On Mon, Mar 27, 2017 at 9:03 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Hi all,
>>>>>
>>>>> Thanks. I have shared the draft of my proposal titled "Non-Occurrence
>>>>> of Events for Siddhi Patterns" with WSO2 through GSoC dashboard and
>>>>> requesting your feedback on this.
>>>>>
>>>>>
>>>>> Thanks & Regards,
>>>>> Gobinath
>>>>>
>>>>> On Wed, Mar 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <
>>>>> s...@wso2.com> wrote:
>>>>>
>>>>>> Thanks for the GSoC idea, I hope this will be a good way to improve
>>>>>> the Siddhi language and make it more powerfull.
>>>>>> If time permits we can also add other use-cases of patterns &
>>>>>> sequences and improve it further.
>>>>>>
>>>>>> Since you are still not a commuter I hope these contributions will
>>>>>> help you be a committer to Siddhi as well :)
>>>>>> I'll make this as a formal idea, do work on a proposal as well.
>>>>>>
>>>>>> Regards
>>>>>> Suho
>>>>>>
>>>>>>
>>>>>> On Wed, Mar 15, 2017 at 6:09 PM, Gobinath <slgobin...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi team,
>>>>>>>
>>>>>>> This is Gobinath a former software engineer at WSO2 currently doing
>>>>>>> masters at Western University. This time I plan to do GSoC with WSO2 and
>>>>>>> this is the basic idea of what I have discussed with Suho.
>>>>>>> Based on Suho's suggestion, I come up with a proposal to implement
>>>>>>> detecting non-occurring events using Siddhi patterns. The current Siddhi
>>>>>>> patterns allow identifying the patterns that present.
>>>>>>>
>>>>>>> See an example:
>>>>>>> from every e1=Stream1[price>20] -> e2=Stream2[price>e1.price] within
>>>>>>> 1 sec
>>>>>>> select e1.symbol as symbol1, e2.symbol as symbol2
>>>>>>> insert into OutputStream;
>>>>>>>
>>>>>>> Detecting the absence of a pattern is not natively supported by
>>>>>>> Siddhi patterns for the moment. In other words, identifying event_a not
>>>>>>> followed by event_b within 2 minutes is not possible using the current
>>>>>>> patterns implementation (Note that a time frame is required otherwise we
>>

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-04-16 Thread Gobinath
Hi,

A prototype is implemented and available at [1]. Currently the query
support for absent patterns and two simple pattern identifications (e1 ->
not e2 and not e1 -> e2) are implemented. Please have a look at the unit
test [2] to get the idea. Class names and variable names are subject to
change (will finalize later). I am waiting for your feedback.


Thanks & Regards,
Gobinath


[1] https://github.com/lgobinath/siddhi/tree/feature-absent-event-pattern
[2]
https://github.com/lgobinath/siddhi/blob/feature-absent-event-pattern/modules/siddhi-core/src/test/java/org/wso2/siddhi/core/query/pattern/EveryAbsentPatternTestCase.java


On Fri, Mar 31, 2017 at 6:28 AM, Gobinath <slgobin...@gmail.com> wrote:

> Hi all,
>
> Thanks Suho for your feedback. I have made the changes based on your
> suggestions and submitted the final proposal. Started working on a
> prototype and will update you soon with the results.
>
>
> Thanks & Regards,
> Gobinath
>
> On Thu, Mar 30, 2017 at 12:28 PM, Sriskandarajah Suhothayan <s...@wso2.com
> > wrote:
>
>> I have given some feedback on the gsoc site.
>>
>> Suho
>>
>> On Mon, Mar 27, 2017 at 9:03 PM, Gobinath <slgobin...@gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> Thanks. I have shared the draft of my proposal titled "Non-Occurrence of
>>> Events for Siddhi Patterns" with WSO2 through GSoC dashboard and requesting
>>> your feedback on this.
>>>
>>>
>>> Thanks & Regards,
>>> Gobinath
>>>
>>> On Wed, Mar 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <
>>> s...@wso2.com> wrote:
>>>
>>>> Thanks for the GSoC idea, I hope this will be a good way to improve the
>>>> Siddhi language and make it more powerfull.
>>>> If time permits we can also add other use-cases of patterns & sequences
>>>> and improve it further.
>>>>
>>>> Since you are still not a commuter I hope these contributions will help
>>>> you be a committer to Siddhi as well :)
>>>> I'll make this as a formal idea, do work on a proposal as well.
>>>>
>>>> Regards
>>>> Suho
>>>>
>>>>
>>>> On Wed, Mar 15, 2017 at 6:09 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>>
>>>>> Hi team,
>>>>>
>>>>> This is Gobinath a former software engineer at WSO2 currently doing
>>>>> masters at Western University. This time I plan to do GSoC with WSO2 and
>>>>> this is the basic idea of what I have discussed with Suho.
>>>>> Based on Suho's suggestion, I come up with a proposal to implement
>>>>> detecting non-occurring events using Siddhi patterns. The current Siddhi
>>>>> patterns allow identifying the patterns that present.
>>>>>
>>>>> See an example:
>>>>> from every e1=Stream1[price>20] -> e2=Stream2[price>e1.price] within 1
>>>>> sec
>>>>> select e1.symbol as symbol1, e2.symbol as symbol2
>>>>> insert into OutputStream;
>>>>>
>>>>> Detecting the absence of a pattern is not natively supported by Siddhi
>>>>> patterns for the moment. In other words, identifying event_a not followed
>>>>> by event_b within 2 minutes is not possible using the current patterns
>>>>> implementation (Note that a time frame is required otherwise we have to
>>>>> wait for infinite time to say event_b has not arrived). The current
>>>>> workaround [1] to detect non-delivered items is shown below:
>>>>>
>>>>> from arrivals_stream#window.time(2 minutes)
>>>>> select *
>>>>> insert expired events into overdue_deliveries_stream;
>>>>>
>>>>> from every arrivalEvent = arrivals_stream ->
>>>>> deliveryEvent = deliveries_stream[arrivalEvent.trackingId ==
>>>>> trackingId]
>>>>> or overdue_delivery = 
>>>>> overdue_deliveries_stream[arrivalEvent.trackingId
>>>>> == trackingId]
>>>>> select arrivalEvent.trackingId as trackingId,
>>>>> arrivalEvent.customerName as customerName, arrivalEvent.telephoneNo as
>>>>> telephoneNo, deliveryEvent.trackingId as deliveryId
>>>>> insert into filter_stream;
>>>>>
>>>>> from filter_stream [ (deliveryId is null)]
>>>>> select trackingId, customerName, telephoneNo
>>>>> insert into alert_stream;
>>>

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-03-31 Thread Gobinath
Hi all,

Thanks Suho for your feedback. I have made the changes based on your
suggestions and submitted the final proposal. Started working on a
prototype and will update you soon with the results.


Thanks & Regards,
Gobinath

On Thu, Mar 30, 2017 at 12:28 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> I have given some feedback on the gsoc site.
>
> Suho
>
> On Mon, Mar 27, 2017 at 9:03 PM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi all,
>>
>> Thanks. I have shared the draft of my proposal titled "Non-Occurrence of
>> Events for Siddhi Patterns" with WSO2 through GSoC dashboard and requesting
>> your feedback on this.
>>
>>
>> Thanks & Regards,
>> Gobinath
>>
>> On Wed, Mar 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <s...@wso2.com
>> > wrote:
>>
>>> Thanks for the GSoC idea, I hope this will be a good way to improve the
>>> Siddhi language and make it more powerfull.
>>> If time permits we can also add other use-cases of patterns & sequences
>>> and improve it further.
>>>
>>> Since you are still not a commuter I hope these contributions will help
>>> you be a committer to Siddhi as well :)
>>> I'll make this as a formal idea, do work on a proposal as well.
>>>
>>> Regards
>>> Suho
>>>
>>>
>>> On Wed, Mar 15, 2017 at 6:09 PM, Gobinath <slgobin...@gmail.com> wrote:
>>>
>>>> Hi team,
>>>>
>>>> This is Gobinath a former software engineer at WSO2 currently doing
>>>> masters at Western University. This time I plan to do GSoC with WSO2 and
>>>> this is the basic idea of what I have discussed with Suho.
>>>> Based on Suho's suggestion, I come up with a proposal to implement
>>>> detecting non-occurring events using Siddhi patterns. The current Siddhi
>>>> patterns allow identifying the patterns that present.
>>>>
>>>> See an example:
>>>> from every e1=Stream1[price>20] -> e2=Stream2[price>e1.price] within 1
>>>> sec
>>>> select e1.symbol as symbol1, e2.symbol as symbol2
>>>> insert into OutputStream;
>>>>
>>>> Detecting the absence of a pattern is not natively supported by Siddhi
>>>> patterns for the moment. In other words, identifying event_a not followed
>>>> by event_b within 2 minutes is not possible using the current patterns
>>>> implementation (Note that a time frame is required otherwise we have to
>>>> wait for infinite time to say event_b has not arrived). The current
>>>> workaround [1] to detect non-delivered items is shown below:
>>>>
>>>> from arrivals_stream#window.time(2 minutes)
>>>> select *
>>>> insert expired events into overdue_deliveries_stream;
>>>>
>>>> from every arrivalEvent = arrivals_stream ->
>>>> deliveryEvent = deliveries_stream[arrivalEvent.trackingId ==
>>>> trackingId]
>>>> or overdue_delivery = overdue_deliveries_stream[arrivalEvent.trackingId
>>>> == trackingId]
>>>> select arrivalEvent.trackingId as trackingId, arrivalEvent.customerName
>>>> as customerName, arrivalEvent.telephoneNo as telephoneNo,
>>>> deliveryEvent.trackingId as deliveryId
>>>> insert into filter_stream;
>>>>
>>>> from filter_stream [ (deliveryId is null)]
>>>> select trackingId, customerName, telephoneNo
>>>> insert into alert_stream;
>>>>
>>>> This solution requires a time window and it is inefficient if we are
>>>> interested only on one occurrence of such a pattern (In other words same
>>>> query without every keyword). Further, the query is more complex and not
>>>> user-friendly.
>>>>
>>>> If we provide patterns to detect absence of patterns, the above query
>>>> can be rewritten as below:
>>>>
>>>> from every arrivalEvent = arrivals_stream ->  (not
>>>> deliveries_stream[arrivalEvent.trackingId == trackingId] within 2 min )
>>>> select arrivalEvent.trackingId as trackingId, arrivalEvent.customerName
>>>> as customerName, arrivalEvent.telephoneNo as telephoneNo
>>>> insert into alert_stream;
>>>>
>>>> As you can see, we can use the existing language components like not &
>>>> within. This can be achieved by extending the existing
>>>> StreamPreStateProcessors and StreamPostStateProcessors with an internal
&

Re: [Dev] [GSoC][Siddhi][CEP]: Siddhi Pattern for Absence of Events

2017-03-27 Thread Gobinath
Hi all,

Thanks. I have shared the draft of my proposal titled "Non-Occurrence of
Events for Siddhi Patterns" with WSO2 through GSoC dashboard and requesting
your feedback on this.


Thanks & Regards,
Gobinath

On Wed, Mar 15, 2017 at 1:30 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

> Thanks for the GSoC idea, I hope this will be a good way to improve the
> Siddhi language and make it more powerfull.
> If time permits we can also add other use-cases of patterns & sequences
> and improve it further.
>
> Since you are still not a commuter I hope these contributions will help
> you be a committer to Siddhi as well :)
> I'll make this as a formal idea, do work on a proposal as well.
>
> Regards
> Suho
>
>
> On Wed, Mar 15, 2017 at 6:09 PM, Gobinath <slgobin...@gmail.com> wrote:
>
>> Hi team,
>>
>> This is Gobinath a former software engineer at WSO2 currently doing
>> masters at Western University. This time I plan to do GSoC with WSO2 and
>> this is the basic idea of what I have discussed with Suho.
>> Based on Suho's suggestion, I come up with a proposal to implement
>> detecting non-occurring events using Siddhi patterns. The current Siddhi
>> patterns allow identifying the patterns that present.
>>
>> See an example:
>> from every e1=Stream1[price>20] -> e2=Stream2[price>e1.price] within 1 sec
>> select e1.symbol as symbol1, e2.symbol as symbol2
>> insert into OutputStream;
>>
>> Detecting the absence of a pattern is not natively supported by Siddhi
>> patterns for the moment. In other words, identifying event_a not followed
>> by event_b within 2 minutes is not possible using the current patterns
>> implementation (Note that a time frame is required otherwise we have to
>> wait for infinite time to say event_b has not arrived). The current
>> workaround [1] to detect non-delivered items is shown below:
>>
>> from arrivals_stream#window.time(2 minutes)
>> select *
>> insert expired events into overdue_deliveries_stream;
>>
>> from every arrivalEvent = arrivals_stream ->
>> deliveryEvent = deliveries_stream[arrivalEvent.trackingId == trackingId]
>> or overdue_delivery = overdue_deliveries_stream[arrivalEvent.trackingId
>> == trackingId]
>> select arrivalEvent.trackingId as trackingId, arrivalEvent.customerName
>> as customerName, arrivalEvent.telephoneNo as telephoneNo,
>> deliveryEvent.trackingId as deliveryId
>> insert into filter_stream;
>>
>> from filter_stream [ (deliveryId is null)]
>> select trackingId, customerName, telephoneNo
>> insert into alert_stream;
>>
>> This solution requires a time window and it is inefficient if we are
>> interested only on one occurrence of such a pattern (In other words same
>> query without every keyword). Further, the query is more complex and not
>> user-friendly.
>>
>> If we provide patterns to detect absence of patterns, the above query can
>> be rewritten as below:
>>
>> from every arrivalEvent = arrivals_stream ->  (not
>> deliveries_stream[arrivalEvent.trackingId == trackingId] within 2 min )
>> select arrivalEvent.trackingId as trackingId, arrivalEvent.customerName
>> as customerName, arrivalEvent.telephoneNo as telephoneNo
>> insert into alert_stream;
>>
>> As you can see, we can use the existing language components like not &
>> within. This can be achieved by extending the existing
>> StreamPreStateProcessors and StreamPostStateProcessors with an internal
>> timer so that they can expire their internal list of events based on the
>> time limit. It is somewhat similar to time windows but the processor can
>> turn off the timer and ignore the events if it is a one time pattern
>> detection.
>>
>> I hope it gives the basic idea and I am waiting for your suggestions and
>> feedback.
>>
>> [1] https://docs.wso2.com/display/CEP400/Sample+0111+-+Detec
>> ting+non-occurrences+with+Patterns
>>
>>
>> Thanks & Regards,
>> Gobinath
>> --
>> *Gobinath** Loganathan*
>> Graduate Student,
>> Electrical and Computer Engineering,
>> Western University.
>> Email  : slgobin...@gmail.com
>> Mobile : (+1) 416-895-0721
>> Blog: javahelps.com <http://www.javahelps.com/>
>>
>>
>
>
>
> --
>
> *S. Suhothayan*
> Associate Director / Architect & Team Lead of WSO2 Complex Event Processor
> *WSO2 Inc. *http://wso2.com
> * <http://wso2.com/>*
> lean . enterprise . middleware
>
>
> *cell: (+94) 779 756 757 | blog: http://suhothayan.blogspot.com/
> <http://suhothayan.blogspot.com/>twitter: http://twitter.com/suhothayan
> <http://twitter.com/suhothayan> | linked-in:
> http://lk.linkedin.com/in/suhothayan <http://lk.linkedin.com/in/suhothayan>*
>



-- 
*Gobinath** Loganathan*
Graduate Student,
Electrical and Computer Engineering,
Western University.
Email  : slgobin...@gmail.com
Mobile : (+1) 416-895-0721
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] WSO2 Committers += Sirojan Tharmakulasingam

2016-10-24 Thread Gobinath Loganathan
Congratulations Sirojan :-)

On Mon, Oct 24, 2016 at 10:47 AM, Rasika Perera <rasi...@wso2.com> wrote:

> Congratulations Sirojan!
>
> On Mon, Oct 24, 2016 at 10:09 AM, Prakhash Sivakumar <prakh...@wso2.com>
> wrote:
>
>> Congratz Sirojan :)
>>
>> On Mon, Oct 24, 2016 at 9:50 AM, Pamod Sylvester <pa...@wso2.com> wrote:
>>
>>> Hi Devs,
>>>
>>> It's my pleasure to welcome Sirojan Tharmakulasingam as a WSO2
>>> Committer.
>>>
>>> Sirojan is a member of Integration TG and has contributed towards
>>> development of several features for the MB product. In recognition of his
>>> contribution, dedication and commitment he has being voted as a WSO2
>>> committer.
>>>
>>> Sirojan, welcome onboard and keep up the good work
>>>
>>> Thanks,
>>> Pamod
>>> --
>>> *Pamod Sylvester *
>>>
>>> *WSO2 Inc.; http://wso2.com <http://wso2.com>*
>>> cell: +94 77 7779495
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Prakhash Sivakumar
>> Software Engineer | WSO2 Inc
>> Platform Security Team
>> Mobile : +94771510080
>> Blog : https://medium.com/@PrakhashS
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> With Regards,
>
> *Rasika Perera*
> Software Engineer
> LinkedIn: http://lk.linkedin.com/in/rasika90
>
> <http://wso2.com/signature>
>
> WSO2 Inc. www.wso2.com
> lean.enterprise.middleware
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Gobinath **Loganathan*
Software Engineer, WSO2 Inc. http://wso2.com

Email  : gobin...@wso2.com
Mobile : (+94) 770 780 210
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Architecture] [IS] [Analytics] Improvement to use Siddhi streams to send notifications

2016-07-22 Thread Gobinath Loganathan
Hi Suho and all,

The problem has been identified and fixed with the new commit [1].
According to this commit, the following changes have been done:

(1) No need to use arbitrary_ prefix anywhere.
(2) The publisher will first check for payload data, if not available it
will check for the arbitrary data. Therefore use the arbitrary data map
keys as they are. [2][3]
(3) Arbitrary data can be used in dynamic properties. [3]

[1]
https://github.com/wso2/carbon-analytics-common/commit/f1d5cafe92e9b71b884a9a4838e2cc446cf83685

[2]
https://github.com/wso2/carbon-analytics-common/blob/master/components/event-publisher/org.wso2.carbon.event.publisher.core/src/main/java/org/wso2/carbon/event/publisher/core/internal/type/text/TextOutputMapper.java#L168

[3]
https://github.com/wso2/carbon-analytics-common/blob/master/components/event-publisher/org.wso2.carbon.event.publisher.core/src/main/java/org/wso2/carbon/event/publisher/core/internal/EventPublisher.java#L339

On Fri, Jul 22, 2016 at 12:28 PM, Sriskandarajah Suhothayan <s...@wso2.com>
wrote:

>
>
> On Fri, Jul 22, 2016 at 12:00 PM, Indunil Upeksha Rathnayake <
> indu...@wso2.com> wrote:
>
>> Hi,
>>
>> Please find the meeting notes in [1].  I have following considerations
>> regarding the improvements we have discussed.
>>
>> (1) Even though we have configured to load the email template from
>> EventPublisher(analytics side), the placeholder values has to be sent as
>> meta data/correlation data/payload data/arbitrary data, since in analytics
>> side, the user claim values are not getting from the user store.
>> In order to send the placeholder values from IS side, anyway we have to
>> load the email template and retrieve the placeholders. So as I have
>> understood, for email notifications, it's not needed to use the email
>> template loading part in analytics, since it'll be a redundant task. (Refer
>> [2])
>>
>
> Here we can set the claim values as arbitrary data, and the notification
> specific details as the meta, correlation & payload data.
> Then we can use the template loading only at the analytics side.
>
>
>> (2) The email templates has to be changed as follows.
>> i) if the value will be provided in an arbitrary data map, the
>> placeholder should be with a prefix "arbitrary_"
>> (ex:{{arbitrary_givenname}})
>>
> ii) if the value will be provided in an meta data map, the placeholder
>> should be changed as {{...}} (ex:{{givenname}})
>>
>> No we should not use "arbitrary_" for any cases, its internal information
> and the names should not have "arbitrary_" even if its in arbitrary data
> map or otherwise.
>
> (3) Only Text OutputMapping Content can be filled from a value in an
>> arbitrary data map using prefix "arbitrary_" .  It's not possible to use a
>> value of an arbitrary data map, in a Dynamic adapter properties, only a
>> value from a meta data/correlation data/payload data map can be used. I
>> think that need to be extended to use even an arbitrary value as a dynamic
>> adapter property.(Refer [3])
>>
>
> @Gobi can you please fix this if that's the case.
>
>
>>
>> (4) The default stream definitions and publisher definitions has to be
>> deployed on super tenant as well as other tenants as well. And when a new
>> tenant is added, those streams and publishers has to be deployed for that
>> particular tenant as well.
>>
>> We can have a tenant creation handler to do this copying during that
> tenant creation time. WDYT?
>
> Really appreciate your ideas/suggestions regarding the above mentioned
>> concerns.
>>
>> [1] Invitation: [Architecture] [Discussion] Improvement to use Siddhi
>> str... @ Wed Jul 20, 2016 4:30pm - 5:30pm (IST) (indu...@wso2.com)
>>
>> [2]
>> https://github.com/wso2/carbon-analytics-common/blob/master/components/event-publisher/org.wso2.carbon.event.publisher.core/src/main/java/org/wso2/carbon/event/publisher/core/internal/type/text/TextOutputMapper.java#L108
>>
>> [3]
>> https://github.com/wso2/carbon-analytics-common/blob/master/components/event-publisher/org.wso2.carbon.event.publisher.core/src/main/java/org/wso2/carbon/event/publisher/core/internal/EventPublisher.java#L311
>>
>> Thanks and Regards
>> --
>> Indunil Upeksha Rathnayake
>> Software Engineer | WSO2 Inc
>> Emailindu...@wso2.com
>> Mobile   0772182255
>>
>>
>>
>
>
> --
>
> *S. Suhothayan*
> Associate Director / Architect & Team Lead of WSO2 Complex Event Processor
> *WSO2 Inc. *http://wso2.com
> * <http://wso2.com/>*
> lean . enterprise 

Re: [Dev] Carbon UI Issue with JSI18N Mapping from JavaScript

2016-05-25 Thread Gobinath Loganathan
Hi,

I found the solution. I didn't add the jsi18n declaration in the parent JSP
(In my case *create_event_publisher.jsp*) where the script was invoked.



After adding it, everything works fine.

Thanks.

Regards,
Gobinath

On Wed, May 25, 2016 at 2:00 PM, Gobinath Loganathan <gobin...@wso2.com>
wrote:

> Hi,
>
> When I use Carbon jsi18n mapping in JavaScript, it generates 'ReferenceError:
> org_wso2_carbon_event_publisher_ui_jsi18n is not defined' error in the
> browser. The page source has the variable
> *org_wso2_carbon_registry_resource_ui_jsi18n* instead of
> *org_wso2_carbon_event_publisher_ui_jsi18n*.
>
> The JSP and JavaScript code snippets are given below:
> *resources/web/eventpublisher/index.jsp:*
> ...
>   resourceBundle="org.wso2.carbon.event.publisher.ui.i18n.Resources"
>  request="<%=request%>"
>  namespace="org.wso2.carbon.event.publisher.ui"/>
> ...
>
> *resources/web/eventpublisher/js/event_publisher.js:*
> ...
>
> CARBON.showErrorDialog(org_wso2_carbon_event_publisher_ui_jsi18n["registry.resource.cache.timeout.nan"]);
> ...
>
> *org/wso2/carbon/event/publisher/ui/i18n/Resources.properties:*
> ...
> registry.resource.cache.timeout.nan=Cache timeout is not a numeric value:
> ...
>
> Could anyone suggest a solution for this?
>
> Thanks
>
> Regards,
> Gobinath
> --
> *Gobinath **Loganathan*
> Software Engineer, WSO2 Inc. http://wso2.com
>
> Email  : gobin...@wso2.com
> Mobile : (+94) 770 780 210
> Blog: javahelps.com <http://www.javahelps.com/>
>
>
>



-- 
*Gobinath **Loganathan*
Software Engineer, WSO2 Inc. http://wso2.com

Email  : gobin...@wso2.com
Mobile : (+94) 770 780 210
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Carbon UI Issue with JSI18N Mapping from JavaScript

2016-05-25 Thread Gobinath Loganathan
Hi,

When I use Carbon jsi18n mapping in JavaScript, it generates 'ReferenceError:
org_wso2_carbon_event_publisher_ui_jsi18n is not defined' error in the
browser. The page source has the variable
*org_wso2_carbon_registry_resource_ui_jsi18n* instead of
*org_wso2_carbon_event_publisher_ui_jsi18n*.

The JSP and JavaScript code snippets are given below:
*resources/web/eventpublisher/index.jsp:*
...

...

*resources/web/eventpublisher/js/event_publisher.js:*
...
CARBON.showErrorDialog(org_wso2_carbon_event_publisher_ui_jsi18n["registry.resource.cache.timeout.nan"]);
...

*org/wso2/carbon/event/publisher/ui/i18n/Resources.properties:*
...
registry.resource.cache.timeout.nan=Cache timeout is not a numeric value:
...

Could anyone suggest a solution for this?

Thanks

Regards,
Gobinath
-- 
*Gobinath **Loganathan*
Software Engineer, WSO2 Inc. http://wso2.com

Email  : gobin...@wso2.com
Mobile : (+94) 770 780 210
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] DAS 3.0.1 - Empty Dashboard for Smart Home Sample

2016-05-12 Thread Gobinath Loganathan
Hi all,
Thank you for your support. Now it is working as expected after creating
and importing a new certificate for my IP.

Thanks a lot.

On Fri, May 13, 2016 at 11:11 AM, Rukshani Weerasinha <ruksh...@wso2.com>
wrote:

> Hi all,
>
> I will update this thread as well as the Jira issue [1] once the DAS Quick
> Start Guide is updated with the relevant information.
>
> [1] DOCUMENTATION-3344 <https://wso2.org/jira/browse/DOCUMENTATION-3344>
>
> Best Regards,
> Rukshani.
>
> On Fri, May 13, 2016 at 10:59 AM, Nipuna Chandradasa <nipu...@wso2.com>
> wrote:
>
>> Hi All,
>>
>> Dashboard Server team have given few patches to solve gadget loading
>> related issues happening in a real production environment where we don't
>> use localhost. Those issues are mentioned in the mail thread i mentioned in
>> the previous mail.
>>
>> Thank you,
>>
>> On Fri, May 13, 2016 at 10:54 AM, Iranga Muthuthanthri <ira...@wso2.com>
>> wrote:
>>
>>> Think we need to have a note on the above in the QSG
>>>
>>> On Fri, May 13, 2016 at 10:51 AM, Nipuna Chandradasa <nipu...@wso2.com>
>>> wrote:
>>>
>>>> Hi Gobinath,
>>>>
>>>> Here what you have to do is to create a new certificate for your IP and
>>>> import it in to wso2carbon.jks and clienttruststore.jks.
>>>> Refer to this blog[1] for more details.
>>>>
>>>> [1].
>>>> http://udarakr.blogspot.com/2014/04/you-may-get-following-error-and-your.html
>>>>
>>>> Regards,
>>>> Marcus
>>>>
>>>> On Fri, May 13, 2016 at 10:46 AM, Gobinath Loganathan <
>>>> gobin...@wso2.com> wrote:
>>>>
>>>>> Hi Nipuna,
>>>>> I got the same error. Thank you for your help, I will have a look.
>>>>>
>>>>> For reference, I have added my console error message here:
>>>>> [2016-05-13 10:37:08,655] ERROR
>>>>> {org.apache.shindig.gadgets.render.DefaultServiceFetcher} -  Services
>>>>> methods from the https://10.100.7.87:9443/shindig/rpc endpoint could
>>>>> not be fetched. The following error occurred: javax.net.ssl.SSLException:
>>>>> hostname in certificate didn't match: <10.100.7.87> != .
>>>>> [2016-05-13 10:37:09,026]  INFO
>>>>> {org.apache.shindig.gadgets.http.BasicHttpFetcher} -  The following
>>>>> exception occurred when fetching
>>>>> https://10.100.7.87:9443/portal/store/carbon.super/gadget/Peak_Usage_Range_-_Seattle/index.xml:
>>>>> 8 ms elapsed.
>>>>> [2016-05-13 10:37:09,027]  INFO
>>>>> {org.apache.shindig.gadgets.http.BasicHttpFetcher} -
>>>>> javax.net.ssl.SSLException: hostname in certificate didn't match:
>>>>> <10.100.7.87> != 
>>>>> at
>>>>> org.apache.http.conn.ssl.AbstractVerifier.verify(AbstractVerifier.java:238)
>>>>> at
>>>>> org.apache.http.conn.ssl.BrowserCompatHostnameVerifier.verify(BrowserCompatHostnameVerifier.java:54)
>>>>> ...
>>>>>
>>>>>
>>>>> Thanks.
>>>>>
>>>>> On Fri, May 13, 2016 at 10:34 AM, Nipuna Chandradasa <nipu...@wso2.com
>>>>> > wrote:
>>>>>
>>>>>> Hi Gobinath,
>>>>>>
>>>>>> Is there any error on the console or the debug tool of the browser
>>>>>> saying IP !=  ?
>>>>>> This is not because of you don't have data. Here gadgets are not even
>>>>>> rendered. This can be because of a SSLException (Your certificate doesn't
>>>>>> match your host) or if you have a LB in front your DAS with proxy port
>>>>>> configured, shindig uses server port to render not the proxy port... so 
>>>>>> 404
>>>>>> error..
>>>>>>
>>>>>> Please have a look at mail tread mention here which is in support.
>>>>>>
>>>>>>  [DAS] Hostname issue while adding gadgets to dashboard when fronted
>>>>>> by an LB
>>>>>>
>>>>>>  Regards,
>>>>>>
>>>>>>
>>>>>> On Fri, May 13, 2016 at 10:15 AM, Gobinath Loganathan <
>>>>>> gobin...@wso2.com> wrote:
>>>>>>
>>>>>>> Hi Thanuja,
>>>>>>> I also think so. Even I executed the 'smart_home_script' m

Re: [Dev] DAS 3.0.1 - Empty Dashboard for Smart Home Sample

2016-05-12 Thread Gobinath Loganathan
Hi Nipuna,
I got the same error. Thank you for your help, I will have a look.

For reference, I have added my console error message here:
[2016-05-13 10:37:08,655] ERROR
{org.apache.shindig.gadgets.render.DefaultServiceFetcher} -  Services
methods from the https://10.100.7.87:9443/shindig/rpc endpoint could not be
fetched. The following error occurred: javax.net.ssl.SSLException: hostname
in certificate didn't match: <10.100.7.87> != .
[2016-05-13 10:37:09,026]  INFO
{org.apache.shindig.gadgets.http.BasicHttpFetcher} -  The following
exception occurred when fetching
https://10.100.7.87:9443/portal/store/carbon.super/gadget/Peak_Usage_Range_-_Seattle/index.xml:
8 ms elapsed.
[2016-05-13 10:37:09,027]  INFO
{org.apache.shindig.gadgets.http.BasicHttpFetcher} -
javax.net.ssl.SSLException: hostname in certificate didn't match:
<10.100.7.87> != 
at
org.apache.http.conn.ssl.AbstractVerifier.verify(AbstractVerifier.java:238)
at
org.apache.http.conn.ssl.BrowserCompatHostnameVerifier.verify(BrowserCompatHostnameVerifier.java:54)
...


Thanks.

On Fri, May 13, 2016 at 10:34 AM, Nipuna Chandradasa <nipu...@wso2.com>
wrote:

> Hi Gobinath,
>
> Is there any error on the console or the debug tool of the browser saying
> IP !=  ?
> This is not because of you don't have data. Here gadgets are not even
> rendered. This can be because of a SSLException (Your certificate doesn't
> match your host) or if you have a LB in front your DAS with proxy port
> configured, shindig uses server port to render not the proxy port... so 404
> error..
>
> Please have a look at mail tread mention here which is in support.
>
>  [DAS] Hostname issue while adding gadgets to dashboard when fronted by
> an LB
>
>  Regards,
>
>
> On Fri, May 13, 2016 at 10:15 AM, Gobinath Loganathan <gobin...@wso2.com>
> wrote:
>
>> Hi Thanuja,
>> I also think so. Even I executed the 'smart_home_script' manually, but
>> no luck.
>>
>> Thanks.
>>
>> On Fri, May 13, 2016 at 10:13 AM, Thanuja Uruththirakodeeswaran <
>> thanu...@wso2.com> wrote:
>>
>>> Hi Gobinath,
>>>
>>> But if the corresponding gadget datasources don't have data, It will
>>> show 'Data is not available for plotting' messgae in gadgets. I've checked
>>> this with chrome version 49.0.2623.87. But in your case, gadget is
>>> totally empty. This might be due to some other problems.
>>>
>>> Thanks.
>>>
>>> On Fri, May 13, 2016 at 9:57 AM, Thanuja Uruththirakodeeswaran <
>>> thanu...@wso2.com> wrote:
>>>
>>>> Hi Gobinath,
>>>>
>>>> I tried the same sample and can see the data in dashboards. But you
>>>> have to wait until smart_home_script spark script is get executed after you
>>>> ran the sample java client to publish the data to see the data in
>>>> dashboard. Because the spark script used for this sample
>>>> (smart_home_script) is scheduled to run every 3 minutes to copy data
>>>> received to corresponding gadgets' datasources.
>>>>
>>>> Thanks.
>>>>
>>>> On Fri, May 13, 2016 at 9:25 AM, Gobinath Loganathan <gobin...@wso2.com
>>>> > wrote:
>>>>
>>>>> Hi team,
>>>>> The Dashboard of DAS does not generate graphical charts for smart home
>>>>> application sample as expected in QuickStartGuide
>>>>> <https://docs.wso2.com/display/DAS301/Quick+Start+Guide#QuickStartGuide-DeployingthesampleC-App>
>>>>>  (Screenshot
>>>>> is attached). However, the "Data Explorer" shows the data as expected. I
>>>>> face the same problem in both Chrome and Firefox.
>>>>>
>>>>> Could anyone suggest a solution for this?
>>>>>
>>>>>
>>>>> Thanks.
>>>>>
>>>>> --
>>>>> *Gobinath **Loganathan*
>>>>> Software Engineer, WSO2 Inc. http://wso2.com
>>>>>
>>>>> Email  : gobin...@wso2.com
>>>>> Mobile : (+94) 770 780 210
>>>>> Blog: javahelps.com <http://www.javahelps.com/>
>>>>>
>>>>>
>>>>>
>>>>> ___
>>>>> Dev mailing list
>>>>> Dev@wso2.org
>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Thanuja Uruththirakodeeswaran
>>>> Software Engineer
>>>> WSO2 Inc.;http://wso2.com
>>>

Re: [Dev] DAS 3.0.1 - Empty Dashboard for Smart Home Sample

2016-05-12 Thread Gobinath Loganathan
Hi Thanuja,
I also think so. Even I executed the 'smart_home_script' manually, but no
luck.

Thanks.

On Fri, May 13, 2016 at 10:13 AM, Thanuja Uruththirakodeeswaran <
thanu...@wso2.com> wrote:

> Hi Gobinath,
>
> But if the corresponding gadget datasources don't have data, It will show
> 'Data is not available for plotting' messgae in gadgets. I've checked this
> with chrome version 49.0.2623.87. But in your case, gadget is totally
> empty. This might be due to some other problems.
>
> Thanks.
>
> On Fri, May 13, 2016 at 9:57 AM, Thanuja Uruththirakodeeswaran <
> thanu...@wso2.com> wrote:
>
>> Hi Gobinath,
>>
>> I tried the same sample and can see the data in dashboards. But you have
>> to wait until smart_home_script spark script is get executed after you ran
>> the sample java client to publish the data to see the data in dashboard.
>> Because the spark script used for this sample (smart_home_script) is
>> scheduled to run every 3 minutes to copy data received to corresponding
>> gadgets' datasources.
>>
>> Thanks.
>>
>> On Fri, May 13, 2016 at 9:25 AM, Gobinath Loganathan <gobin...@wso2.com>
>> wrote:
>>
>>> Hi team,
>>> The Dashboard of DAS does not generate graphical charts for smart home
>>> application sample as expected in QuickStartGuide
>>> <https://docs.wso2.com/display/DAS301/Quick+Start+Guide#QuickStartGuide-DeployingthesampleC-App>
>>>  (Screenshot
>>> is attached). However, the "Data Explorer" shows the data as expected. I
>>> face the same problem in both Chrome and Firefox.
>>>
>>> Could anyone suggest a solution for this?
>>>
>>>
>>> Thanks.
>>>
>>> --
>>> *Gobinath **Loganathan*
>>> Software Engineer, WSO2 Inc. http://wso2.com
>>>
>>> Email  : gobin...@wso2.com
>>> Mobile : (+94) 770 780 210
>>> Blog: javahelps.com <http://www.javahelps.com/>
>>>
>>>
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Thanuja Uruththirakodeeswaran
>> Software Engineer
>> WSO2 Inc.;http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: +94 774363167
>>
>
>
>
> --
> Thanuja Uruththirakodeeswaran
> Software Engineer
> WSO2 Inc.;http://wso2.com
> lean.enterprise.middleware
>
> mobile: +94 774363167
>



-- 
*Gobinath **Loganathan*
Software Engineer, WSO2 Inc. http://wso2.com

Email  : gobin...@wso2.com
Mobile : (+94) 770 780 210
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] DAS 3.0.1 - Empty Dashboard for Smart Home Sample

2016-05-12 Thread Gobinath Loganathan
Hi team,
The Dashboard of DAS does not generate graphical charts for smart home
application sample as expected in QuickStartGuide
<https://docs.wso2.com/display/DAS301/Quick+Start+Guide#QuickStartGuide-DeployingthesampleC-App>
(Screenshot
is attached). However, the "Data Explorer" shows the data as expected. I
face the same problem in both Chrome and Firefox.

Could anyone suggest a solution for this?


Thanks.

-- 
*Gobinath **Loganathan*
Software Engineer, WSO2 Inc. http://wso2.com

Email  : gobin...@wso2.com
Mobile : (+94) 770 780 210
Blog: javahelps.com <http://www.javahelps.com/>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev