Thread: [Quickfix-developers] QF hanging in resend scenario
Brought to you by:
orenmnero
|
From: adrien1977 (s. by Nabble.com) <li...@na...> - 2006-01-04 20:58:17
|
Hi We are implementing a component that uses quickfix to connect to another quickfix server. We have noticed a weird scenario that causes our adapter and the server to hang (may because entering a deadlock) We Connect for the first time to the server and send 2000 messages and get the responses. We disconnect and reset the sequence on the server to 1 but keep our sequence the same. We reconnect and obviously we received a resend request from the server. We start blasting the 2000 messages and the server processes them and start sending the messages back to us. However we do not receive these messages (or may be they are queued in QF) because they do not show in the log (but they are in the network. We could see them using a sniffer) While still sending the messages, our adapter stop sending more, and this is because the TCP window on the receiving side is full. However the server is still sending messages that we do not receive. After a while our adapter start sending back message, then stops starts again and finally stops and nothing else happens. I would like to know if it is normal. We are thinking that the thread that received the resend request is the same thread that processes the resend of messages. Since the receiving thread is busy sending the messages if cannot receive any this causing a queue in our side. Is it normal that the receiving thread is blocked when processing a resend? Should not it allowed more messages to come?? We are using the C++ version with Java wrapper. thanks adrien -- View this message in context: http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2209923 Sent from the QuickFIX - Dev forum at Nabble.com. |
|
From: Oren M. <or...@qu...> - 2006-01-04 21:14:02
|
Are you using the SocketInitiator or ThreadedSocketInitiator? --oren adrien1977 (sent by Nabble.com) wrote: > Hi > > We are implementing a component that uses quickfix to connect to > another quickfix server. > > We have noticed a weird scenario that causes our adapter and the > server to hang (may because entering a deadlock) > > > > We Connect for the first time to the server and send 2000 messages and > get the responses. > > We disconnect and reset the sequence on the server to 1 but keep our > sequence the same. > > We reconnect and obviously we received a resend request from the server. > > We start blasting the 2000 messages and the server processes them and > start sending the messages back to us. > > However we do not receive these messages (or may be they are queued in > QF) because they do not show in the log (but they are in the network. > We could see them using a sniffer) > > > > While still sending the messages, our adapter stop sending more, and > this is because the TCP window on the receiving side is full. > > However the server is still sending messages that we do not receive. > > > > After a while our adapter start sending back message, then stops > starts again and finally stops and nothing else happens. > > > > I would like to know if it is normal. > > > > We are thinking that the thread that received the resend request is > the same thread that processes the resend of messages. > > Since the receiving thread is busy sending the messages if cannot > receive any this causing a queue in our side. > > > > Is it normal that the receiving thread is blocked when processing a > resend? Should not it allowed more messages to come?? > > > > We are using the C++ version with Java wrapper. > > > > thanks > > > > > > adrien > > > > View this message in context: QF hanging in resend scenario > <http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2209923> > Sent from the QuickFIX - Dev > <http://www.nabble.com/QuickFIX---Dev-f1041.html> forum at Nabble.com. |
|
From: adrien1977 (s. by Nabble.com) <li...@na...> - 2006-01-04 21:17:20
|
We use a socket initiator and not the threaded one. However we do not think that it would solve the issue because what the threadSocketInitiator does is to spawn a thread for each session. Our adapter only has one session so it would not matter. -- View this message in context: http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2210275 Sent from the QuickFIX - Dev forum at Nabble.com. |
|
From: Oren M. <or...@qu...> - 2006-01-04 21:24:18
|
Two for each session. One is dedicated to pulling messages off the socket. Are using 1.10.2? --oren adrien1977 (sent by Nabble.com) wrote: > We use a socket initiator and not the threaded one. > However we do not think that it would solve the issue because what the > threadSocketInitiator does is to spawn a thread for each session. Our > adapter only has one session so it would not matter. > > View this message in context: Re: QF hanging in resend scenario > <http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2210275> > Sent from the QuickFIX - Dev > <http://www.nabble.com/QuickFIX---Dev-f1041.html> forum at Nabble.com. |
|
From: Caleb E. <cal...@gm...> - 2006-01-04 21:24:25
|
On 1/4/06, adrien1977 (sent by Nabble.com) <li...@na...> wrote: > > We use a socket initiator and not the threaded one. > However we do not think that it would solve the issue because what the > threadSocketInitiator does is to spawn a thread for each session. Our > adapter only has one session so it would not matter. Yes, it would. -- Caleb Epstein caleb dot epstein at gmail dot com |
|
From: adrien1977 (s. by Nabble.com) <li...@na...> - 2006-01-04 21:30:53
|
Ok then We are going to do a quick test with a simulator to see if it is the case. We were able to reprocuce the scenario with a simulator and not the other party's server. I'll get back to you guys and thanks for the help -- View this message in context: http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2210513 Sent from the QuickFIX - Dev forum at Nabble.com. |
|
From: adrien1977 (s. by Nabble.com) <li...@na...> - 2006-01-04 21:51:11
|
Ok Our first initial test seem to be working. Looking at the code, we missed the Queuing part. We really appreciate your help and keep you posted on the results thanks Adrien -- View this message in context: http://www.nabble.com/QF-hanging-in-resend-scenario-t852464.html#a2210927 Sent from the QuickFIX - Dev forum at Nabble.com. |