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

feat(wal): reduce concurrent conflicts between block write operations and poll operations #1554

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

Conversation

RapperCL
Copy link

@Chillax-0v0 Chillax-0v0 changed the title feat(wal):reduce concurrent conflicts between block write operations and poll operations (#1550) feat(wal): reduce concurrent conflicts between block write operations and poll operations (#1550) Jul 11, 2024
@Chillax-0v0 Chillax-0v0 changed the title feat(wal): reduce concurrent conflicts between block write operations and poll operations (#1550) feat(wal): reduce concurrent conflicts between block write operations and poll operations Jul 11, 2024
@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


chenyong152 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@Chillax-0v0
Copy link
Contributor

Hello, @RapperCL, you can update your code within the same PR; there's no need to create multiple PRs.

@Chillax-0v0

This comment was marked as resolved.

@RapperCL

This comment was marked as resolved.

@Chillax-0v0

This comment was marked as resolved.

Comment on lines 64 to 68
* The lock of {@link #pendingBlocks}, {@link #writingBlocks}, {@link #currentBlock}.
*/
private final Lock blockLock = new ReentrantLock();

private final Lock pollBlocKLock = new ReentrantLock();
Copy link
Contributor

Choose a reason for hiding this comment

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

The comments for blockLock should be updated, and meanwhile, add some comments for pollBlockLock.

Copy link
Contributor

Choose a reason for hiding this comment

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

Now pendingBlocks is not protected by blockLock, comments of blockLock should be updated.

@Chillax-0v0
Copy link
Contributor

We have provided a tool called "WriteBench" for testing WAL performance. You can use it to compare the performance before and after the modifications to confirm their effectiveness.

@RapperCL
Copy link
Author

We have provided a tool called "WriteBench" for testing WAL performance. You can use it to compare the performance before and after the modifications to confirm their effectiveness.

Okay, I'll find some time later to test it.

@Chillax-0v0
Copy link
Contributor

#1550 (comment)

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.

None yet

3 participants