Fix API Hangs (Send no Price Data) on multiple subscriptions.

Created at 03 Sep 2018, 12:05
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
CT

ctid491211

Joined 10.06.2018

Fix API Hangs (Send no Price Data) on multiple subscriptions.
03 Sep 2018, 12:05


Hi,

I implemented a quickfix Client for your FIX Api. After some time I figured out how to logon and subscribe to Quote data. Now I try to subscribe to 25 Symbols at a time. I get exactly one Sample of price data of some of the subsciptions and after that there is no incoming Traffic. It feels like the server side is not working anymore at that time. There is no Communication like heartbeats or other messages on that socket. I tried it with and without TLS, but the result is the same. I had these types of "Connection Loss" (Socket is open) also with one Symbol at a time but they happen later. Witout Symbol subscription the heartbeats stop after ca. 3 to 4 times.

I use an icmarkets demo account for testing. Config is like the following. Client library is quickfixgo. Hope someone can help me with this Issue.

[DEFAULT]
ReconnectInterval=10
SenderCompID=icmarkets.******
BeginString=FIX.4.4
TargetCompID=cServer
StartTime=22:05:00
EndTime=22:00:00
HeartBtInt=30
SocketConnectHost=h1.p.ctrader.cn
DataDictionary=spec/FIX44.xml
FileLogPath=log
SocketInsecureSkipVerify=Y
[SESSION]
SenderSubID=QUOTE
SocketConnectPort=5211

Best Regards


@ctid491211
Replies

PanagiotisCharalampous
03 Sep 2018, 12:09

Hi ctid491211,

Do you send heartbeats to the server to keep the connection active?

Best Regards,

Panagiotis


@PanagiotisCharalampous

ctid491211
03 Sep 2018, 12:29

Hi,

Thank you for the fast response. No, not activeliy. But I think the library does it automatically. I see heartbeats on the log every 30 seconds like its defined in the config until the communication stops. Are these Heartbets necessary for further communication. So maybe theres a Problem in the quickfix library. I will try to send them manually. But in the cas with 25 concurrent subscriptions the communication doesn't even come to the point of Heartbeat interval.

Best Regards

pete


@ctid491211

PanagiotisCharalampous
03 Sep 2018, 12:33

Hi Pete,

If the server does not receive heartbeats from the client then it will close the connection. Please try sending one heartbeat every 10 seconds for each subscription and let me know if it works.

Best Regards,

Panagiotis


@PanagiotisCharalampous

ctid491211
03 Sep 2018, 13:11

Okay, I will try to send the heartbeats manually. But it is not really intuitive and never mentioned in the Documentation, that it is necessery to send Heartbeats every 10 seconds. Maybe it would be good to mention that.

Thank you! Best regards!


@ctid491211

ctid491211
03 Sep 2018, 13:40

I just found the mistake. It was actually in my Code. There was a routine wich blocks the communication. You can mark this as resolved! It weren't the heartbeats!

Thank you very much!

Best regards!

pete


@ctid491211