When is a message FINAL
What flags or statuses should we use to identify a final message for a given stream id?
Currently, my application uses
public boolean isFinal() {
Msg msg = decodeMsg();
return msg.isFinalMsg() || msg.msgClass() == MsgClasses.ACK;
}
Is this logic correct or we need to look for other markers in response
The application maintains a map of stream ids to their corresponding messages
Whenever the message is marked as final using isFinal() as shown above, we remove it from the map
However, what is noticed is we still get updates for those stream ids
What is the right approach?
Best Answer
-
As you may have noted in the developer guide, the isFinalMsg() is the mechanism for confirming if a message is the final Msg on that Stream and no further messages should be received.
Therefore, if you are observing instances where you continue to receive further messages on a stream after the isFinalMsg(), then you need to trace all incoming and outgoing messages on the channel when running your app - to a file. This XML trace can then be used to confirm if indeed you are receiving additional messages AFTER the final message. If this is the case, you would need to raise a ticket with our Premium support system and attach the trace file, so that it can be investigated offline.
For an example of how to capture all message to a trace file, I recommend you refer to the Consumer example which traces the message to an XML file when a -x parameter is provided on the command line..
In terms of the AckMsg / CloseMsg comment in the - when you as a Consumer send a CloseMsg to explicitly close a stream, you can optionally specify a flag indicating that you want to receive an AckMsg to confirm if the CloseMsg was accepted - this is not the same as the final Msg you receive on a Stream.
1
Answers
-
Can you please clarify why you are treating an AckMsg as Final?
One possible explanation for what you are observing:
You open a stream for an item in order to perform OnStream posting, you perform an OnStream post using its stream id. After which you can expect to get an AckMsg which does NOT have isFinalMsg() set. Upon receipt of that AckMsg, (based on your above code snippet) if you then remove the corresponding stream id from your Map, the stream will still be open and you could get further updates on that stream.
0 -
Hi Umer, we don't post anything into TREP, we only consume
Also, from the documentation, it says for ACK Message: A provider uses AckMsg to inform a consumer of success or failure for a specific PostMsg or CloseMsg. This is the reason why the logic accounts for Ack
Not sure what is the best way to consider a message as closed
0 -
Thank you for the explanation - where can we all such detailed documentation?
Could you share any links?
0
Categories
- All Categories
- 6 AHS
- 39 Alpha
- 162 App Studio
- 4 Block Chain
- 5 Bot Platform
- 17 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
- 370 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 中文论坛