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

Clone read transactions into TxnManager message listener #6809

Merged
merged 6 commits into from
Feb 27, 2024

Conversation

emhane
Copy link
Member

@emhane emhane commented Feb 26, 2024

Closes #6807.

  • Changes signature of TxnManager::with_max_read_transaction_duration. Alt solution was to change

#[cfg(feature = "read-tx-timeouts")]
read_transactions: Option<std::sync::Arc<read_transactions::ReadTransactions>>,

to an Arc<Option<_>>, but that would result in a much larger diff and unsafe code.

@emhane emhane added C-bug An unexpected or incorrect behavior A-db Related to the database labels Feb 26, 2024
Copy link
Collaborator

@shekhirin shekhirin left a comment

Choose a reason for hiding this comment

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

LGTM, nice catch! Just doc comment fix + nit from my side.

I thought this functionality was covered by tests, but apparently not. Do you think we can add one?

crates/storage/libmdbx-rs/src/txn_manager.rs Outdated Show resolved Hide resolved
crates/storage/libmdbx-rs/src/environment.rs Outdated Show resolved Hide resolved
@emhane emhane added this pull request to the merge queue Feb 27, 2024
Merged via the queue into main with commit f5ce869 Feb 27, 2024
29 checks passed
@emhane emhane deleted the emhane/clone-read-txns branch February 27, 2024 01:09
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-db Related to the database C-bug An unexpected or incorrect behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use ReadTransactions in TxnManager message listener
2 participants