forked from TrueCloudLab/frostfs-contract
[#185] *: Use storage.DeserializeValues
flag for search
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
23d9799e51
commit
e6a33e8193
2 changed files with 4 additions and 6 deletions
|
@ -537,10 +537,9 @@ func filterNetmap(ctx storage.Context, st nodeState) []storageNode {
|
|||
func getNetmapNodes(ctx storage.Context) []netmapNode {
|
||||
result := []netmapNode{}
|
||||
|
||||
it := storage.Find(ctx, candidatePrefix, storage.ValuesOnly)
|
||||
it := storage.Find(ctx, candidatePrefix, storage.ValuesOnly|storage.DeserializeValues)
|
||||
for iterator.Next(it) {
|
||||
rawNode := iterator.Value(it).([]byte)
|
||||
node := std.Deserialize(rawNode).(netmapNode)
|
||||
node := iterator.Value(it).(netmapNode)
|
||||
result = append(result, node)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue