Joined: Oct 31, 2020
Posted: Jan 8, 2022 04:51 AM
Msg. 1 of 2
Hi I have a question.
Is it OK to use 500 connections to listen to 500 symbols (each connection listen to one symbol) ?
Or it's recommended to use one connection to listen to all symbols?
Do you utilize multi cores when there are a lot of connections?
Joined: Jul 3, 2019
Posted: Jan 10, 2022 10:50 AM
Msg. 2 of 2
First, are we talking about the number of connections to the iqfeed server, or are you talking about the number of socket connections you can make from one server connection?
Your login ID can make multiple connections to the iqfeed API server, but they must all be from the same machine. If login ID 123456 is connected to the server, and you try to connect it from another computer, the first connection will be severed. It is possible to make one server connection, and then open many different socket connections using it.
It's not clear from your initial message which of these you're trying to do. But in general, both types of multiple connections are allowed, within the limitations that I've previously given. We don't have an upper limit on the number of connections you can have. But the "Maximum Symbols" limit for the number of symbols you can watch (typically 1300 total), and rate-limiting for historical look up requests (50 per second), are per login ID, not per connection. So having two different server or socket connections using the same login ID will not let you request 100 historical lookups.
We don't really recommend a specific number of connections to have; do whatever works best for your app and environment. Having one connection per symbol is probably a little excessive. But many users will split a workload among multiple connections, like having 10 connections and watching 50 symbols on each.
I hope this information is helpful!
DTN IQFeed Implementation Support Specialist