|
From: Tommy H. <Tom...@Bo...> - 2007-04-26 17:05:36
|
BTW, another approach to question #3... Use RMI to expose methods to an external process. From there, you can write a simple application that can call these methods (performing whatever tasks you need). I guess another alternative would be to call the hooks in the management extensions if you only need those methods that have already bee exposed. You should also register a shutdown thread. This will get called when the Ctrl-C interrupt is passed to the JVM. You can gracefully close DB connections, files. etc. before you program is terminated. -Tommy On Apr 26, 2007, at 11:54 AM, Tommy Hannon wrote: > QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ > QuickFIX/J Support: http://www.quickfixj.org/support/ > I just started developing with QuickFIX/J last week and am totally > delighted with the ease of use (kinda of like switching to a Mac). > > Most everything you need to manage the "grunt-work" of the protocol > is handled using the "Setting" file as described in the user manual. > Session level stuff, Logon/Logout, heartbeats, resends, all are > handled "under-the-hood" and need not be handled at your application > level code. IMHO, the greatest benefit to new users is the > management extensions. > > Just add a few lines of code to a Java 1.5 codebase and a system > property on the command line; start "jconsole" and connect! (Be sure > to start the console using the same user as your application if > running locally) From there the session attributes page is a real > help. you can view or update values on-the-fly. Go to the > "Operations" tab and you can reset, disconnect, logon, or logoff > individual sessions. > > In general this product is very is easy to use, almost beyond > belief. My suggestion would be to check out the "Creating Your > Application", "Receiving Messages" and "Sending Messages" sections of > the user manual paying attention to the "Most Type Safe" approach. > > Good luck! > > -Tommy > > On Apr 26, 2007, at 10:46 AM, Toli Kuznets wrote: > >> QuickFIX/J Documentation: http://www.quickfixj.org/documentation/ >> QuickFIX/J Support: http://www.quickfixj.org/support/ >> Robert, >> >>> 1.) We plan on connecting to 4 end-points, so I have 4 sessions >>> in my >>> configuration file...is there a benefit to using the >>> ThreadedSocketInitiator as opposed to just the SocketInitiator? >> >> This is a classic trade-off. if you need all your incoming >> messages to >> be processed in order they are coming in across all connections, then >> use the regular SocketInitiator. >> If the 4 connections are totally unrelated then you can process them >> concurrently using the ThreadedSocketInitiator >> >>> >>> 2.) If one of our end-point's connection goes down indefinitely, >>> are >>> the remaining 3 sessions ok? Say one of the 4 end-points goes down >>> momentarily and then goes back up, will the engine reconnect or do I >>> have to bring the entire engine down and reconnect all 4 sessions? >> >> QFJ should reconnect to the lost connection when it comes back u and >> renegotiate a logon. >> there area various timeout settings you can tweak to modify the >> timeout behaviour. >> >>> 3.) Examples of the custom Initiator classes have a 'System.in' >>> statement waiting for a user to hit a key on the keyboard to exit >>> the >>> engine. If we want to put this process in the background, this >>> isn't a >>> feasible design obviously...so I was curious what people are >>> doing to >>> build an engine that can be set as a background process and then >>> when >>> brought back to the foreground, how is the engine being stopped >>> elegantly so the appropriate logout and disconnect procedures occur? >>> >> >> I'd be intersted to hear how others approach this problem as well. >> For >> now, we create the socket initiator and FIX listenrers in Spring, and >> then the main thread just goes to sleep (we do a new >> Semaphore(0).wait()). The OMS is then killed by pressing Ctrl-C if >> you >> run it on the console, or with an /etc/init.d script wrapping a 'kill >> -9' on our virtual appliance. Here's the code for reference: >> http://trac.marketcetera.org/trac.fcgi/browser/platform/trunk/oms/ >> src/main/java/org/marketcetera/oms/OrderManagementSystem.java#L59 >> >> >> -- >> Toli Kuznets >> http://www.marketcetera.com: Open-Source Trading Platform >> download.run.trade. >> >> --------------------------------------------------------------------- >> - >> --- >> This SF.net email is sponsored by DB2 Express >> Download DB2 Express C - the FREE version of DB2 express and take >> control of your XML. No limits. Just data. Click to get it now. >> http://sourceforge.net/powerbar/db2/ >> _______________________________________________ >> Quickfixj-users mailing list >> Qui...@li... >> https://lists.sourceforge.net/lists/listinfo/quickfixj-users >> > > > ---------------------------------------------------------------------- > --- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Quickfixj-users mailing list > Qui...@li... > https://lists.sourceforge.net/lists/listinfo/quickfixj-users > |