Can my application request the same RIC multiple times?
I have a question about what happens if my application requests the same RIC multiple times. What happens? Will the API warn me that I already have it? What should I do to check or guard against this happening? I saw this article (link) but it didn't answer my question. Thank you. API is EMA Java v4.1.
https://community.developers.refinitiv.com/questions/10057/subscribing-to-ric-multiple-times.html
Best Answer
-
Hello @mark.ringrose,
For EMA this is a valid request, so there will be no warning. EMA will establish two streams on behalf of the consumer, each with it's own streamId. The consumer will process every update twice, once on each stream ID, so if one is printing the updates, each update will be seen twice.
For example:
UpdateMsg
streamId="5"
domain="MarketPrice Domain"
updateTypeNum="0"
name="JPY="
serviceId="300"
serviceName="ELEKTRON_EDGE"
Payload dataType="FieldList"
FieldList
FieldEntry fid="114" name="BID_NET_CH" dataType="Real" value="0.47"
FieldEntry fid="372" name="IRGPRC" dataType="Real" value="0.44"
FieldListEnd
PayloadEnd
UpdateMsgEnd
EmaRdm.INSTRUMENT_UPDATE_UNSPECIFIED
UpdateMsg
streamId="6"
domain="MarketPrice Domain"
updateTypeNum="0"
name="JPY="
serviceId="300"
serviceName="ELEKTRON_EDGE"
Payload dataType="FieldList"
FieldList
FieldEntry fid="114" name="BID_NET_CH" dataType="Real" value="0.47"
FieldEntry fid="372" name="IRGPRC" dataType="Real" value="0.44"
FieldListEnd
PayloadEnd
UpdateMsgEndIf you would prefer for this not to happen, at the point of registerClient, would check if the subscription is unique.
Does this address the question?
0
Answers
-
Zoya,
Thank you very much for your prompt reply. It does address the question. One further question on your reply: In your final sentence you say: "If you would prefer for this not to happen, at the point of registerClient, would check if the subscription is unique."
Does the registerClient method respond with a flag or indicator to tell me if the subscription is unique? So, do I just have to check this flag or do I need to do something special to find out if the subscription is unique?
Thank you.
0 -
Each subscription returns a handle. Please look up registerClient() and handle(), in Reference.
Each event carries the handle, i.e. event.handle, so one can match the two, the registration and the event, this way. The intention of the handle:
- is to match the event seen in a callback with subscription
- to unregister
- to reissue
- not to determine if it is unique in terms of item
In order not to register for the same item twice, the consumer keeps track of and controls what it passes into registerClient
Please note that one may also require register for two of the same item with different Domain Model, i.e. L1 and L2, which is also a legit use, and will result in two different handles with two different streamIds.
Please note, that one can pass parameter closure into registerClient that may help keeping track of uniqueness, among other things. If we generate a closure in a way that uniquely defines every item registration, and store and keep the closures that have been used prior, we can always check if the registration is unique.
0
Categories
- All Categories
- 6 AHS
- 39 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 367 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 60 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛