Re: [Quickfix-developers] FW: ResendRequest and quickfix 1.4.1
Brought to you by:
orenmnero
From: Oren M. <ore...@ya...> - 2003-04-09 17:23:26
|
Looks like you can fix this by doing the following to the JavaApplication::toApp method in src/java/JavaApplication.cpp The abort is being caused by the line: msg = *((FIX::Message*)jmsg.getInt( "cppPointer" )); add the check if( !pEnv->ExceptionOccurred() ) before that line and see if you get better results. "Bishop, Barry" <Bar...@gs...> wrote:Hi, Further investigation leads me to believe that the processing of an inbound ResendRequest message has the following behaviour with quickfix 1.4.1 JNI layer: 1) Appropriate messages are always resent 2) Processing continues normally afterwards unless any message was not sent by throwing DoNotSend from Application.toApp(), in which case the library cores. I'm looking at the JNI code now to try and work this out. A work-around would very much be appreciated! Thanks, barry -----Original Message----- From: Bishop, Barry Sent: 09 April 2003 15:10 To: developers QuickFIX Subject: ResendRequest and quickfix 1.4.1 Hi, I have just built quickfix 1.4.1 with GCC 2.95 and STLport on solaris. All my previous problems have been fixed, except I now have a new one. My java application aborts with a core when processing a ResendRequest message. It didn't do this with quickfix 1.3.2 and my java code hasn't changed. The resend is fulfilled, as I see the messages being resent. However, after the last one, the application dies. I have a stack trace (see below) that seems to suggest something is going wrong in the JNI layer, specifically JavaApplication.toApp(). I think '__check_eh_spec' must be something to do with C++ exception handling. I have attached my (java) implementation of Application.toApp() that gets called. Thanks for any help guys, barry bishop ############################################################################ ###### ATTACHMENTS ############################################################################ ###### Implementation of 'org.quickfix.Application.toApp' ================================================== public void toApp(Message message, SessionID sessionId) throws DoNotSend { // throwing a DoNotSend from here stops the message being sent. boolean send = true; org.quickfix.field.PossDupFlag possDup = new org.quickfix.field.PossDupFlag(); try { message.getHeader().getField( possDup ); // Is this field a duplicate? if ( possDup.getValue() == org.quickfix.field.PossDupFlag.POSSIBLE_DUPLICATE ) { // Yes. Is it a quote? if ( message instanceof org.quickfix.fix42.Quote ) { send = false; } } } catch ( FieldNotFound fnf ) { // Definitely not a duplicate } if ( ! send ) throw new DoNotSend(); // Everything we send comes via this callback. audit( "toApp", message, sessionId ); } STACK ===== ----------------- lwp# 25 / thread# 25 -------------------- ff31acfc _lwp_kill (6, 0, 0, ffffffff, ff33c3ec, ff3c2474) + 8 ff2b563c abort (ff338000, f3c2c31c, 11, 1, ff3e260c, fdc10290) + 100 f40de394 __default_terminate (14c, f46cf564, f40de390, ff3e260c, 2979c, ff3c2474) + 4 f40df214 terminate__Fv (f40df280, f3c29dcc, 18, 1, ff3e260c, fdc10290) + 20 f40df220 __default_unexpected__Fv (48, f46cf590, f40df21c, 2a0f48, 0, 0) + 4 f40df2a0 unexpected__Fv (0, 4, 2a0f48, f4af3000, 81010100, ff00) + 20 f40df564 __check_eh_spec (1, f587ecb4, f49eb9d0, f49eb800, 1097c0, 8f2a4) + 60 f410abe0 toApp__15JavaApplicationRQ23FIX7MessageRCQ23FIX9SessionID (1128e0, f587e e78, 354974, f410a93c, 0, 53) + 2a4 f413c2f4 resend__Q23FIX7SessionRQ23FIX7Message (354970, f587ee78, 354b20, f587efb 8, f587f0f4, f587f330) + 174 f413b1e4 nextResendRequest__Q23FIX7SessionRCQ23FIX7Message (354970, f587f330, f46 95c00, 354b20, 0, 0) + 4d8 f41417d4 next__Q23FIX7SessionRCQ23FIX7Message (354970, f587f330, 354b20, 0, 0, 0) + 394 f41413c0 next__Q23FIX7SessionRCQ24_STLt12basic_string3ZcZQ24_STLt11char_traits1Zc ZQ24_STLt9allocator1Zc (354970, f587f450, 0, 3b5118, 6f0, 0) + 3c f41528d8 read__Q23FIX16SocketConnectionRQ23FIX15SocketConnector (2e0e70, 10d0a4, f587f4e0, 5000, ff33b1bc, ffffffff) + 8c f4155028 onData__Q23FIX15SocketInitiatorRQ23FIX15SocketConnectori (10cfd8, 10d0a4 , 15, f4154f9c, 160, f587d4f0) + 8c f464a58c onEvent__Q23FIX16ConnectorWrapperRQ23FIX13SocketMonitori (f587f6e8, 10d0 a4, 15, f464a510, 10d0a8, 0) + 7c f4156bd4 block__Q23FIX13SocketMonitorRQ33FIX13SocketMonitor8Strategy (10d0a4, f58 7f6e8, 10d05c, f4154974, 1, f587f6fc) + 2d0 f4153ef8 block__Q23FIX15SocketConnectorRQ33FIX15SocketConnector8Strategy (10d0a4, 10d05c, 0, 0, ff382000, 0) + 2c f4154944 onStart__Q23FIX15SocketInitiator (10cfd8, 10cfd8, f4154910, f4686c00, ec , 0) + 34 f4108c20 start__Q23FIX9Initiator (10cfd8, 6, 269d8, f587f970, ff1fe2a0, ff209990) + 1a8 f41343d8 Java_org_quickfix_SocketInitiator_doStart (8f2a4, f587fa64, f587fc48, 0, 1, 0) + 2c 0007a8f0 ???????? (f64689a0, f587fc48, 8f220, ff1fe2a0, b7, f9d59260) 00077a74 ???????? (f64689a0, 79abc, 8f220, 80bc8, f9a86030, 0) 00077d1c ???????? (f6f7e7d0, 79abc, f587fbdc, 80d68, ff1fe2a0, 0) 00077d1c ???????? (0, 1, ff20a500, 82ebc, 1e, e) ff232454 __1cMStubRoutinesG_code1_ (f587fc68, f587fea0, a, f9816050, 79abc, f587f dec) + 410 fefcd23c __1cJJavaCallsLcall_helper6FpnJJavaValue_pnMmethodHandle_pnRJavaCallArgu ments_pnGThread__v_ (f587fe98, ff1fe2a0, f587fde4, 8f220, 79abc, f587fea0) + 308 fefcc8d4 __1cJJavaCallsMcall_virtual6FpnJJavaValue_nLKlassHandle_nMsymbolHandle_4 pnRJavaCallArguments_pnGThread__v_ (f9816cc8, f587fdd0, f587fdd4, ff1fe2a0, f587fe 98, f587fde4) + 150 fefcc944 __1cJJavaCallsMcall_virtual6FpnJJavaValue_nGHandle_nLKlassHandle_nMsymbo lHandle_5pnGThread__v_ (f587fe98, f587fe94, f587fe90, f587fe84, f587fe7c, 8f220) + 60 feffd7d8 __1cMthread_entry6FpnKJavaThread_pnGThread__v_ (f9816cc8, 8f220, ff1fe2a 0, ff1fe2a0, 3, 8f220) + 17c ff0d5078 __1cKJavaThreadDrun6M_v_ (f5800000, ff207d18, ff1fe2a0, 80000, 8f220, 80 000) + 36c ff070918 _start (ff1fe2a0, 0, 0, 0, 0, 0) + 20 ff370694 _lwp_start (0, 0, 0, 0, 0, 0) ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger for complex code. Debugging C/C++ programs can leave you feeling lost and disoriented. TotalView can help you find your way. Available on major UNIX and Linux platforms. Try it free. www.etnus.com _______________________________________________ Quickfix-developers mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-developers --------------------------------- Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more |