Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
87 10 13 14

Correct usage of the Timeseries API after a timeout when waiting for Eikon login

When DataServicesFactory.Create() is called, Eikon Terminal will be automatically started up by the API, bringing up the login dialog. Our question is how to correctly handle when the user is not entering the credentials for a prolonged time.

This is the flow of status updates coming via the callbacks registered in DataServicesFactory.Create():

Virtually immediately:

  • IConnectionInformation.State=StartingInitialization, Message=Starting Data Services initialization.
  • IConnectionInformation.State=LaunchingEikon, Message=Try start/wake up Eikon.

After three minutes:

  • AggregateException.Message=Unable to start automatically Eikon after 60 attempts. Please make sure Eikon is correctly installed on this computer.

Apparently this error is a fatal one, i.e. logging in afterwards will not lead to a success callback with a valid IDataServices object passed in.
We are currently handling this situation by calling DataServicesFactory.Create() again, which will then lead to the above status updates again. We will repeat this until the user has finally logged in, so Create() may be called quite a number of times (with about three minutes time inbetween)
The problem however is, that if the user does not log in for hours or even days, the computer is starting to become unstable, probably due to a resource exhaustion of some kind.
We are wondering if calling DataServicesFactory.Create() subsequently (if the first call fails) from the same process could be the culprit.
What would be the proposed way of cleanly handling above situation?

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-api
icon clock
10 |1500

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

Hi @GoGoGroundhog

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?

If so please can you click the 'Accept' text next to the appropriate reply. This will guide all community members who have a similar question.

Thanks,

AHS

Upvotes
Accepted
39.4k 77 11 27

Now I'm not quite sure I understand the scenario you describe. In either of the events (automatic logout on weekends or logout due to exclusive sign on event) you already have IDataServices object initialized. When either of these events occur your application will be notified via StateChanged event of IDataServices. Are you saying that when you receive StateChanged event and IDataServices.State value is Down you immediately call DataServicesFactory.Create()? I don't see the need to do so. In either of the events you mentioned Eikon is still running, albeit the user is signed out. When the user signs back in IDataServices object will detect that and raise StateChanged event and IDataServices.State will be set to Up.
Does this make sense to you? Or am I missing something?
By the way, if the user setup silent login, the user will not be prompted to enter Eikon credentials when signing back into Eikon after logout.

icon clock
10 |1500

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

Upvotes
39.4k 77 11 27

I must say this is not a very common scenario. Personally I've never previously seen it in practice. In my experience the absolute vast majority of users use silent login. They check the box saying "Sign me in automatically" when first entering their Eikon credentials and never need to type in username and password again.
My only suggestion is to abandon attempts at calling DataServicesFactory.Create() after a few tries until the user signs into Eikon. To establish the latter you could pop up a dialog from your application informing the user that he or she needs to sign into Eikon and resume calling DataServicesFactory.Create() once the user hits OK in that dialog.

icon clock
10 |1500

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

Upvotes
87 10 13 14

Thanks Alex,
we do see this situation arise quite a lot. One common example is the automatic log out from Eikon Terminal that usually takes places after a prolonged period of inactivity. This is mostly happening on weekends. Trying to recreate the API connection via the above method leads to the observed problems.

Another example of this happening is when a user logs in to Eikon from some other computer which in turn disconnects the original connection.

Do you know of any way to check if a user is logged into Eikon which does not involve calling DataServicesFactory.Create()?

icon clock
10 |1500

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

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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