Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When executing siddhi with JMeter the execution fails because RAM usage is too high. #1233

Closed
cosdrago opened this issue Apr 24, 2019 · 2 comments
Assignees
Milestone

Comments

@cosdrago
Copy link

Description:
When trying to simulate an event-stream with JMeter and use it as source on siddhi it works for a little time but ends with RAM being overused and the execution of the program stops.

I tried executing the code with a database,without a database, using a partition to get the events one by one.

Affected Siddhi Version:
WSO2 Stream Processor latest version.

OS, DB, other environment details and versions:

The virtual machine where this is setup has 8GB RAM, 4 CPU.

Steps to reproduce:

This is the stream code:

@source(type = 'http',
receiver.url='http://172.23.3.22:8007/insertSweetProduction',
basic.auth.enabled='false',
@Map(type='json', @attributes( tipoDato='$.tipoDato', fecha='$.fecha', valor='$.valor', servicio='$.servicio')))
define stream insertSweetProduction (tipoDato string, fecha string, valor double, servicio string);

This is the sink stream:

@sink(type='file',
@Map(type='json'),
@attributes( tipoDato='$.tipoDato', fecha='$.fecha', valor='$.valor', servicio='$.servicio'),
file.uri='/dev/null')
define stream fileSweetProduction (tipoDato string, fecha string, valor double, servicio string);

And this is the query executed to copy from one stream to another:

@info(name='query2')
from insertSweetProduction
select tipoDato,fecha,valor,servicio
insert into fileSweetProduction;

The expected results are that the wso2worker would show that all the events were processed and inserted on the sink stream. On JMeter I am simulating 1 user introducing 6000 events during 1 hour and it looks like the memory ends up overused and the simulation stops. Tried with partition and the memory usage improved a lot but still ended up in failure. All I can think is that is a coding problem but cant seem to find anything that could cause this.

@suhothayan
Copy link
Contributor

Have you found a fix for this problem?
Please share your feedback we can then work on that.

@niveathika
Copy link
Member

niveathika commented Apr 26, 2019

The same question was raised in SO as well, As per the feedback, seems changing the file.uri from /dev/null to a valid file URL solved the issue. [1]

I have opened a new issue in siddhi-io-file to track this matter.

[1] https://stackoverflow.com/questions/55831010/when-trying-to-execute-an-siddhi-app-using-an-event-stream-generated-by-jmeter-t

@mohanvive mohanvive added this to the 5.0.1 milestone Jun 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants