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

writecache: flush cache when moving to the DEGRADED mode #1825

Merged
merged 1 commit into from
Oct 4, 2022

Conversation

fyrchik
Copy link
Contributor

@fyrchik fyrchik commented Sep 30, 2022

Degraded mode allows us to operate without an SSD, thus writecache should be unavailable in this mode.

Signed-off-by: Evgenii Stratonikov evgeniy@morphbits.ru

@codecov
Copy link

codecov bot commented Sep 30, 2022

Codecov Report

Merging #1825 (c13cba1) into master (2e3ef81) will increase coverage by 0.01%.
The diff coverage is 85.71%.

❗ Current head c13cba1 differs from pull request most recent head f105dc1. Consider uploading reports for the commit f105dc1 to get more accurate results

@@            Coverage Diff             @@
##           master    #1825      +/-   ##
==========================================
+ Coverage   31.06%   31.08%   +0.01%     
==========================================
  Files         374      374              
  Lines       26377    26384       +7     
==========================================
+ Hits         8195     8202       +7     
  Misses      17492    17492              
  Partials      690      690              
Impacted Files Coverage Δ
pkg/local_object_storage/writecache/flush.go 48.27% <50.00%> (+0.60%) ⬆️
pkg/local_object_storage/shard/put.go 75.00% <100.00%> (+0.80%) ⬆️
pkg/local_object_storage/writecache/mode.go 68.18% <100.00%> (+7.07%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

acid-ant
acid-ant previously approved these changes Sep 30, 2022
carpawell
carpawell previously approved these changes Oct 4, 2022
@@ -59,7 +59,7 @@ func (c *cache) runFlushLoop() {
}()
}

func (c *cache) flush() {
func (c *cache) flushDB() {
Copy link
Member

Choose a reason for hiding this comment

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

why that renaming?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because we already have OpenDB

…mode

Degraded mode allows us to operate without an SSD,
thus writecache should be unavailable in this mode.

Signed-off-by: Evgenii Stratonikov <evgeniy@morphbits.ru>
@fyrchik fyrchik merged commit 8b3b16f into nspcc-dev:master Oct 4, 2022
aprasolova pushed a commit to aprasolova/neofs-node that referenced this pull request Oct 19, 2022
…mode

Degraded mode allows us to operate without an SSD,
thus writecache should be unavailable in this mode.

Signed-off-by: Evgenii Stratonikov <evgeniy@morphbits.ru>
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