Re: [Quickfix-developers] Logging messages conditionally
Brought to you by:
orenmnero
|
From: Staffan U. <sta...@mu...> - 2006-05-16 13:08:49
|
> > I'd like to _not_ log certain messages to the messages_log table. > > Specifically, market data information is not important enough to > > warrant the required storage space, and I would like not to store sent > > messages in the log. > > > > Is there an easy way to do this? > > You could derive your own Log class from whichever Log you're > currently using and have it do nothing when it sees the message types > you want to ignore in the onIncoming/onOutgoing methods. For more > interesting messages, call the base class method. > > You'll need to do a string search (e.g. for "\00135=<X>\001") since > the Logs are passed strings, not Message objects. The string search requirement is a bit unfortunate, or at least ugly. A bigger problem is that the JdbcLog class is not public, but maybe this is just a bug and not by design? (I see that FileLog is indeed public). Staffan |