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

Replace Semaphore with ReleasableLock in Engine and Translog related classes #17304

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

ahnyujin
Copy link

@ahnyujin ahnyujin commented Feb 8, 2025

Description

This refactor replaces the use of Semaphore with ReleasableLock for better consistency across the codebase. By aligning with the existing locking mechanisms, this change improves readability and ensures uniform lock acquisition and release patterns.

Changes

  • Replaced Semaphore with ReleasableLock in RemoteFsTranslog.
  • Ensured that lock handling follows the established project conventions.
  • Improved code maintainability by using a more structured locking approach.

Related Issues

Resolves #11360

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@github-actions github-actions bot added enhancement Enhancement or improvement to existing feature or request good first issue Good for newcomers Storage:Durability Issues and PRs related to the durability framework labels Feb 8, 2025
Copy link
Contributor

github-actions bot commented Feb 8, 2025

❌ Gradle check result for 93c1fbc: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Signed-off-by: Yujin Ahn <ujahnn@gmail.com>
Copy link
Contributor

github-actions bot commented Feb 9, 2025

❌ Gradle check result for 8cf56b4: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Member

@dbwiddis dbwiddis left a comment

Choose a reason for hiding this comment

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

LGTM Generally. A few comments/questions.

Signed-off-by: Yujin Ahn <ujahnn@gmail.com>
Signed-off-by: Yujin Ahn <ujahnn@gmail.com>
Copy link
Contributor

❌ Gradle check result for 6516873: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Signed-off-by: Yujin Ahn <ujahnn@gmail.com>
Copy link
Contributor

❌ Gradle check result for f82640b: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancement or improvement to existing feature or request good first issue Good for newcomers Storage:Durability Issues and PRs related to the durability framework
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Use ReleasableLock within Engine and Translog related classes
3 participants