[Quickfix-developers] multiple sessions/connections
Brought to you by:
orenmnero
From: azmat <mr...@gm...> - 2008-03-04 18:40:13
|
All- I've setup two connections in my config file, but how do I start both sessions? Would they both get called if their information is in the "FixSettings.txt" file with the code below (when _initiator.start() is called): if (_initiator != null) throw new Exception("Already Started"); try { SessionSettings settings = new SessionSettings("FixSettings.txt"); QFWrapper application = new QFWrapper(this); FileStoreFactory storeFactory = new FileStoreFactory(settings); FileLogFactory logFactory = new FileLogFactory(settings); MessageFactory messageFactory = new DefaultMessageFactory(); _initiator = new ThreadedSocketInitiator(application, storeFactory, settings, logFactory, messageFactory); _initiator.start(); } catch (Exception e) { System.Diagnostics.Trace.WriteLine("FixServer.Start() ERROR: " + e.Message); } Also, I need to setup another session for Drop Copies, and I imagine the same rule applies to 3 sessions as it does with 2. Basically what I will be doing is cracking any messages received, and if the messages contained are MarketData Messages (specifically snapshot, incremental, or reject messages), I will use the appropriate market-data logic in my application. If it is an execution Report then the cracker will pick it up and we can take care of it. Is this the correct approach? thanks! azmat -- View this message in context: http://www.nabble.com/multiple-sessions-connections-tp15834166p15834166.html Sent from the QuickFIX - Dev mailing list archive at Nabble.com. |