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

Make struct ndb threadsafe #56

Merged
merged 2 commits into from
Dec 14, 2024
Merged

Make struct ndb threadsafe #56

merged 2 commits into from
Dec 14, 2024

Conversation

jb55
Copy link
Contributor

@jb55 jb55 commented Dec 10, 2024

The monitor and subscription access was technically not threadsafe. Let's fix that to avoid blowing our leg off in notecrumbs async rust land.

jb55 added 2 commits December 9, 2024 15:35
This was overkill and was using lots of memory

Signed-off-by: William Casarin <[email protected]>
This was the only thing that wasn't threadsafe. Add a simple mutex
instead of a queue so that polling is quick.

This also means we can't really return the internal subscriptions
anymore, so we remove that for now until we have a safer
interface.

Fixes: #55
Signed-off-by: William Casarin <[email protected]>
@jb55 jb55 linked an issue Dec 10, 2024 that may be closed by this pull request
@jb55 jb55 merged commit 67f3a5e into master Dec 14, 2024
1 check passed
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.

ndb_monitor is not threadsafe
1 participant