View Full Version : backup data feed logic not working
zweistein
03-04-2009, 01:30 AM
dear sirs,
today I observed a problem in NT. I am using Multibroker license.
My setup is first connection IB, second connection PATS system.
IB has backup data feed PATS and PATS has backup data feed IB.
Today IB had a broken eurofarm marketdata connection, so I expected NT to fall back to the PATS system.
This is the log message:
04/03/2009 8.49 Default HMDS data farm connection is broken:euhmds2 2105
But there was no fallback and no marketdata was taken from the PATS connection.
To check wether the marketdata on PATS was available I disconnected the IB and had PATS as the only connection.
Another problem showed up here:
In the Control center -> Orders Tab I could see the marfket data for FDAX and FGBL, and this confirmed that PATS was transmitting market data.
My open chart windows for FDAX and FGBL would however not receive this market data and they would not update and there was no bid or ask shown in the chart trader window.
Please indicate a solutuon to have a working fallback market data connection.
Best regards
Andreas
NinjaTrader_Jason
03-04-2009, 03:12 AM
Hello zweistein,
It is not necessary to assign each connection as backup if you connect to both simultaneously; if one connection is disconnected, you will still be connected to the other connection, which will provide the data from there on.
Am I correct after the log message, you were still connected to IB; the lower left corner listed 'Connected - IB' in green?
If so, NinjaTrader was still trying to retrieve the futures data from IB. Only when the first connection does not support the instrument type selected (futures, forex, equities, indices), it will retrieve the data from the second connection. Since you were still connected to IB, it tried to retrieve the data from IB, but you did not receive data, since the eurofarm feed was broken.
Once disconnected you received real-time from Patsystems. Try right clicking in the charts and select 'Reload Historical Data' regarding the charts that did not update with real-time data.
zweistein
03-04-2009, 03:25 AM
Hi Jason,
NT Control Center gave Connected->InteractiveBrokers in green.
IB TWS gave MarketData button in orange with eurofarm disconnected.
I would like to have NT switch automatically to the other working connection, PATS.
Since my PATS has no historic data but only market data feed reload historical data will not work and it would not help as I didn't even get bid ask data in the charttrader window.
NT could also elaborate the log message and act accordingly. Elaborate messages from TWS concerning MarketData!
Any better way to have an automatic fallback?
Andreas
NinjaTrader_Jason
03-04-2009, 03:35 AM
Hello Andreas,
Unfortunately this is not possible if the connection is indicated as green in NinjaTrader; you will need to disconnect manually.
I will forward your suggestion to our development team and ask them if they can add this to the list of future considerations for the software.
Thank you for your feedback.
tjendra
04-30-2009, 08:52 AM
Hello Andreas,
Unfortunately this is not possible if the connection is indicated as green in NinjaTrader; you will need to disconnect manually.
I will forward your suggestion to our development team and ask them if they can add this to the list of future considerations for the software.
Thank you for your feedback.
So if the IB connection is orange, then does it fallback to the second connection for data?
NinjaTrader_Jason
04-30-2009, 09:09 AM
Hello tjendra,
No, the orange color indicates NinjaTrader is connected, but not correctly. Only when the first connection is fully disconnected, the second connection is used.
tjendra
04-30-2009, 09:17 AM
Hello tjendra,
No, the orange color indicates NinjaTrader is connected, but not correctly. Only when the first connection is fully disconnected, the second connection is used.
But wouldn't that be weird? I mean the whole idea of having a secondary feed is that if there is something wrong with the primary feed, it would fallback on the secondary feed for data. Else, what's the secondary feed used for, unless it is only used to get symbols not available on the primary feed.
And is there a difference between having the backup feed specified in Account Connection versus just connecting 2 feeds?
NinjaTrader_Jason
04-30-2009, 09:23 AM
Hello tjendra,
The orange color indicates there is still a connection, so it will not convert to the second connection. Usually the orange color indicates either the order or price server is not connected correctly.
If the first connection does not support an instrument type and the second connection does, NinjaTrader will retrieve the data from the second connection. If the second connection is not connected, but setup as backup data feed, it will not retrieve data for the instrument type not supported by the first connection.
tjendra
04-30-2009, 09:37 AM
Hello tjendra,
The orange color indicates there is still a connection, so it will not convert to the second connection. Usually the orange color indicates either the order or price server is not connected correctly.
If the first connection does not support an instrument type and the second connection does, NinjaTrader will retrieve the data from the second connection. If the second connection is not connected, but setup as backup data feed, it will not retrieve data for the instrument type not supported by the first connection.
But thats the main issue isn't it, orange color indicates either the order or price server is not connected correctly. So shouldn't it be getting the correct data from the secondary feed instead to make sure you are getting the correct data?
For the backup data feed, does it get used by the primary feed when it is orange color? Under what circumstances would the backup data feed be used then?
NinjaTrader_Jason
04-30-2009, 09:45 AM
As I mentioned, NinjaTrader will only convert to the second connection when the first connection is fully disconnected.
NinjaTrader will convert to the back up data feed if the primary feed is fully disconnected. This will only work if the back up data feed connection is live.
tjendra
04-30-2009, 09:54 AM
As I mentioned, NinjaTrader will only convert to the second connection when the first connection is fully disconnected.
NinjaTrader will convert to the back up data feed if the primary feed is fully disconnected. This will only work if the back up data feed connection is live.
Maybe let me put it this way instead. What should I do if I want to get correct data when the connection turn orange color which indicates either the order or price server is not connected correctly.
Since either the backup feed or the secondary feed won't work unless the primary feed is disconnected.
What you are saying so far, is that there is no way I can get correct data if the connection turn orange.
NinjaTrader_Jason
04-30-2009, 10:01 AM
Hello tjendra,
Disconnect the first connection and restart NinjaTrader. Check if you can get connected successfully as per the first connection (that appeared orange the previous session).
If not, connect to the data feed that normally is connected second only.
tjendra
04-30-2009, 10:10 AM
Hello tjendra,
Disconnect the first connection and restart NinjaTrader. Check if you can get connected successfully as per the first connection (that appeared orange the previous session).
If not, connect to the data feed that normally is connected second only.
I always can get successful connected to the first connection if I restart NT. What I am saying here is what if it turn orange during the trading session? What am I suppose to do? Restart NT everytime it turn orange? How is anybody able to trade live like that?
Also, it may turn orange for only 1 min and turn green again. So I am missing that 1 min of data which can impact my indicators. How should I get that missing 1 min of data to load correctly during a live trading session? That why the logical idea would be the backup feed should provide the data isn't it. But it doesn't, unless the first feed is disconnected.
NinjaTrader_Jason
04-30-2009, 10:13 AM
It should not turn orange on a frequent base. Do you experience many orange connections?
Right click in the chart and select 'Reload Historical Data' to reload missing historical data.
Check if you have software, such as (corporate) firewalls, spyware and anti-virus software that could be interfering the connection.
tjendra
04-30-2009, 10:21 AM
It should not turn orange on a frequent base. Do you experience many orange connections?
Right click in the chart and select 'Reload Historical Data' to reload missing historical data.
Check if you have software, such as (corporate) firewalls, spyware and anti-virus software that could be interfering the connection.
It turned orange a few times in a trading session for a few mins each time. I know that if I reload historical data it will get the correct data, but I am running a live strategy! That few mins might be when I need to get in or get out of a trade, by the time I finish reloading, the price level would not be where I want to get in/out initially isn't it?
Am I correct to say that NT can't load the correct data if a connection goes orange then and there is no way to remedy this problem in real time beside reloading historical data later.
I do not use software, such as (corporate) firewalls, spyware and anti-virus software on my trading computer.
NinjaTrader_Jason
04-30-2009, 10:28 AM
Do you experience other consequences on your PC when you experience the orange color?
Your strategy will not function if you do not receive real-time data or if NinjaTrader cannot connect to your live account.
You are correct in your assumption.
Unfortunately NinjaTrader does not dictate when a connection is lost. It operates like a radio receiver in that it receives a signal from your broker and then displays/reports these signals back to you the trader. When a connection is lost, it is the broker's API that determines this and reports this to NinjaTrader which in turn reports this back to the trader.
The common problems that contribute to this are:
- ISP issues
- hardware firewall issues changing IP addresses frequently
- Dynamic ISP address switching the address frequently intraday. Usually this happens once a week but you may want to check with your ISP. If they do change daily, a static IP address may work.
- With Windows XP SP2, if you have more than 10 open TCPIP socket connections open (10 programs making connections through the internet) windows will randomly shut down some connections
- Broker servers having problems
tjendra
04-30-2009, 10:41 AM
Do you experience other consequences on your PC when you experience the orange color?
Your strategy will not function if you do not receive real-time data or if NinjaTrader cannot connect to your live account.
You are correct in your assumption.
Unfortunately NinjaTrader does not dictate when a connection is lost. It operates like a radio receiver in that it receives a signal from your broker and then displays/reports these signals back to you the trader. When a connection is lost, it is the broker's API that determines this and reports this to NinjaTrader which in turn reports this back to the trader.
The common problems that contribute to this are:
- ISP issues
- hardware firewall issues changing IP addresses frequently
- Dynamic ISP address switching the address frequently intraday. Usually this happens once a week but you may want to check with your ISP. If they do change daily, a static IP address may work.
- With Windows XP SP2, if you have more than 10 open TCPIP socket connections open (10 programs making connections through the internet) windows will randomly shut down some connections
- Broker servers having problems
I am still connected to the live account. It is just that when the connection turn orange, my strategy miss some entries / exits because the data on the chart then becomes incorrect.
The 2nd thing I want to clarify is that, the backup and secondary feed does not serve any purpose unless the primary feed is disconnected.
3rd, isn't it possible for NT to check if the connection turn orange, then they should ask the backup / secondary feed for the missing data rather then wait until the connection is lost? Or is this feature going to be available in NT 7 so that the data reliability and accuracy is enhanced by having a fallback feed?
NinjaTrader_Jason
04-30-2009, 10:45 AM
I am still connected to the live account. It is just that when the connection turn orange, my strategy miss some entries / exits because the data on the chart then becomes incorrect.
--> This is as expected, since there is no real-time or NinjaTrader cannot connect to your live account your strategy is running on.
The 2nd thing I want to clarify is that, the backup and secondary feed does not serve any purpose unless the primary feed is disconnected.
--> Correct, the primary feed needs to be fully disconnected.
3rd, isn't it possible for NT to check if the connection turn orange, then they should ask the backup / secondary feed for the missing data rather then wait until the connection is lost? Or is this feature going to be available in NT 7 so that the data reliability and accuracy is enhanced by having a fallback feed?
--> I will forward your suggestions to our development team and ask them if they can add this to the list of future considerations for the software. Thank you for your feedback.