Siddhi application always repeated start
yourgentlesmile opened this issue · 5 comments
Description:
I try to run siddhi application with the siddhi-sdk but ,I found that the siddhi-application will always repeated start-action.
This is the command-line when I started application:
F:/studySoftware/siddhi-sdk-1.0.0\bin\siddhi.bat run E:/CompanyProj/siddhiDemo/src/com/pop.siddhi
Here is the result :
[org.wso2.extension.siddhi.io.http.source.HttpConnectorPortBindingListener] : siddhi: started HTTP server connector localhost:8081
[org.wso2.extension.siddhi.io.http.source.HttpSourceListener] : Source Listener has created for url http://localhost:8081/Api/public/test
[org.wso2.extension.siddhi.io.http.source.HttpSourceListener] : Source Listener has created for url http://localhost:8081/Api/public/test
ERROR [org.wso2.siddhi.core.stream.input.source.Source] - Error on 'TestExecutSionPlan'. Listener URL http://localhost:8081/Api/public/test already connectedError while connecting at Source 'http' at 'FooStream'.
org.wso2.siddhi.core.exception.SiddhiAppCreationException: Error on 'TestExecutSionPlan'. Listener URL http://localhost:8081/Api/public/test already connected
at org.wso2.extension.siddhi.io.http.source.HttpConnectorRegistry.registerSourceListener(HttpConnectorRegistry.java:143)
The bug info obviously show the problem,the application will start when it is already started
Also,I use the siddhi-io-kafka,the problem exist too.the log shows that the kafka-consumer will be created again and again.
So, I guess that this may be a bug
siddhi application source code:
@App:name('testSiddhi')
--@source(type='kafka',
-- topic.list='localtopic',
-- partition.no='1',
-- threading.option='single.thread',
-- group.id="test",
-- bootstrap.servers='localhost:9092',
-- @map(type='json'))
@source(type = 'http',
receiver.url='http://localhost:8081/Api/public/test',
basic.auth.enabled='false',@map(type='json'))
define stream FooStream (symbol string, price float, volume long);
--
--@sink(type='kafka',
-- topic='resulttopic',
-- partition.no='0',
-- bootstrap.servers='localhost:9092',
-- @map(type='json')
--)
@sink(type='log', prefix="LOGGER")
define stream OutputStream (symbol string, price float, volume long,multiple float);
@info(name = 'query1')
from FooStream select symbol, price, volume,(price * volume) as multiple insert into OutputStream;
By the way,I also use Stream Processor Studio to test my code.it run successfully~
Affected Product Version:
Siddhi-SDK 1.0.0
OS, DB, other environment details and versions:
Windows 10 , Idea Version: 2017.3.3 ,Siddhi-plugin-Idea 1.1.0
Steps to reproduce:
- Write a siddhi code ,and run it with siddhi-sdk.......
Generally speaking~ I don't know how to describle the step to reproduce it . There are normally step to run a application with siddhi-sdk.I strictly follow the guide to build it~
Thank you ~QvQ
Thank you for reporting this issue. We will look into this. Meantime you can use the Stream Processor Studio.
Thank you for fix it ~~~, (≧ω≦)/
@yourgentlesmile please find the latest available sdk here. Please try out and see.
Thanks ,I will try it and tell you the result~ Thank you ╮( ̄▽ ̄)╭
@RAVEENSR It worked well, Thank you ~( • ̀ω•́ )✧