Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demonstrate issue exceeding numInGroup in ControlNotification and avoid leaking offline sessions #506

Merged
merged 2 commits into from
Apr 18, 2024

Conversation

ZachBray
Copy link
Contributor

Please see the commit messages for more details.

Note that this only fixes the group encoding exception when there are fewer than uint8.MAX_VALUE sessions.
We might want to introduce maximum session count limits too.

Apologies for the imports moving. Is there an IntelliJ Code Style file somewhere?

Relates to support ticket: 18482.

Session reconnections in `soleLibraryMode` cause
`LiveLibraryInfo#allSessions` to grow, as offline sessions are not
removed.

Upon a library timeout and reconnection, the engine attempts to send
details of these sessions to the library; however, that exceeds the
maximum group size.
Relates to support ticket 18482.

When using `soleLibraryMode` and a FIX session disconnects, the engine
will keep the session instance in `LiveLibraryInfo` but mark it as
disconnected (e.g., removing the endpoint information and
`connectionId`).

When a FIX session reconnects, a new session will be added to
`LiveLibraryInfo` regardless of whether or not there is an existing
session.

In this commit, I've added a removal as part of `addSession` maintaining
an invariant that `LiveLibraryInfo` has only one session instance per
`sessionId`. I believe this is safe, but I'm not hugely familiar with
lots of the code paths. I have added some logging in case I have missed
something. There are some long standing checks around duplicate
sessions, which gives me hope.
@vyazelenko
Copy link
Contributor

@ZachBray I use Intellij editor config from Aeron.

@vyazelenko vyazelenko merged commit 74a8858 into 0.139-updates Apr 18, 2024
@ZachBray ZachBray deleted the bugfix/ticket-18482 branch April 18, 2024 14:51
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.

2 participants