|
From: Toli K. <to...@ma...> - 2007-06-05 00:41:18
Attachments:
qfjLog.txt
|
Hi, I'm using QFJ to connect to a broker via SSL. Every once in a while, i get in a situation where the underlying MINA layer is seeing incoming FIX messages, but they don't seem to ever make their way up to the application layer. Connecting to the same broker without SSL, i'm seeing the same exact incoming messages, but they don't ever get dropped. For example, during connection in the Mina output i'm seeing a Logon (35=A) followed by a Trading Session Status (35=h). The Logon comes through, but every once in a while the TradingSessionStatus doesn't. The broker logs shows them sending me a heartbeat and a test request, but i never see that (even in Mina layer) so eventually i'm timed out and disconnected. Is it possible that there's some race condition in the SSL decoding code? i can't seem to trace where the entrypoint from Mina into QFJ code is. The log with QFJ and Mina messages attached. -- Toli Kuznets http://www.marketcetera.com: Open-Source Trading Platform download.run.trade. |
|
From: Brad H. <Bra...@gb...> - 2007-06-05 01:57:01
|
Hi Toli, Perhaps this is fixed by http://www.quickfixj.org/jira/browse/QFJ-179 for 1.1.1?=20 Brad. -----Original Message----- From: qui...@li... [mailto:qui...@li...] On Behalf Of Toli Kuznets Sent: Tuesday, 5 June 2007 11:20 AM To: qui...@li... Subject: Re: [Quickfixj-users] Is anybody seeing dropped incoming SSLmessages? QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ QuickFIX/J Support: http://www.quickfixj.org/support/ In the spirit of answering my own questions, I have figured out my problem - it was a "user error" of sorts. Turns out I had a deadlock: since this was a quick-and-dirty sample app, i was stupid to send a MarketDataRequest from inside the onLogon() method. As a result, i had a lock on the DataDictionary and was waiting on SocketIoProcessor (mina's SSL processor) while the SocketIoProcessor was receiving a new message and was in turn waiting on the DataDictionary. So rest assured, SSL (if used correctly) does not drop any incoming messages. Here's a corollary question: it's obvious that sending messages out in onXXX callbacks can lead to deadlocks. Any advice/best practices on how to handle that situation, aside from handing work out to other threads/runnables? thanks! |
|
From: Toli K. <to...@ma...> - 2007-06-05 07:17:18
|
Brad, I was running from SVN HEAD, so looks like there still may be some nascent deadlock issues possible, even given the current codebase. my only changes were the ones i made for QFJ-188, but i don't think that introduced any new synchronization problems. On 6/4/07, Brad Harvey <Bra...@gb...> wrote: > QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ > QuickFIX/J Support: http://www.quickfixj.org/support/ > > Hi Toli, > > Perhaps this is fixed by http://www.quickfixj.org/jira/browse/QFJ-179 > for 1.1.1? > > Brad. -- Toli Kuznets http://www.marketcetera.com: Open-Source Trading Platform download.run.trade. |
|
From: Steve B. <st...@te...> - 2007-06-05 10:54:17
|
Hi Toli, The Session implementation in the trunk doesn't synchronize the data dictionary access. I had also modified the Session to release locks on itself before any app callback. The ATApplication implementation used for acceptance testing has asserts to check that no locks are held. This should have eliminated the type of deadlock you are describing. Can you take a look at the version of Session you are using to verify that the data dictionary access is not synchronized? Steve > -----Original Message----- > From: qui...@li... [mailto:quickfixj- > use...@li...] On Behalf Of Toli Kuznets > Sent: Tuesday, June 05, 2007 3:17 AM > To: qui...@li... > Subject: Re: [Quickfixj-users] Is anybody seeing dropped > incomingSSLmessages? > > QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ > QuickFIX/J Support: http://www.quickfixj.org/support/ > Brad, > > I was running from SVN HEAD, so looks like there still may be some > nascent deadlock issues possible, even given the current codebase. > > my only changes were the ones i made for QFJ-188, but i don't think > that introduced any new synchronization problems. > > On 6/4/07, Brad Harvey <Bra...@gb...> wrote: > > QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ > > QuickFIX/J Support: http://www.quickfixj.org/support/ > > > > Hi Toli, > > > > Perhaps this is fixed by http://www.quickfixj.org/jira/browse/QFJ-179 > > for 1.1.1? > > > > Brad. > > > -- > Toli Kuznets > http://www.marketcetera.com: Open-Source Trading Platform > download.run.trade. > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Quickfixj-users mailing list > Qui...@li... > https://lists.sourceforge.net/lists/listinfo/quickfixj-users |
|
From: Toli K. <to...@ma...> - 2007-06-05 01:20:29
Attachments:
trace.txt
|
In the spirit of answering my own questions, I have figured out my problem - it was a "user error" of sorts. Turns out I had a deadlock: since this was a quick-and-dirty sample app, i was stupid to send a MarketDataRequest from inside the onLogon() method. As a result, i had a lock on the DataDictionary and was waiting on SocketIoProcessor (mina's SSL processor) while the SocketIoProcessor was receiving a new message and was in turn waiting on the DataDictionary. So rest assured, SSL (if used correctly) does not drop any incoming messages. Here's a corollary question: it's obvious that sending messages out in onXXX callbacks can lead to deadlocks. Any advice/best practices on how to handle that situation, aside from handing work out to other threads/runnables? thanks! (stack dump with deadlock attached for the curious). On 6/4/07, Toli Kuznets <to...@ma...> wrote: > Hi, > > I'm using QFJ to connect to a broker via SSL. > > Every once in a while, i get in a situation where the underlying MINA > layer is seeing incoming FIX messages, but they don't seem to ever > make their way up to the application layer. > Connecting to the same broker without SSL, i'm seeing the same exact > incoming messages, but they don't ever get dropped. > > For example, during connection in the Mina output i'm seeing a Logon > (35=A) followed by a Trading Session Status (35=h). > The Logon comes through, but every once in a while the > TradingSessionStatus doesn't. > The broker logs shows them sending me a heartbeat and a test request, > but i never see that (even in Mina layer) so eventually i'm timed out > and disconnected. > > Is it possible that there's some race condition in the SSL decoding > code? i can't seem to trace where the entrypoint from Mina into QFJ > code is. > > The log with QFJ and Mina messages attached. > > -- > Toli Kuznets > http://www.marketcetera.com: Open-Source Trading Platform > download.run.trade. > > -- Toli Kuznets http://www.marketcetera.com: Open-Source Trading Platform download.run.trade. |