Uploaded image for project: 'QuickFIX/J'
  1. QuickFIX/J
  2. QFJ-335

NullPointerException in LogUtil when logging event with SingleThreadedEventHandlingStrategy

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Default
    • Resolution: Fixed
    • Affects Version/s: 1.3.1
    • Fix Version/s: 1.3.3
    • Component/s: Engine
    • Labels:
      None
    • Environment:
      Windows XP
      Java 1.6.0_07

      Description

      When connecting and disconnecting to a server and the sequence numbers get out of sync the SingleThreadedEventHandlingStrategy tries to log an event after the initiator has closed all of its sessions. This causes the quickfix.LogUtil.logThrowable(LogUtil.java:54) to throw a NPE as there is no session to get the log from.

      This is an intermittent bug as there are a number of threads involved (QFJ Timer, SocketConnectorIoProcessor-6.0, and QFJ Message Processor). One iteration logs the following message:
      quickfix.SessionException Logon state is not valid for message (MsgType=5)
      another has the NPE and yet another has not issues at all.

      The full stack trace is:
      Exception in thread "QFJ Message Processor" java.lang.NullPointerException
      at quickfix.LogUtil.logThrowable(LogUtil.java:54)
      at quickfix.mina.SingleThreadedEventHandlingStrategy$SessionMessageEvent.processMessage(SingleThreadedEventHandlingStrategy.java:109)
      at quickfix.mina.SingleThreadedEventHandlingStrategy.block(SingleThreadedEventHandlingStrategy.java:70)
      at quickfix.mina.SingleThreadedEventHandlingStrategy$1.run(SingleThreadedEventHandlingStrategy.java:86)
      at java.lang.Thread.run(Thread.java:619)

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              mvfranz Michael Franz
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: