question

Upvotes
Accepted
13 2 1 2

EMA Java questions on Subscription methods, simultaneous sessions and perf stats

  • When OmmConsumer.registerClient already subscribes 100 items, how it can subscribe another 10 items?
  • Can OmmConsumer.registerClient be initialized several times to establiashed concurrent subscriptions in one Java app?
  • How EMA Java based App can figure out how many RICs are subscribed from the connected ADS?
  • Do we have any performance metrics for EMA Java testing, e.g. how many updates/second?
elektronrefinitiv-realtimeelektron-sdkrrtema-apielektron-message-api
icon clock
10 |1500

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

Upvote
Accepted
20.3k 73 10 20

Hi @tony.zhu

You can call registerClient() as many times as you want - as and when required as per your application requirments. The examples generally do this once at the start only because they are just simple examples.

It can be called for individual RICs or for Batch requests (e.g. example370__MarketPrice__Batch) - as arequired.

You can also use multiple OmmConsumer instances if required - but generally, this is only done if using Horizontal Scaling where you want to share the load between multiple threads and each OmmConsumer instance is executed on its own thread. e.g. a client developer I worked with split there 80,000 RIC list (with quite high volatility) between 2-3 OMMConsumer instances on there multi-core CPU hardware.

Your Market Data team can use ADS diagnostic tools to monitor how many items are open on each connection. OR you can just keep track at your application by maintaining a counter when you make a request (using registerclient()) and then get back a valid Initial Refresh / Closed Status message - accordingly. Note that sometimes you may get back an Unsolicited Refresh for an already open item - so this should not be used to increment your counter.

You can also close an item when no longer required by calling unregisterClient() with the item handle. - handle is returned when calling registerClient() or can be extracted from the OmmConsumerEvent you receive in the Event handlers (onRefreshMsg, onUpdateMsg etc).

EMA Java can potentially handle hundreds of thousands of updates a second - but this depends greatly on many factors such as update size, your PC specifications, network speed and how long you spend processing each update in the onRefreshMsg and onUpdateMsg event handlers of your application.

We don't have any official performance figures - but when I co-presented a session on Performance Coding at our Developer event last year, a colleague did some basic performance tests and was able to achieve just under 400,000 updates a second when subscribing to 5000 items on a fairly powerful developer laptop. This was not a scientific test - but was done purely to provide a rough indication of what is possible.

In the EMA\PerfTools folder of your ElektronSDK you will find some source code you can use to do your own performance tests - using your own RIC list on your hardware, network etc.


icon clock
10 |1500

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

Upvotes
13 2 1 2

Thanks for your quick and detailed clarifications.

icon clock
10 |1500

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

Click below to post an Idea Post Idea