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

When RuntimeException is thrown within a call-back and DisconnectOnError=Y the session does not get disconnected automatically

    Details

    • Type: Bug
    • Status: Open
    • Priority: Default
    • Resolution: Unresolved
    • Affects Version/s: 1.5.3
    • Fix Version/s: None
    • Component/s: Engine
    • Labels:
      None

      Description

      Hi,

      When a RuntimeException is thrown within a call-back and the "DisconnectOnError" parameter is set to "Y" the session does not get disconnected automatically unless the "RejectMessageOnUnhandledException" parameter is also set to "Y". This dependency is not documented, but even if it was, it wouldn’t make too much sense.

      It seems to be logical to understand an occurrence of a RuntimeException within a call-back as an error condition on its own, which should be sufficient to trigger the disconnection logic dictated by the "DisconnectOnError" parameter (regardless of any other settings).

      Currently, if RejectMessageOnUnhandledException=N, the engine simply ignores the message for which the exception was thrown even though DisconnectOnError=Y (although it reports the exception as an “error” in the log).

      Test code attached.

      Please note that probably all call-backs exhibit the same behaviour, not just the fromApp() call-back used in the TestApp class. It is also possible that the “ResetOnError” parameter is treated in a similar manner.

      Regards,
      Andrzej Hajderek

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              andrzej_ls Andrzej Hajderek
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: