[#1121] node: Change mode of shard components
Signed-off-by: Alexander Chuprov <a.chuprov@yadro.com>
This commit is contained in:
parent
6f2187a420
commit
806236da78
47 changed files with 194 additions and 100 deletions
|
@ -27,15 +27,14 @@ func (b *BlobStor) Open(ctx context.Context, mode mode.Mode) error {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (b *BlobStor) openBlobStor(ctx context.Context, mode mode.Mode) error {
|
||||
readOnly := mode.ReadOnly()
|
||||
func (b *BlobStor) openBlobStor(ctx context.Context, mod mode.Mode) error {
|
||||
for i := range b.storage {
|
||||
select {
|
||||
case <-ctx.Done():
|
||||
return ctx.Err()
|
||||
default:
|
||||
}
|
||||
err := b.storage[i].Storage.Open(readOnly)
|
||||
err := b.storage[i].Storage.Open(mode.ConvertToComponentMode(mod))
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue