Skip to content

Vote generator write queue#4556

Merged
clemahieu merged 2 commits intonanocurrency:developfrom
clemahieu:vote_generator_write_queue
Apr 13, 2024
Merged

Vote generator write queue#4556
clemahieu merged 2 commits intonanocurrency:developfrom
clemahieu:vote_generator_write_queue

Conversation

@clemahieu
Copy link
Copy Markdown
Contributor

Changes the vote_generators to respect the database write queue.

Add consistency check to ensure the writer token is not already queued since they're waited for by value.
Change wait-loop to use the predicated overload of wait.

Add consistency check to ensure the writer token is not already queued since they're waited for by value.
Change wait-loop to use the predicated overload of wait.
Previously the vote_generator was not respecting the write_queue.
Copy link
Copy Markdown
Contributor

@pwojcikdev pwojcikdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was there any performance or stability problem with previous code? Or it's just for consistency?

@clemahieu
Copy link
Copy Markdown
Contributor Author

clemahieu commented Apr 13, 2024

Was there any performance or stability problem with previous code? Or it's just for consistency?

Yea there was a weird behavior where one of the schedulers (I think hinted) would 95% of the time execute something instantly but sometimes it would take multiple seconds.

This was on the transaction locks branch so it's hard to tell since that's still being debugged. It's worth a new performance analysis with this.

@clemahieu clemahieu merged commit 06ef24b into nanocurrency:develop Apr 13, 2024
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