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

batch merge in Write Operator #394

Open
yang20150702 opened this issue Feb 10, 2022 · 0 comments
Open

batch merge in Write Operator #394

yang20150702 opened this issue Feb 10, 2022 · 0 comments

Comments

@yang20150702
Copy link

yang20150702 commented Feb 10, 2022

I'm learning the source code of goleveldb. I find an issue about batch merge in db.Write func.
I want to know the design of batch, maybe my understanding is wrong.
this picture is about test case.
sc_20220210163255

writeLocks

in Write func: db.writeMergeC <- writeMerge{sync: sync, batch: batch}:
in writeLocked func:
this two func is synchronous. if this case executes in Write func, this logic will block.
I think the logic of batch merge should be asynchronous

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

No branches or pull requests

1 participant