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

refactor: move write_batch_delete into rocksdb_wrapper #669

Merged
merged 5 commits into from
Jan 6, 2021

Conversation

levy5307
Copy link
Contributor

@levy5307 levy5307 commented Jan 5, 2021

What problem does this PR solve?

move write_batch_delete into rocksdb_wrapper, and use it to reimplement multi_remove

  • Manual test (add detailed scripts or steps below)
>>> use temp
OK
>>> multi_set hash sort1 value1 sort2 value2 sort3 value3 sort4 value4
OK

app_id          : 2
partition_index : 4
decree          : 9
server          : 10.232.55.210:34802
>>> multi_get hash
"hash" : "sort1" => "value1"
"hash" : "sort2" => "value2"
"hash" : "sort3" => "value3"
"hash" : "sort4" => "value4"

4 key-value pairs got, fetch completed.

app_id          : 2
partition_index : 4
server          : 10.232.55.210:34802
>>> multi_del hash sort1
1 key-value pairs deleted.

app_id          : 2
partition_index : 4
decree          : 10
server          : 10.232.55.210:34802
>>> multi_get hash
"hash" : "sort2" => "value2"
"hash" : "sort3" => "value3"
"hash" : "sort4" => "value4"

3 key-value pairs got, fetch completed.

app_id          : 2
partition_index : 4
server          : 10.232.55.210:34802
>>> multi_del hash sort2 sort3
2 key-value pairs deleted.

app_id          : 2
partition_index : 4
decree          : 11
server          : 10.232.55.210:34802
>>> multi_get hash
"hash" : "sort4" => "value4"

1 key-value pairs got, fetch completed.

app_id          : 2
partition_index : 4
server          : 10.232.55.210:34802
>>> multi_del hash sort4
1 key-value pairs deleted.

app_id          : 2
partition_index : 4
decree          : 13
server          : 10.232.55.210:34802
>>> multi_get hash

0 key-value pairs got, fetch completed.

app_id          : 2
partition_index : 4
server          : 10.232.55.210:34802

@levy5307 levy5307 closed this Jan 5, 2021
@levy5307 levy5307 reopened this Jan 5, 2021
@levy5307 levy5307 closed this Jan 5, 2021
@levy5307 levy5307 reopened this Jan 5, 2021
@levy5307 levy5307 closed this Jan 5, 2021
@levy5307 levy5307 reopened this Jan 5, 2021
@levy5307 levy5307 merged commit 9ab1a01 into apache:master Jan 6, 2021
@neverchanje neverchanje mentioned this pull request Mar 1, 2021
@levy5307 levy5307 deleted the write-batch-delete branch March 18, 2021 03:16
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.

3 participants