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

engine: Do not ignore+detach shards with failed Open/Init ops #2464

Merged

Conversation

cthulhu-rider
Copy link
Contributor

Previously, storage engine ignored configured shards if they failed to open/init (with at least one successful). This behavior is unclear: if engine is configured to work with N shards, then all N shards must work, otherwise, the whole engine is broken and needs to be reconfigured.

Immediately fail engine's Open/Init methods on any shard failure. With this, it's redundant to open/init shard concurrently, so they are processed one-by-one now.

In the future, possibly, optional config flag will be added to ignore problem shards, but default behavior will be kept strict.

@codecov
Copy link

codecov bot commented Aug 1, 2023

Codecov Report

Merging #2464 (abe1928) into master (91f716b) will decrease coverage by 0.10%.
The diff coverage is 66.66%.

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

@@            Coverage Diff             @@
##           master    #2464      +/-   ##
==========================================
- Coverage   29.47%   29.38%   -0.10%     
==========================================
  Files         399      399              
  Lines       30433    30385      -48     
==========================================
- Hits         8971     8928      -43     
+ Misses      20718    20714       -4     
+ Partials      744      743       -1     
Files Changed Coverage Δ
pkg/local_object_storage/blobstor/control.go 63.33% <0.00%> (ø)
pkg/local_object_storage/engine/control.go 81.81% <100.00%> (-2.21%) ⬇️

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

Previously, storage engine ignored configured shards if they failed to
open/init (with at least one successful). This behavior is unclear: if
engine is configured to work with N shards, then all N shards must work,
otherwise, the whole engine is broken and needs to be reconfigured.

Immediately fail engine's  `Open`/`Init` methods on any shard failure.
With this, it's redundant to open/init shard concurrently, so they are
processed one-by-one now.

In the future, possibly, optional config flag will be added to ignore
problem shards, but default behavior will be kept strict.

Signed-off-by: Leonard Lyubich <[email protected]>
@cthulhu-rider cthulhu-rider merged commit 4a0198f into nspcc-dev:master Aug 8, 2023
7 of 8 checks passed
@cthulhu-rider cthulhu-rider deleted the bugfix/blobstor-init-failure branch August 8, 2023 16:53
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