Re: [Quickfix-developers] (no subject)
Brought to you by:
orenmnero
|
From: Dale W. <wil...@oc...> - 2005-05-23 15:04:36
|
Hi QuickFIX developers,
I think I've run into a "you-can't-get-there-from-here" problem, but I'd
like to be sure I'm not missing something.
The situation I'm trying to handle happens when the client (initiator)
is recovering from a significant failure and has lost track of the
sequence number expected by the server (acceptor).
The client sends logon message a sequence number that is less than the
one expected by the server. The server responds, correctly, with a
logout message. If the server is based on QuickFIX this logout message
will contain a Text field giving the expected sequence number.
i.e.: 58=MsgSeqNum too low, expecting 7 but received 1
What I would like to do is detect this Logout message; inform the user
of the situation; and allow them to verity that the sequence number
should be reset.
Unfortunately as far as I have been able to determine, the Logout
message containig the expected sequence number never reaches the
application code. QuickFIX determines that this is not a valid sequence
of messages:
[ Session::verify calls Session::validLogonState and throws an
exception when it returns false. ]
and calls Application::onLogout() (twice, actually, but who's counting.)
The body of the message containing the expected sequence number isn't
available vis the onLogout call -- so I can't find a way to determine
what sequence number is expected.
My work around for this will be to read the log, identify the logout
message, and parse it to find the expected sequence number -- unless, of
course, someone tells me that there's a better way.
Any suggestions would be appreciated,
Dale
--
-----------------------------------------------------
Dale Wilson, Senior Software Engineer
Object Computing, Inc. (OCI)
http://www.ociweb.com/ http://www.theaceorb.com/
----------------------------------------------------
|