Join the 80,000 other DTN customers who enjoy the fastest, most reliable data available. There is no better value than DTN!

(Move your cursor to this area to pause scrolling)




"The people at Nirvana have very nice things to say about your company and I can see why! Price and service is a potent combination." - Comment from Ed
"Just a thank you for the very helpful and prompt assistance and services. You provided me with noticeably superior service in my setup compared to a couple of other options I had looked at." - Comment from John
"As a past ******* customer(and not a happy one), IQ Feed by DTN is a much better and cheaper product with great customer support. I have had no problems at all since switching over." - Comment from Public Forum
"I started a trial a few weeks back before the market went wild. DTN.IQ didn’t miss anything and beat my other provider. I decided to stay with you because of the great service through all the volatility." - Comment from Mike
"Previously I was using *******. IQFeed is WAY more economical, and for my charting needs is just as good, if not better." - Comment from Public Forum Post
"I noticed that ******* quotes locked up shortly after the interest rate announcement yesterday while yours stayed stable." - Comment from Ron in Utah
"I would just like to say that IQFeed version 4 is running very well and I am very happy with its performance. I would also like to extend a big thanks for the fast and efficient help that I always receive. My questions and concerns are always addressed promptly. Way to go!" - Comment from Josh in CO.
"I am very happy I changed. I love the product, but more so I am thrilled with Tech Support. You are knowledgeable, polite, pleasant and professional." - Comment from Pat
"Thanks for all of your help. Great customer service deserves to be recognized which one the reasons I've been a customer of DTN for over 10 years!" - Comment from Stuart
"Thanks for following up with me. You guys do a great job in tech support." - Comment from Phelps
Home  Search  Register  Login  Recent Posts

Information on DTN's Industries:
DTN Oil & Gas | DTN Trading | DTN Agriculture | DTN Weather
Follow DTNMarkets on Twitter
DTN.IQ/IQFeed on Twitter
DTN News and Analysis on Twitter
»Forums Index »Archive (2017 and earlier) »IQFeed Developer Support »Data feed not recovering after internet disuption
Author Topic: Data feed not recovering after internet disuption (3 messages, Page 1 of 1)

bludev
-Interested User-
Posts: 16
Joined: Nov 14, 2012


Posted: Nov 14, 2012 10:02 PM          Msg. 1 of 3
Hi,
I am experiencing an issue where IQFeed level 1 data never recovers after an unexpected internet disruption.

My application detects the initial internet outage and properly closes all port connections (admin, level 1, level 2 and history) and then starts regular attempts at reconnection until it succeeds when the internet connection is restored. But then every so often (could be intermittent) although my connection to level 1 (port 5009) is successful, I do not receive any live tick data at all, but somehow I can retrieve historical data (port 9100) without any problem.

I can confirm that this is not a problem within the application code, because of two observations
1. “Seconds since last update” in the feed status steadily increases indicating no level 1 data is being received by IQFeed
2. The IQConnect test in the diagnostics tool fails for level 1 data.

So my questions are:
1. Is this a known bug?
2. If so, are there any immediate plans to release a fix?
3. Seeing as the client application thinks it is “successfully” connected to level 1 port, is there any way of programmatically detecting the fault? (other than detecting ticks which can be a problem if the market is shut and we trade many markets in many time zones with daylight saving, so this approach can get tedious)
4. Assuming there is some way for the application to know when the IQfeed level 1 data is not working, then is there a workaround other than closing IQfeed completely and restarting again?

I am developing in Windows 7 x64 and have had this same experience with both IQFeed version 4.8 and 4.9.

Thank you in advance.
Edited by bludev on Nov 14, 2012 at 10:03 PM

DTN_Steve_S
-DTN Guru-
Posts: 2093
Joined: Nov 21, 2005


Posted: Nov 15, 2012 08:47 AM          Msg. 2 of 3
Hello, there are no known bugs pertaining to what you describe. However, any scenario where the feed gets into a state where it thinks it is connected to a server while not being connected is certainly not intended.

In order to help identify the source of this, can you expand on your reconnection logic?

You mention that your app closes all local connections to IQFeed. This should cause the feed to shut down and at that point you would need to re-launch the feed to reconnect (in your case, it sounds like you are repeatedly launching the feed). Is that accurate for how you are handling the scenario?

bludev
-Interested User-
Posts: 16
Joined: Nov 14, 2012


Posted: Nov 25, 2012 09:36 PM          Msg. 3 of 3
Hi,

Thanks for your reply and sorry for my late response:

Here is my attempt at a summary overview of how we use IQFeed

To connect we have an AttemptConnection() routine which roughly speaking does the following...

SocketAdmin_.Connect(New IPEndPoint(IPAddress.Parse("127.0.0.1"),"9300"))
SocketAdmin_.Send("S,REGISTER CLIENT APP,[productid]," & ID)
SocketLevelI _.Connect(New IPEndPoint(IPAddress.Parse("127.0.0.1"),"5009"))
SocketLevelI_.Send("S,REQUEST STATS")
listening to receive "REGISTER CLIENT APP COMPLETED"
SocketLevelII _.Connect(New IPEndPoint(IPAddress.Parse("127.0.0.1"),"9200"))
SocketHistoricData _.Connect(New IPEndPoint(IPAddress.Parse("127.0.0.1"),"9100"))

The routine is designed such that any failure or time-out at any of the above steps would return false and we try again by repeating the process at some later point. If every line executes normally then the routine return true and we assume that the connection with IQFeed is established normally and tick data must be coming through.

Any exceptions while attempting to Connect, Send, Receive or ListenForData, will trigger a ConnectionClosed() event. This event’s handler includes the following instructions:

SocketAdmin_.Close()
SocketLevelI_.Close()
SocketLevelII_.Close()
SocketHistoricData_.Close()

to clean everything up. At this stage the IQFeed application is NOT closed and the tray icon persists. We then run AttemptConnection() asynchronously in a timed loop until a connection is established.

As I mentioned before, this often works. But sometimes if the cause of the initial disconnect is unexpected internet outage, then AttemptConnection() returns true giving the impression that everything is ok but then no data is received. So I guess one issue to look at is how to programmatically detect the problem in the first place.

Please let me know if you need me to be more specific about any of the above procedures and provide more information.
Edited by DTN_Jay_Froscheiser on Nov 26, 2012 at 07:44 AM
 

 

Time: Wed May 8, 2024 2:53 PM CFBB v1.2.0 15 ms.
© AderSoftware 2002-2003