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(kv): clear RPC method which completely cleans storage #736

Merged
merged 6 commits into from
Jun 24, 2021

Conversation

rustatian
Copy link
Member

Reason for This PR

closes #735

Description of Changes

  • Implement Clear method for all supported storages.
  • Memcached via flush_all.
  • Memory - destroy memory region.
  • Redis - flush DB (only connected to the KV DB)
  • BoltDB - delete and recreate bucket.

License Acceptance

By submitting this pull request, I confirm that my contribution is made under
the terms of the MIT license.

PR Checklist

[Author TODO: Meet these criteria.]
[Reviewer TODO: Verify that these criteria are met. Request changes if not]

  • All commits in this PR are signed (git commit -s).
  • The reason for this PR is clearly provided (issue no. or explanation).
  • The description of changes is clear and encompassing.
  • Any required documentation changes (code and docs) are included in this PR.
  • Any user-facing changes are mentioned in CHANGELOG.md.
  • All added/changed functionality is tested.

Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
@rustatian rustatian added C-enhancement Category: enhancement. Meaning improvements of current module, transport, etc.. B-missing feature Bug: missing feature after implementation beta-nominated Nominated for backporting to the RR in the beta channel. labels Jun 24, 2021
@rustatian rustatian added this to the 2.3.1 milestone Jun 24, 2021
@rustatian rustatian requested a review from wolfy-j June 24, 2021 12:34
@rustatian rustatian self-assigned this Jun 24, 2021
Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
@codecov
Copy link

codecov bot commented Jun 24, 2021

Codecov Report

Merging #736 (60001db) into master (87d023d) will decrease coverage by 0.06%.
The diff coverage is 58.53%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #736      +/-   ##
==========================================
- Coverage   67.57%   67.51%   -0.07%     
==========================================
  Files          94       94              
  Lines        4824     4885      +61     
==========================================
+ Hits         3260     3298      +38     
- Misses       1151     1165      +14     
- Partials      413      422       +9     
Impacted Files Coverage Δ
plugins/kv/drivers/memcached/driver.go 49.50% <40.00%> (-0.50%) ⬇️
plugins/redis/kv.go 60.34% <50.00%> (-0.37%) ⬇️
plugins/kv/drivers/boltdb/driver.go 52.46% <52.63%> (+0.01%) ⬆️
plugins/kv/rpc.go 71.23% <57.14%> (-1.50%) ⬇️
plugins/memory/kv.go 62.85% <100.00%> (+2.25%) ⬆️
plugins/websockets/pool/workers_pool.go 62.74% <0.00%> (-7.85%) ⬇️
plugins/websockets/validator/access_validator.go 77.77% <0.00%> (-3.48%) ⬇️
plugins/broadcast/rpc.go 62.50% <0.00%> (+9.37%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ce53a8e...60001db. Read the comment docs.

Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
Signed-off-by: Valery Piashchynski <piashchynski.valery@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B-missing feature Bug: missing feature after implementation beta-nominated Nominated for backporting to the RR in the beta channel. C-enhancement Category: enhancement. Meaning improvements of current module, transport, etc..
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEATURE REQUEST, KV] RPC support for the kv.Clear method
1 participant