Giuseppe Corti
Hi Vinoth Kumar,
The only way to influence the memory held by the server is through the 'clear snapshot' request that your Data Adapter can issue for the subscribed Items.
But it would be preferable to investigate the issue to determine where the leak resides and resolve it.
Regards,
Giuseppe
rvkvino
Hello,
i have created an adopter and connecting XXX number of different sites and streaming the data. on each time gap for example from the start time of the adopter on every 12 hours approximately it get stuck in peak hours. We need to know is there any memory limitations for each adopter which we build or any other limitation to be cleared on periodical basis.
If I restart my adapter 2 times per day then working fine without any issue.
And also I need to know how dynamically clear snapshot and recreate snapshot. It should be clear if data adapter held my memory issue or if it is any periodically need to clear the snapshot.
Giuseppe Corti
Are there in your adapters code some data structure as a queue or a map? Indeed these are potential candidates to generate memory leaks since they can grow indefinitely if not properly managed.
The Lightstreamer server releases the memory occupied by the snapshot for an Item in two cases:
1. no more client subscribe the involved Item;
2. the Data Adapter esplicitily call the clearSnapshot.
That said, have you tried to check the statistics of the memory occupied looking for the MonitorText logger lines?
If configured at the trace level it records the information every 2 seconds and can give a general overview of the progress of the memory.
Regards,
Giuseppe
rvkvino
Hello,
Now I have an issue like when the user close the tab that time session and connection automatically managed by lightstreamer. But when I check in my windows server currPorts in 8080 lot of connection in Time Wait and Close Wait status. Could you please let me know how the connection properly close in LS adapter or LS server. Because If connection in Close Wait or Time_Wait means lot of resources are using and getting memory leak and high CPU usages. So Please let me know the proper way to avoid this issue.
Giuseppe Corti
Hi Vinoth Kumar,
You could call explicitly the
disconnect() method but I don't know if in your client you can properly identify how trigger the call.
In any case TIME_WAIT and CLOSE_WAIT on the tcp sockets are strongly dependent on any network intermediary like proxies or other devices in the middle between client and server.
Regards,
Giuseppe
rvkvino
Hello,
I need some assistant on TCP port, When I check my server ports more that 3000 ports established state in 8080 port with the process name of java.exe. I have an remote adapter and having more number of clients for my site. I have a doubt as for every client connection whether one java.exe will be start ? Or what is the flow of establishing the java.exe process on 8080 port?
Giuseppe Corti
Hi Vinoth Kumar,
No, I confirm that no java.exe have to start for each new client connection.
The picture you attached is quite small, but it seems however that the process id is always the same and therefore correctly all the tcp connections are handle by the same jvm running the Lightstreamer server.
The jvm running the Lightstreamer server listens on the tcp ports defined in your lightstreamer_conf.xml and then for each a client connection a dedicated tcp connection is established.
You can check the number of tcp connections established managed by the server in the log (MonitorText lines) or in the Monitoring Dashboard.
Regards,
Giuseppe
rvkvino
Hello,
Could you please check now in this link
http://logimaxdemo.in/2018-07-20remotels.png. I have attached clear screenshot now. The issue is now opening multiple java.exe process for 8080 port.
Giuseppe Corti
Hi Vinoth Kumar,
As you can see from the process id column, which always contains the same value, the java.exe process is just only one.
The situation is correct, as you have to expect a connection established for each client connected to the server.
This is not an issue.
Regards,
Giuseppe
rvkvino
Hello,
But my server persons are saying there is the cause of the issue is due to the java application that's being run and is creating many connections to the server and not closing them properly. And the servers seems to have usage and there are many "ESTABLISHED" states in 8080 port. They are saying more process in 8080 with established and Time_wait state for java.exe. This only issue to get 100% cpu usages. I need your suggestion and help to solve this issue.
Giuseppe Corti
Hi Vinoth Kumar,
But please let me stress out that this is not an issue, it is normal that your server has an established connection for each connected client.
If you want to handle 50K concurrent clients you have to expect 50K tcp ports established in your server.
And also a certain number of tcp connections in Time_Wait or Close_Wait is also expected especially if you have a high rate of session turnover, ie sessions that start and end continuously.
Regards,
Giuseppe