Discover Refinitiv
MyRefinitiv Refinitiv Perspectives Careers
Created with Sketch.
All APIs Questions & Answers  Register |  Login
Ask a question
  • Questions
  • Tags
  • Badges
  • Unanswered
Search:
  • Home /
  • Elektron /
avatar image
Question by pratik.p.mehta · Jul 26, 2019 at 02:41 PM · ematrepETA

Item Resubscription

So we open a session for subscription for an item say AAPL.OQ, get some refresh and updates, then close the subscription using CloseMsg with below params:

closeMsg.clear();
encodeIterator.clear();
closeMsg.msgClass(MsgClasses.CLOSE);
closeMsg.containerType(DataTypes.NO_DATA);
closeMsg.flags(CloseMsgFlags.ACK);
byteBuffer.clear();
encodeBuffer.clear();
encodeBuffer.data(byteBuffer);

encodeIterator.setBufferAndRWFVersion(encodeBuffer, Codec.majorVersion(), Codec.minorVersion());

Now within the same session, I want to resubscribe to AAPL.OQ, I see that though my request for subscription is sent to TREP, I don't get any responses (refresh messages) back.

How to resubscribe after unsubscription within the same session

People who like this

0 Show 0
Comment
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

2 Replies

  • Sort: 
avatar image
REFINITIV
Best Answer
Answer by jirapongse.phuriphanvichai · Jul 30, 2019 at 03:43 AM

@pratik.p.mehta

To close a stream, you need to specify the streamID of the closed item.

closeMsg.clear();
closeMsg.msgClass(MsgClasses.CLOSE);
closeMsg.streamId(streamId());
closeMsg.domainType(domainType);
closeMsg.containerType(DataTypes.NO_DATA);

After that, you can send a new request message to subscribe to that item.

You can refer to the com.thomsonreuters.upa.examples.consumer example in the Elektron SDK package regarding closing and requesting items.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
REFINITIV
Answer by umer.nalla · Jul 30, 2019 at 10:11 AM

Hi @pratik.p.mehta

Depending on your use case / requirements - you may want to explore the Pause / Resume functionality available with the Elektron APIs.

As the name suggests, you can pause an event stream and resume it as required - for some scenarios this can be more efficient than close and resubscribe.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

Watch this question

Add to watch list
Add to your watch list to receive emailed updates for this question. Too many emails? Change your settings >
10 People are following this question.

Related Questions

Updated and Latest enumtype.def and RMDFieldDictionary Files

While using EMA or ETA do you have any field like “line time” which would indicate the time at which data left the exchange?

In NASDAQ Basic is QUOTIM_MS, the time exchange received the quote or the time at which the quote left the exchange?

Choosing an API to contribute/Post data to TREP

Payload message processing for TREP

  • Feedback
  • Copyright
  • Cookie Policy
  • Privacy Statement
  • Terms of Use
  • Careers
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Alpha
  • App Studio
  • Block Chain
  • Bot Platform
  • Calais
  • Connected Risk APIs
  • DSS
  • Data Fusion
  • Data Model Discovery
  • Datastream
  • Eikon COM
  • Eikon Data APIs
  • Electronic Trading
    • Generic FIX
    • Local Bank Node API
    • Trading API
  • Elektron
    • EMA
    • ETA
    • WebSocket API
  • Legal One
  • Messenger Bot
  • Messenger Side by Side
  • ONESOURCE
    • Indirect Tax
  • Open PermID
    • Entity Search
  • Org ID
  • PAM
    • PAM - Logging
  • ProView
  • ProView Internal
  • Product Insight
  • Project Tracking
  • Refinitiv Data Platform
    • Refinitiv Data Platform Libraries
  • Rose's Space
  • Screening
    • Qual-ID API
    • Screening Deployed
    • Screening Online
    • World-Check One
    • World-Check One Zero Footprint
  • Side by Side Integration API
  • TR Knowledge Graph
  • TREP APIs
    • CAT
    • DACS Station
    • Open DACS
    • RFA
    • UPA
  • TREP Infrastructure
  • TRIT
  • TRKD
  • TRTH
  • Thomson One Smart
  • Transactions
    • REDI API
  • Velocity Analytics
  • Wealth Management Web Services
  • World-Check Data File
  • Explore
  • Tags
  • Questions
  • Badges