Hello, has anyone come across below issues:
1) Sometimes websocket connection is not establishing
2) Sometimes there is no response from Refinitiv
How to solve this issue?
Hello @techlead @Bhavik
Could you please clarify the "We are generating a new access token every 5 seconds" message? Why does the application refresh token every 5 seconds?
It would be nice if you can post a cutdown version of your code that can replicate the issue to let us check in detail.
### RTO Access Token time ###
The Access Token expiration time is based on the "expires_in" information value. The default expires_in is 600 seconds (10 minutes), so the application should refresh a token with RDP and re-send a new access token to the WebSocket server every 90% of the initial time before it expires (aka 9 minutes), not every 5 seconds.
### RTO Workflow ###
Please let me explain more about the RTO WebSocket connection workflow. The WebSocket - RTO connection workflow is a mix of the RDP APIs HTTP and WebSocket API workflows. The workflow summaries are as follows.
You can see more detail on the RTO Python market_price_rdpgw_service_discovery.py example (the code is in Python, but the concept is the same for all languages).
I strongly suggest the client read the WebSocket API: Connect to Refinitiv Real-Time - Optimized tutorial.
There is the Article.WebSocketAPI.Javascript.QuoteWidget and Example.ERT.Javascript.ERTController JavaScript examples for RTO (and RTDS) that you can check the workflow above with JavaScript code.
Hello @techlead
I am sorry to hear that you are facing those issues. Are you connecting to your local RTDS or RTO? Can you replicate the issue on demand with the WebSocket API examples?
About the "Sometimes there is no response from Refinitiv", the WebSocket API is a server-side API, so you may need to contact the server team to verify the issue on the server side. I highly recommend you contact the Real-Time support team from https://my.refinitiv.com/content/mytr/en/helpandsupport.html website.
Hello,
Posting on behalf of @techlead
Hi @wasin.w - client is using RTO and there is a case 12669770 open with platform support who are unable to see disconnection. the last error on the case is - "Undefined data issue was from our end. We are generating a new token every 5 seconds and after some random duration the websocket connection is not established."
Below is a snippet of the comms with support after 10-July.
Platform support:
I cross referenced your logs with our logs on the backend. But I do not see any disconnections.
Have you implemented the 4 minute refresh logic? Did it resolve the undefined data retreival?
Client:
We tried the solution specified by you, but the same issue persists. We are generating a new access token every 5 seconds then too after 8-10 minutes our connection is getting lost and we are unable to connect to websocket again.
Wasim, need your assistance on the same topic.