Needed your help in solving few use cases.

6 views
Skip to first unread message

Nilesh Kumar

unread,
Feb 5, 2024, 5:24:33 AM2/5/24
to siddhi-dev
Hi, 

I wanted to process the list coming from Databases at one sort and calculate the average on the list. Here my event is not generated as it's created. 

I wanted to process small batch of data a one short using siddhi CEP.It's not on every events. 

Senthuran Ambalavanar

unread,
Feb 5, 2024, 11:18:16 AM2/5/24
to Nilesh Kumar, siddhi-dev
Hi Nilesh,


On Mon, Feb 5, 2024 at 3:54 PM Nilesh Kumar <nilesh...@gmail.com> wrote:
Hi, 

I wanted to process the list coming from Databases at one sort and calculate the average on the list. Here my event is not generated as it's created. 
To perform a join with a database table and get data out of it, we must have a stream event triggered. You can trigger an event by calling an exposed HTTP source [1] , or with a start trigger [2] (which executes at the start of the Siddhi app). Then you can send that event to a stream, join it with a table, and calculate the average.

define trigger StartTrigger at 'start';

@source(type='http', receiver.url=... )
define stream HttpInputStream(...);

from StartTrigger
-- or
-- from HttpInputStream
select *
insert into JoinStream;

-- Join `JoinStream` with database table, then calculate the avg



Thanks,
Senthuran.
 

I wanted to process small batch of data a one short using siddhi CEP.It's not on every events. 

--
Siddhi homepage: http://siddhi.io/
Siddhi Github repo: https://github.com/siddhi-io/siddhi
 
You received this message because you are subscribed to the Google Groups "Siddhi-dev" group.
To post to this group, send email to siddh...@googlegroups.com
To unsubscribe from this group, send email to siddhi-dev+...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/siddhi-dev?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups "siddhi-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to siddhi-dev+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/siddhi-dev/4828d0a6-67b1-45e0-8d50-d05dce839d56n%40googlegroups.com.


--
Senthuran Ambalavanar | Associate Technical Lead | WSO2 LLC
Reply all
Reply to author
Forward
0 new messages