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

Move Aol mutex to Segment and make it conditional #171

Merged
merged 2 commits into from
Jan 27, 2025
Merged

Move Aol mutex to Segment and make it conditional #171

merged 2 commits into from
Jan 27, 2025

Conversation

gsserge
Copy link
Contributor

@gsserge gsserge commented Jan 22, 2025

  • The Aol is already thread safe due to RwLock at the Store level.
  • Concurrent reads are safe because of FileExt::read_at which does not change the file descriptor's cursor.
  • For the non-Unix platforms that do not provide read_at, use a conditional Mutex within the Segment object.
  • Use Mutex instead of RwLock to protect the fd cache.

@gsserge gsserge requested a review from arriqaaq January 22, 2025 11:38
@gsserge gsserge merged commit 3857b67 into main Jan 27, 2025
7 checks passed
@gsserge gsserge deleted the aol_mutex branch January 27, 2025 09:14
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