Re: [Quickfix-developers] Fwd: QuickFIX Python and Twisted
Brought to you by:
orenmnero
|
From: Robert P. <rob...@gm...> - 2006-11-16 02:26:10
|
Unfortuntely, I'm unable to get it running on my end.
I've grabbed the QuickfixPython.cpp file straight from SVN and
compiled. ( The python version is 2.3.4 RHEL, and the OS is CentOS
4.4 on i386, if that's at all relevant. )
I run this simple client,
------------------------------------------------------------------
fileName = "my.conf"
settings = quickfix.SessionSettings(fileName)
application = MyClient(connStr)
storeFactory = quickfix.FileStoreFactory(settings)
logFactory = quickfix.FileLogFactory(settings)
initiator = quickfix.SocketInitiator(application, storeFactory,
settings, logFactory)
time.sleep(3)
log.msg("starting initiator...")
initiator.start()
log.msg("...started initiator.")
log.msg("starting sleep cycle")
while True :
time.sleep(1)
log.msg("snore")
initiator.stop()
-----------------------------------------------------
For output, I only see this:
2006/11/15 21:11 EST [-] Log opened.
2006/11/15 21:11 EST [-] MyClient: created.
2006/11/15 21:11 EST [-] starting initiator...
2006/11/15 21:11 EST [-] ...started initiator.
2006/11/15 21:11 EST [-] starting sleep cycle
And it hangs there indefinitely. I DO notice that if I remove the
time.sleep(1), I see a bunch of "snore"'s, but that they stop after a
second (same happens with just print statement).
I've tried adding cout's to the QuickfixPython.cpp code, and can see
when each swig threading macro is invoked, but the cout's in the
wrap_Initiator_start function I don't see being invoked at all, so I'm
at a bit of a loss.
Tomorrow, I'll try to get a fresh checkout and see if I can get that
running. Has anyone
BTW, I have some modifications to quickfix.i to allow for ODBC,
PostgreSQL, and MySQL data stores and logging, so I need to regenerate
QuickfixPython.cpp instead of just using the one from SVN. However,
for now I'll use the File-based store and logging.
cheers,
rob
On 11/15/06, Robert Parrott <rob...@gm...> wrote:
> I've been regenerating QuickfixPython.cpp from the quickfix.i with
> swig 1.3.29 at each stage.
>
> Is this the version you're using?
>
>
>
> On 11/15/06, Oren Miller <or...@qu...> wrote:
> > That's my fault. I checked in a file that had some of the manual
> > threading changes I had started on. I removed all that stuff and it
> > seems to work here. Can you do another update and try again?
> >
> > --oren
> >
> > On Nov 15, 2006, at 6:34 PM, Robert Parrott wrote:
> >
> > > QuickFIX Documentation: http://www.quickfixengine.org/quickfix/doc/
> > > html/index.html
> > > QuickFIX Support: http://www.quickfixengine.org/services.html
> > >
> > > Unfortunately, I'm finding that after this change, the initiator
> > > thread doesn't even start when Initiator.start() is called in python.
> > > Reverting back to the interface generated without the -threads option
> > > generates a library that runs the initiator thread.
> > >
> > > Oh well, no magic bullet here, it seems.
> >
> >
>
|