[QFJ-337] IoSessionResponder.send does not return true when message is sent Created: 19/Aug/08  Updated: 06/Oct/08  Resolved: 08/Sep/08

Status: Closed
Project: QuickFIX/J
Component/s: Engine, Networking
Affects Version/s: 1.3.2
Fix Version/s: 1.3.3

Type: Bug Priority: Default
Reporter: Michael Franz Assignee: Unassigned
Resolution: Fixed Votes: 1
Labels: None
Environment:

Windows XP
Java 1.6.0_07



 Description   

IoSessionResponder.send does not return true when message is sent. isWritten does not wait to see if the data has been written. Presumably the data is being written in another thread (since a Future is returned) from ioSession.write. If the thread doing the writing has not had time to execute the isWritten will return false even though the message will be written after the isWritten has been called. The writing needs to be performed in the same thread as the call, or the current thread needs to wait for the thread doing the writing to return.

The method in question is:
return ioSession.write(data).isWritten();

When running this through the debugger the behavior is most likely correct (as can be the case with multi-threaded applications), but if running with just logging send method will return false even though the record is sent.


Generated at Sat Nov 23 07:38:45 UTC 2024 using JIRA 7.5.2#75007-sha1:9f5725bb824792b3230a5d8716f0c13e296a3cae.