Re: [Quickfix-developers] Re: monitor the FIX connection failure programmatically?
Brought to you by:
orenmnero
|
From: Alvin W. <AW...@FF...> - 2005-11-04 22:05:12
|
The Session::isSessionTime() is not available in QF Java!! :(
Workaround?
"Oren Miller" <or...@qu...>
11/04/2005 02:53 PM
To: "Caleb Epstein" <cal...@gm...>, "Alvin Wang" <AW...@FF...>
cc: <qui...@li...>,
<qui...@li...>
bcc:
Subject: Re: [Quickfix-developers] Re: monitor the FIX connection failure
programmatically?
You can use Session::isSessionTime() to determine if you are within the
start and end times. The hearbeat interval has nothing to do with when
the session disconnects.
--oren
----- Original Message -----
From: Alvin Wang
To: Caleb Epstein
Cc: Oren Miller ; qui...@li... ; qui...@li...
Sent: Friday, November 04, 2005 1:48 PM
Subject: Re: [Quickfix-developers] Re: monitor the FIX connection failure
programmatically?
Caleb, we want to differentiate the normal logout/disconnect at the end of
day, and the abnormal logout/disconnect during the session. (is it safe to
assume that onLogout will not be called between Endtime and StartTime?) So
my question is, can we use isLoggedOn method inside onLogout to make above judgement? If isLoggedOn=true, it is abnormal.
Or, what is the algorithm to decide exact when the initiator will
disconnect at (around) the EndTime? For example, the EndTime is 22:00:00
and heartbeat interval is 30 seconds. Now the initiator sends a heartbeat
at 21:59:10. will the initiator disconnect at 21:59:40 or 22:00:10?
Many thanks
Alvin
Caleb Epstein <cal...@gm...>
Sent by: qui...@li...
11/04/2005 10:35 AM
To: Alvin Wang <AW...@ff...>
cc: Oren Miller <or...@qu...>,
qui...@li...,
qui...@li...
bcc:
Subject: Re: [Quickfix-developers] Re: monitor the FIX
connection failure programmatically?
On 11/4/05, Alvin Wang <AW...@ff...> wrote:
So does it mean even when the physics connection is down and we did not
receive logout msg, onLogout will still be invoked? If so, how can we tell
if it is an abnormal logout/disconnection?
Not trying to argue, but what if the FIX session is not never setup from
beginning due to network problem? Will onLogout be called?
I wouldn't call asking questions being argumentative :)
No, if a connection never comes up you'll never get an onLogout callback.
I have implemented some monitoring of QuickFIX connections by making use
of the onLogon/onLogout callback (for immediate notification when a
connection comes up or goes down) coupled with a thread that iterates
through all known sessions and uses FIX::Session::lookupSession +
Session::isLoggedOn to capture those connections that either never come up
or are outside their StartTime/EndTime windows.
Pseudocode:
foreach (SessionID as id)
{
Session* sess = Session::lookupSession (id);
if (!sess) continue;
send_connection_status (id, sess->isLoggedOn () ? "UP" : "DOWN");
}
--
Caleb Epstein
caleb dot epstein at gmail dot com
**********************************************************************
This e-mail message is intended solely for the use of the addressee. The
message may contain information that is privileged and confidential.
Disclosure to anyone other than the intended recipient is prohibited. If
you are not the intended recipient, please do not disseminate, distribute
or copy this communication, by e-mail or otherwise. Instead, please notify
us immediately by return e-mail (including the original message with your
reply) and then delete and discard all copies of the message. We have
taken precautions to minimize the risk of transmitting software viruses
but nevertheless advise you to carry out your own virus checks on any
attachment to this message. We accept no liability for any loss or damage
caused by software viruses.
**********************************************************************
|