question

Upvotes
Accepted
7 1 0 7

Java EMA Disconnection due to Client application did not ping and Overflow Condition

Java EMA Disconnection due to Client application did not ping and/Or Overflow Condition. Are both condition linked to each other. How can we configure application to avoid this issue.

#technologyema-api
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
Upvotes
Accepted
14.3k 30 5 10

Hi @vikas.chaudhary ,

The overflow condition can block the application from responding to the ping message. Hence, fixing the overflow condition should help fix this issue.

Regarding the overflow condition, I found the answer below posted by my colleague in this thread

One of the most common causes for Consumer disconnects is a 'Slow Consumer' scenario. Increasing Guaranteed output buffers can only help so far - e.g. for short-lived periods of increased update rates.

If the consumer is processing the updates too slowly, then eventually the buffers on the server you are connecting to will overflow and you would be disconnected.

I cannot tell from the log file, if this is the case here - so you would need to speak to either your internal RTDS team (if you are connecting to an internal ADS) OR our Refinitiv Real-Time Optimized team (if you are connecting to RTO) - so that they can check the logs on the server you are connecting to, to get some clues as to why your consumer is being logged out so often.

If they do confirm that they are seeing buffer overflow scenarios, then you need to modify your code so that less processing is done in the main API thread - the onUpdateMsg and onRefreshMsg callbacks are executed on the main API thread. And the longer you hold onto that thread, the less time the API can spend reading data from the server in a timely manner.

The following article refers to one of our Legacy APIs - however, the same slow consumer scenario could be the case for you and the same solutions could also help you - e.g. worker threads or Horizontal scaling OR a combination of both :
How to Diagnose and Solve Out-of-Memory Issues in RFA Java Applications | Refinitiv Developers

The following example included with RT-SDK is a simple demonstration of Horizontal Scaling

RTSDK-JAVA\Java\Ema\Examples\src\main\java\com\refinitiv\ema\examples\training\consumer\series400\ex410_MP_HorizontalScaling

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.