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)




"If you want customer service that answers the phone, your best bet is IQFeed. I cannot stop praising them or their technical support. They are always there for you, and they are quick. I have used ****** too but the best value is IQFeed." - Comment from Public Forum
"The service is great, I see a noticeable improvement in my volume profiles over [broker]'s data feed" - Comment from Larry
"IQFeed version 4 is a real screamer compared to anything else I have seen." - Comment from Tom
"I was on the phone with a friend who uses CQG and right after the Fed announcement, CQG was as much as 30 seconds behind DTN.IQ. Some quotes were off by as much as 15-18 cents. Your feed never missed a beat." - Comment from Roger
"Thank God for your Data Feed as the only Zippers I see are on my pants (LOL), and no more 200 pip spikes to mess up charts." - Comment from Spiro via Email
"I cannot believe what a difference it makes trading with ProphetX!" - Comment from Bruce in Los Angeles
"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
"Very impressed with the quality of your feed - ******* is a real donkey in comparison." - Comment from A.C. via Email
"I just wanted to let you know how fast and easy I found it to integrate IQFeed into our existing Java code using your JNI client. In my experience, such things almost never go so smoothly - great job!" - Comment from Nate
"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.
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 »can we use multiple socket connections for Level I realtime data
Author Topic: can we use multiple socket connections for Level I realtime data (3 messages, Page 1 of 1)

vis_nagraj
-Interested User-
Posts: 5
Joined: Jun 27, 2007


Posted: Jun 27, 2007 05:19 AM          Msg. 1 of 3
Dear steve,

I had a query regarding using multiple socket connections to IQConnect. We have a requirement of getting realtime data (level 1) for around 100 symbols at the same time. The application is developed in Java. I have a confusion regarding this. Should i use a single Socket connection and give commands for all the 100 symbols, OR should i used different Socket connections at the same time for each symbols. Secondly, we have to use threads to read data from socket, but here also should I use a single thread with a single socket connection for all 100 symbols, OR should i create individual threads (and individual socket connection) for each symbol. Please could u help me in this. How would it affect the performance if we use multiple threads (or socket connections).

Eagery awaiting for some good reply...


Vishwanath

dis
-Interested User-
Posts: 24
Joined: Apr 16, 2007


Posted: Jun 27, 2007 07:54 AM          Msg. 2 of 3
A lot of threads will decrease your performance because there would be some CPU time to switch between them. The good practice is to have one thread per one CPU.

I have desktop application which has 2 threads: main (GUI - request data and watch results) and background one which listens the socket and sends data to the UI. It updates ~700 symbols using single socket and works fine for me.

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


Posted: Jun 27, 2007 08:31 AM          Msg. 3 of 3
With IQFeed, you can create up to 20 local level 1 socket connections at any given time. However, there should be no need to do this unless you have a need to keep certain data compeltely separate in your app. IQFeed makes a single socket conenction to the server for level 1 data.

Concerning threads, as dis said, this depends upon the number of CPU's and/or the number of simultaneous threads your computer can execute at one time (usually equal to the number of CPU's that windows reports). You will see that exceding this number by more than a few threads will actually significantly decrease the performance of your app.
Edited by DTN_Steve_S on Jun 27, 2007 at 08:32 AM
 

 

Time: Sun May 19, 2024 1:50 AM CFBB v1.2.0 7 ms.
© AderSoftware 2002-2003