Skip to content

Fix pre-reset callback for sessions that are not logged on - #1346

Open
6democratickim9 wants to merge 1 commit into
quickfix-j:masterfrom
6democratickim9:codex/fix-327-reset-callback
Open

6democratickim9 wants to merge 1 commit into
quickfix-j:masterfrom
6democratickim9:codex/fix-327-reset-callback

Conversation

@6democratickim9

Copy link
Copy Markdown

Summary

Call ApplicationExtended.onBeforeSessionReset() from Session.reset()
even when the session is disconnected or not yet logged on.

The callback runs before the message store is reset. Logged-on sessions
retain the existing Logout handshake.

Fixes #327

Tests

  • Added coverage for disconnected, connected-but-not-logged-on,
    and logged-on sessions.
  • Verified callback count, store contents before reset, and reset completion.
  • Before the fix: 2 of the 3 regression tests failed.
  • After the fix: all 81 SessionTest tests passed.
  • Full Maven clean install passed on Java 21 with
    skipBundlePlugin,minimal-fix-latest and Javadoc generation skipped.

@codecov

codecov Bot commented Oct 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 70.81%. Comparing base (149869e) to head (3244c81).

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1346      +/-   ##
============================================
+ Coverage     70.79%   70.81%   +0.02%     
  Complexity     2270     2270              
============================================
  Files           161      161              
  Lines          9077     9077              
  Branches       1192     1192              
============================================
+ Hits           6426     6428       +2     
+ Misses         2198     2196       -2     
  Partials        453      453              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

quickfix.ApplicationExtended#onBeforeSessionReset(SessionID) called only if session has responder and is logged on

1 participant