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

expire subsystem should be refactored for scale #1714

Open
gdamore opened this issue Nov 26, 2023 · 0 comments
Open

expire subsystem should be refactored for scale #1714

gdamore opened this issue Nov 26, 2023 · 0 comments

Comments

@gdamore
Copy link
Contributor

gdamore commented Nov 26, 2023

The single most painful and complex part of NNG's bowels is the asynchronous expiration system. It also puts the most stress on the system for lock contention.

What perhaps we should do is build on the idea of aio completion lists, and move from the one monolithic expire queue to individual subsystem queue (or better a queue per socket!), and to place the aios on an expiration list for that socket that is controlled by the subsystem lock.

This would allow for much simpler cancellation & completion.

We need to make sure we are sensible about linear search times with a single list. Perhaps it's time for NNG to get a minheap.

This is probably a substantial refactoring.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant