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

Write database queue functions should be NoOps with RocksDB #2795

Merged
merged 6 commits into from Aug 14, 2020

Conversation

wezrule
Copy link
Contributor

@wezrule wezrule commented Jun 2, 2020

The write_database_queue is currently used by the block processor and confirmation height processor. It's purpose was to provide a way to know if something was holding the LMDB write transaction, so instead of being blocked it could continue doing work. This is not necessary with RocksDB as it doesn't have a global write lock, so these operations can be no-ops essentially.

There were of course some tests relying on this behaviour to test somethings in the confirmation height processor. In those tests (any explicitly using write_database_queue::contains () or write_database_queue::wait ()) a new node flag force_use_write_database_queue can be set to true.

@wezrule wezrule added quality improvements This item indicates the need for or supplies changes that improve maintainability database Relates to lmdb or rocksdb labels Jun 2, 2020
@wezrule wezrule added this to the V22.0 milestone Jun 2, 2020
@wezrule wezrule self-assigned this Jun 2, 2020
@wezrule wezrule requested a review from SergiySW June 18, 2020 16:34
@wezrule wezrule merged commit 97277db into nanocurrency:develop Aug 14, 2020
@wezrule wezrule deleted the write_database_queue_noops branch August 14, 2020 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
database Relates to lmdb or rocksdb quality improvements This item indicates the need for or supplies changes that improve maintainability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants