forked from TrueCloudLab/frostfs-node
[#1840] blobstor: Return info about all components
Signed-off-by: Evgenii Stratonikov <evgeniy@morphbits.ru>
This commit is contained in:
parent
6d7ffefec5
commit
4b005d3178
12 changed files with 246 additions and 88 deletions
|
@ -1,13 +1,14 @@
|
|||
package blobstor
|
||||
|
||||
import "github.com/nspcc-dev/neofs-node/pkg/local_object_storage/blobstor/fstree"
|
||||
|
||||
// DumpInfo returns information about blob stor.
|
||||
func (b *BlobStor) DumpInfo() fstree.Info {
|
||||
func (b *BlobStor) DumpInfo() Info {
|
||||
sub := make([]SubStorageInfo, len(b.storage))
|
||||
for i := range b.storage {
|
||||
if b.storage[i].Storage.Type() == "fstree" {
|
||||
return b.storage[i].Storage.(*fstree.FSTree).Info
|
||||
}
|
||||
sub[i].Path = b.storage[i].Storage.Path()
|
||||
sub[i].Type = b.storage[i].Storage.Type()
|
||||
}
|
||||
|
||||
return Info{
|
||||
SubStorages: sub,
|
||||
}
|
||||
return fstree.Info{}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue