frostfs-node/pkg/local_object_storage/pilorama/info.go
Evgenii Stratonikov 5408efef82 [#1333] services/control: Return pilorama info in ListShards RPC
Do not return backend type from the service for now, because memory
backend is expected to vanish.

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2022-07-08 13:27:17 +03:00

24 lines
537 B
Go

package pilorama
// Info groups the information about the pilorama.
type Info struct {
// Path contains path to the root-directory of the pilorama.
Path string
// Backend is the pilorama storage type. Either "boltdb" or "memory".
Backend string
}
// DumpInfo implements the ForestStorage interface.
func (t *boltForest) DumpInfo() Info {
return Info{
Path: t.path,
Backend: "boltdb",
}
}
// DumpInfo implements the ForestStorage interface.
func (f *memoryForest) DumpInfo() Info {
return Info{
Backend: "memory",
}
}