question

Upvote
Accepted
100 4 4 7

repeatedly call rsslInitChannel when channel in Initializing state?

In my dev env, my test program called 16,000 times within 50ms. Do we have to repeatedly call rsslInitChannel when channel in Initializing state?

elektronrefinitiv-realtimeelektron-sdkrrteta-apielektron-transport-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.

1 Answer

Upvotes
Accepted
1.2k 23 28 42

Yes, the documentation states one only needs to call RsslInitChannel when the socket indicates you can read without blocking.

For TCP transports the protocol works fine when only calling on write-without-blocking event and ignoring read-without-blocking. Note that the examples do neither and simply call based upon an elapsed timer.

Example consumer event loop ignoring read-without-blocking.

From RDC Case: 04096919 when using the Java API, the documentation states:

Typically, calls to the Channel.init method are driven by I/O on the connection, however this can also be accomplished by using a timer to periodically call the method or looping on a call until the channel transitions to active or a failure occurs. Other than any overhead associated with the method call, there is no harm in calling init more frequently than required. If no work is required at the current time, the method will return and indicate that connection is still in progress.

"In short, there are two way to initialize the channel. Using a timer or loop to call the init method until the channel transitions to active or a failure occurs Using I/O driven to call the init method"

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