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)




"I am keeping IQFeed, much better reliabilty than *******. I may refer a few other people in the office to switch as well." - Comment from Don
"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
"I'm satisfied with IQFeed. It's the most reliable and fastest quote feed I have ever used. Although I'm a resident in China, it's still very fast!" - Comment from Xiaofei
"I am enjoying the feed very much - so superior to the broker provided feed I was previously using." - Comment from George
"I have been using IQFeed now for a few years in MultiCharts and I have zero complaints. Very, very rare to have any data hiccups or anything at all go wrong." - Comment from Public Forum
"Awesome response, as usual. It is a sincere and refreshing pleasure to do business with DTN, compared to your competition." - Comment from Ryan
"I just wanted to tell you what a fine job you have been doing. While *******, from what I hear, has been down and out, off and on, IQ feed has held like a champ this week." - Comment from Shirin
"I noticed that ******* quotes locked up shortly after the interest rate announcement yesterday while yours stayed stable." - Comment from Ron in Utah
"I've been using IQFeed 4 in a multi-threaded situation for the last week or two on 2600 symbols or so with 100 simultaneous daily charts, and I have had 100% responsiveness." - Comment from Scott
"I just wanted to say how happy I am with your service. I was able to download the API docs last week and I was able to replicate Interactive Brokers historical bar queries and realtime bar queries over the weekend. That was about one of the fastest integrations that I've ever done and it works perfectly!!!!" - Comment from Jason via Email
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 »getting many SocketTimeoutExceptions in version 4.2.1.4
Author Topic: getting many SocketTimeoutExceptions in version 4.2.1.4 (4 messages, Page 1 of 1)

simon33
-Interested User-
Posts: 28
Joined: Apr 9, 2005


Posted: May 16, 2007 10:14 PM          Msg. 1 of 4
Hello, I just updated from developer version 2.3.0.1 to the new version 4.2.1.4 (I am really, really risk adverse). Anyhow, I do only look up in Historical TCP/IP mode - lots and lots a day.

The error I am seeing is that it is throwing a SocketTimeoutException while reading from a socket. The exception message is: "Read timed out"

Here is the relevant code:

try
{
//write to the socket
sout.write( command );
sout.flush();

//read the response from the socket
String line = sin.readLine();

while( line != null && !line.trim().equals( "!ENDMSG!" ) )
{
if( line.length() != 0 )
{
// we do something
}
line = sin.readLine();
}
}
catch( SocketTimeoutException timeoutException )
{

}

Any ideas?

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


Posted: May 17, 2007 09:46 AM          Msg. 2 of 4
After doing a bit of research, I am not sure why this would be happening for you.

Can you give some more inforamtion about the requests? Are you able to complete any requests at all? If so, does the error occur randomly or is it always on a specific request?

Have you tried to enable logging in IQConnect to see if an error is output to the log by IQConnect?

simon33
-Interested User-
Posts: 28
Joined: Apr 9, 2005


Posted: May 17, 2007 11:32 AM          Msg. 3 of 4
I will definitely turn on the logging but, after re-examining the code, I have another theory that may solve it. Here is what I think is happening.

I am registering with the DTNClient and making calls. Then I think the socket is dying ('Read Time Out' and then all subsequent calls die until the socket can be re-established. If this theory is correct, is a way to listen for socket issues/statuses on the client?

simon33
-Interested User-
Posts: 28
Joined: Apr 9, 2005


Posted: Jun 4, 2007 11:18 AM          Msg. 4 of 4
For completeness, we determined that this had nothing to do with DTN, but it was a network routing issue on our end.
 

 

Time: Mon May 6, 2024 6:25 PM CFBB v1.2.0 10 ms.
© AderSoftware 2002-2003