forked from TrueCloudLab/frostfs-api-go
[#19] subnet: Drop related types and fields
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
parent
bd44a3f47b
commit
ff6d8db741
23 changed files with 171 additions and 1484 deletions
|
@ -1,232 +0,0 @@
|
|||
package netmap
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs"
|
||||
)
|
||||
|
||||
// prefix of keys to subnet attributes.
|
||||
const attrSubnetPrefix = "__SYSTEM__SUBNET_"
|
||||
|
||||
// prefix of keys to subnet attributes.
|
||||
// Deprecated: use attrSubnetPrefix
|
||||
const attrSubnetPrefixNeoFS = "__NEOFS__SUBNET_"
|
||||
|
||||
const (
|
||||
// subnet attribute's value denoting subnet entry
|
||||
attrSubnetValEntry = "True"
|
||||
|
||||
// subnet attribute's value denoting subnet exit
|
||||
attrSubnetValExit = "False"
|
||||
)
|
||||
|
||||
// NodeSubnetInfo groups information about subnet which can be written to NodeInfo.
|
||||
//
|
||||
// Zero value represents entry to zero subnet.
|
||||
type NodeSubnetInfo struct {
|
||||
exit bool
|
||||
|
||||
id *refs.SubnetID
|
||||
}
|
||||
|
||||
// Enabled returns true iff subnet membership is enabled for the node.
|
||||
func (x NodeSubnetInfo) Enabled() bool {
|
||||
return !x.exit
|
||||
}
|
||||
|
||||
// SetEntryFlag sets the subnet entry flag.
|
||||
func (x *NodeSubnetInfo) SetEntryFlag(enters bool) {
|
||||
x.exit = !enters
|
||||
}
|
||||
|
||||
// ID returns identifier of the subnet.
|
||||
func (x NodeSubnetInfo) ID() *refs.SubnetID {
|
||||
return x.id
|
||||
}
|
||||
|
||||
// SetID sets identifier of the subnet.
|
||||
func (x *NodeSubnetInfo) SetID(id *refs.SubnetID) {
|
||||
x.id = id
|
||||
}
|
||||
|
||||
func subnetAttributeKey(id *refs.SubnetID) string {
|
||||
txt, _ := id.MarshalText() // never returns an error
|
||||
|
||||
return attrSubnetPrefix + string(txt)
|
||||
}
|
||||
|
||||
// WriteSubnetInfo writes NodeSubnetInfo to NodeInfo via attributes. NodeInfo must not be nil.
|
||||
//
|
||||
// Existing subnet attributes are expected to be key-unique, otherwise undefined behavior.
|
||||
//
|
||||
// Does not add (removes existing) attribute if node:
|
||||
// - disables non-zero subnet;
|
||||
// - enables zero subnet.
|
||||
//
|
||||
// Attribute key is calculated from ID using format `__SYSTEM__SUBNET_%s`.
|
||||
// Attribute Value is:
|
||||
// - `True` if node enters the subnet;
|
||||
// - `False`, otherwise.
|
||||
func WriteSubnetInfo(node *NodeInfo, info NodeSubnetInfo) {
|
||||
attrs := node.GetAttributes()
|
||||
|
||||
id := info.ID()
|
||||
enters := info.Enabled()
|
||||
|
||||
// calculate attribute key
|
||||
key := subnetAttributeKey(id)
|
||||
|
||||
if refs.IsZeroSubnet(id) == enters {
|
||||
for i := range attrs {
|
||||
if attrs[i].GetKey() == key {
|
||||
attrs = append(attrs[:i], attrs[i+1:]...)
|
||||
break // attributes are expected to be key-unique
|
||||
}
|
||||
}
|
||||
} else {
|
||||
var val string
|
||||
|
||||
if enters {
|
||||
val = attrSubnetValEntry
|
||||
} else {
|
||||
val = attrSubnetValExit
|
||||
}
|
||||
|
||||
presented := false
|
||||
|
||||
for i := range attrs {
|
||||
if attrs[i].GetKey() == key {
|
||||
attrs[i].SetValue(val)
|
||||
presented = true
|
||||
}
|
||||
}
|
||||
|
||||
if !presented {
|
||||
index := len(attrs)
|
||||
attrs = append(attrs, Attribute{})
|
||||
attrs[index].SetKey(key)
|
||||
attrs[index].SetValue(val)
|
||||
}
|
||||
}
|
||||
|
||||
node.SetAttributes(attrs)
|
||||
}
|
||||
|
||||
// ErrRemoveSubnet is returned when a node needs to leave the subnet.
|
||||
var ErrRemoveSubnet = errors.New("remove subnet")
|
||||
|
||||
var errNoSubnets = errors.New("no subnets")
|
||||
|
||||
// IterateSubnets iterates over all subnets the node belongs to and passes the IDs to f.
|
||||
// Handler must not be nil.
|
||||
//
|
||||
// Subnet attributes are expected to be key-unique, otherwise undefined behavior.
|
||||
//
|
||||
// If f returns ErrRemoveSubnet, then removes subnet entry. Note that this leads to an instant mutation of NodeInfo.
|
||||
// Breaks on any other non-nil error and returns it.
|
||||
//
|
||||
// Returns an error if any subnet attribute has wrong format.
|
||||
// Returns an error if the node is not included in any subnet by the end of the loop.
|
||||
func IterateSubnets(node *NodeInfo, f func(refs.SubnetID) error) error {
|
||||
attrs := node.GetAttributes()
|
||||
|
||||
var (
|
||||
err error
|
||||
id refs.SubnetID
|
||||
entries uint
|
||||
|
||||
zeroEntry = true
|
||||
)
|
||||
|
||||
for i := 0; i < len(attrs); i++ { // range must not be used because of attrs mutation in body
|
||||
key := attrs[i].GetKey()
|
||||
|
||||
// cut subnet ID string
|
||||
idTxt := strings.TrimPrefix(key, attrSubnetPrefix)
|
||||
if len(idTxt) == len(key) {
|
||||
idTxt = strings.TrimPrefix(key, attrSubnetPrefixNeoFS)
|
||||
if len(idTxt) == len(key) {
|
||||
// not a subnet attribute
|
||||
continue
|
||||
}
|
||||
}
|
||||
|
||||
// check value
|
||||
val := attrs[i].GetValue()
|
||||
if val != attrSubnetValExit && val != attrSubnetValEntry {
|
||||
return fmt.Errorf("invalid attribute value: %s", val)
|
||||
}
|
||||
|
||||
// decode subnet ID
|
||||
if err = id.UnmarshalText([]byte(idTxt)); err != nil {
|
||||
return fmt.Errorf("invalid ID text: %w", err)
|
||||
}
|
||||
|
||||
// update status of zero subnet
|
||||
isZero := refs.IsZeroSubnet(&id)
|
||||
|
||||
if isZero {
|
||||
zeroEntry = val == attrSubnetValEntry
|
||||
}
|
||||
|
||||
// continue to process only the subnets to which the node belongs
|
||||
if val == attrSubnetValExit {
|
||||
continue
|
||||
}
|
||||
|
||||
// pass ID to the handler
|
||||
err = f(id)
|
||||
|
||||
isRemoveErr := errors.Is(err, ErrRemoveSubnet)
|
||||
|
||||
if err != nil && !isRemoveErr {
|
||||
return err
|
||||
}
|
||||
|
||||
if isRemoveErr {
|
||||
if isZero {
|
||||
// we can't remove attribute of zero subnet because it means entry
|
||||
attrs[i].SetValue(attrSubnetValExit)
|
||||
} else {
|
||||
// we can set False or remove attribute, latter is more memory/network efficient.
|
||||
attrs = append(attrs[:i], attrs[i+1:]...)
|
||||
i--
|
||||
}
|
||||
|
||||
continue
|
||||
}
|
||||
|
||||
entries++
|
||||
}
|
||||
|
||||
if zeroEntry {
|
||||
// missing attribute of zero subnet equivalent to entry
|
||||
refs.MakeZeroSubnet(&id)
|
||||
|
||||
err = f(id)
|
||||
if err != nil {
|
||||
if !errors.Is(err, ErrRemoveSubnet) {
|
||||
return err
|
||||
}
|
||||
|
||||
// zero subnet should be clearly removed with False value
|
||||
index := len(attrs)
|
||||
attrs = append(attrs, Attribute{})
|
||||
attrs[index].SetKey(subnetAttributeKey(&id))
|
||||
attrs[index].SetValue(attrSubnetValExit)
|
||||
} else {
|
||||
entries++
|
||||
}
|
||||
}
|
||||
|
||||
if entries <= 0 {
|
||||
return errNoSubnets
|
||||
}
|
||||
|
||||
node.SetAttributes(attrs)
|
||||
|
||||
return nil
|
||||
}
|
|
@ -1,361 +0,0 @@
|
|||
package netmap_test
|
||||
|
||||
import (
|
||||
"strconv"
|
||||
"testing"
|
||||
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/netmap"
|
||||
netmaptest "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/netmap/test"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
func subnetAttrKey(val string) string {
|
||||
return "__SYSTEM__SUBNET_" + val
|
||||
}
|
||||
|
||||
func assertSubnetAttrKey(t *testing.T, attr *netmap.Attribute, num uint32) {
|
||||
require.Equal(t, subnetAttrKey(strconv.FormatUint(uint64(num), 10)), attr.GetKey())
|
||||
}
|
||||
|
||||
func BenchmarkNodeAttributes(b *testing.B) {
|
||||
const size = 50
|
||||
|
||||
id := new(refs.SubnetID)
|
||||
id.SetValue(12)
|
||||
|
||||
attrs := make([]netmap.Attribute, size)
|
||||
for i := range attrs {
|
||||
if i == size/2 {
|
||||
attrs[i] = *netmaptest.GenerateAttribute(false)
|
||||
} else {
|
||||
data, err := id.MarshalText()
|
||||
require.NoError(b, err)
|
||||
|
||||
attrs[i].SetKey(subnetAttrKey(string(data)))
|
||||
attrs[i].SetValue("True")
|
||||
}
|
||||
}
|
||||
|
||||
var info netmap.NodeSubnetInfo
|
||||
info.SetID(id)
|
||||
info.SetEntryFlag(false)
|
||||
|
||||
node := new(netmap.NodeInfo)
|
||||
|
||||
// When using a single slice `StartTimer` overhead is comparable to the
|
||||
// function execution time, so we reduce this cost by updating slices in groups.
|
||||
const cacheSize = 1000
|
||||
a := make([][]netmap.Attribute, cacheSize)
|
||||
for i := range a {
|
||||
a[i] = make([]netmap.Attribute, size)
|
||||
}
|
||||
|
||||
b.ResetTimer()
|
||||
b.ReportAllocs()
|
||||
for i := 0; i < b.N; i++ {
|
||||
if i%cacheSize == 0 {
|
||||
b.StopTimer()
|
||||
for j := range a {
|
||||
copy(a[j], attrs)
|
||||
}
|
||||
b.StartTimer()
|
||||
}
|
||||
node.SetAttributes(a[i%cacheSize])
|
||||
netmap.WriteSubnetInfo(node, info)
|
||||
if len(node.GetAttributes())+1 != len(attrs) {
|
||||
b.FailNow()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestWriteSubnetInfo(t *testing.T) {
|
||||
t.Run("entry", func(t *testing.T) {
|
||||
t.Run("zero subnet", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
info netmap.NodeSubnetInfo
|
||||
)
|
||||
|
||||
netmap.WriteSubnetInfo(&node, info)
|
||||
|
||||
// entry to zero subnet does not require an attribute
|
||||
attrs := node.GetAttributes()
|
||||
require.Empty(t, attrs)
|
||||
|
||||
// exit the subnet
|
||||
info.SetEntryFlag(false)
|
||||
|
||||
netmap.WriteSubnetInfo(&node, info)
|
||||
|
||||
// exit from zero subnet should be clearly reflected in attributes
|
||||
attrs = node.GetAttributes()
|
||||
require.Len(t, attrs, 1)
|
||||
|
||||
attr := &attrs[0]
|
||||
assertSubnetAttrKey(t, attr, 0)
|
||||
require.Equal(t, "False", attr.GetValue())
|
||||
|
||||
// again enter to zero subnet
|
||||
info.SetEntryFlag(true)
|
||||
|
||||
netmap.WriteSubnetInfo(&node, info)
|
||||
|
||||
// attribute should be removed
|
||||
attrs = node.GetAttributes()
|
||||
require.Empty(t, attrs)
|
||||
})
|
||||
|
||||
t.Run("non-zero subnet", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
info netmap.NodeSubnetInfo
|
||||
id refs.SubnetID
|
||||
)
|
||||
|
||||
// create non-zero subnet ID
|
||||
const num = 15
|
||||
|
||||
id.SetValue(num)
|
||||
|
||||
// enter to the subnet
|
||||
info.SetID(&id)
|
||||
info.SetEntryFlag(true)
|
||||
|
||||
netmap.WriteSubnetInfo(&node, info)
|
||||
|
||||
// check attribute format
|
||||
attrs := node.GetAttributes()
|
||||
require.Len(t, attrs, 1)
|
||||
|
||||
attr := &attrs[0]
|
||||
assertSubnetAttrKey(t, attr, num)
|
||||
require.Equal(t, "True", attr.GetValue())
|
||||
|
||||
// again exit the subnet
|
||||
info.SetEntryFlag(false)
|
||||
|
||||
netmap.WriteSubnetInfo(&node, info)
|
||||
|
||||
// attribute should be removed
|
||||
attrs = node.GetAttributes()
|
||||
require.Empty(t, attrs)
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
func TestSubnets(t *testing.T) {
|
||||
t.Run("empty", func(t *testing.T) {
|
||||
var node netmap.NodeInfo
|
||||
|
||||
called := 0
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
called++
|
||||
|
||||
require.True(t, refs.IsZeroSubnet(&id))
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
require.NoError(t, err)
|
||||
require.EqualValues(t, 1, called)
|
||||
})
|
||||
|
||||
t.Run("with correct attribute", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
|
||||
attrEntry, attrExit netmap.Attribute
|
||||
)
|
||||
|
||||
const (
|
||||
numEntry = 13
|
||||
numExit = 14
|
||||
)
|
||||
|
||||
attrEntry.SetKey(subnetAttrKey(strconv.FormatUint(numEntry, 10)))
|
||||
attrEntry.SetValue("True")
|
||||
|
||||
attrExit.SetKey(subnetAttrKey(strconv.FormatUint(numExit, 10)))
|
||||
attrExit.SetValue("False")
|
||||
|
||||
attrs := []netmap.Attribute{attrEntry, attrEntry}
|
||||
|
||||
node.SetAttributes(attrs)
|
||||
|
||||
mCalledNums := make(map[uint32]struct{})
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
mCalledNums[id.GetValue()] = struct{}{}
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
require.NoError(t, err)
|
||||
require.Len(t, mCalledNums, 2)
|
||||
|
||||
_, ok := mCalledNums[numEntry]
|
||||
require.True(t, ok)
|
||||
|
||||
_, ok = mCalledNums[numExit]
|
||||
require.False(t, ok)
|
||||
|
||||
_, ok = mCalledNums[0]
|
||||
require.True(t, ok)
|
||||
})
|
||||
|
||||
t.Run("with incorrect attribute", func(t *testing.T) {
|
||||
assertErr := func(attr netmap.Attribute) {
|
||||
var node netmap.NodeInfo
|
||||
|
||||
node.SetAttributes([]netmap.Attribute{attr})
|
||||
|
||||
require.Error(t, netmap.IterateSubnets(&node, func(refs.SubnetID) error {
|
||||
return nil
|
||||
}))
|
||||
}
|
||||
|
||||
t.Run("incorrect key", func(t *testing.T) {
|
||||
var attr netmap.Attribute
|
||||
|
||||
attr.SetKey(subnetAttrKey("one-two-three"))
|
||||
|
||||
assertErr(attr)
|
||||
})
|
||||
|
||||
t.Run("incorrect value", func(t *testing.T) {
|
||||
var attr netmap.Attribute
|
||||
|
||||
attr.SetKey(subnetAttrKey("1"))
|
||||
|
||||
for _, invalidVal := range []string{
|
||||
"",
|
||||
"Troo",
|
||||
"Fols",
|
||||
} {
|
||||
attr.SetValue(invalidVal)
|
||||
assertErr(attr)
|
||||
}
|
||||
|
||||
assertErr(attr)
|
||||
})
|
||||
})
|
||||
|
||||
t.Run("remove entry", func(t *testing.T) {
|
||||
t.Run("zero", func(t *testing.T) {
|
||||
var node netmap.NodeInfo
|
||||
|
||||
// enter to some non-zero subnet so that zero is not the only one
|
||||
var attr netmap.Attribute
|
||||
|
||||
attr.SetKey(subnetAttrKey("321"))
|
||||
attr.SetValue("True")
|
||||
|
||||
attrs := []netmap.Attribute{attr}
|
||||
node.SetAttributes(attrs)
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
if refs.IsZeroSubnet(&id) {
|
||||
return netmap.ErrRemoveSubnet
|
||||
}
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
require.NoError(t, err)
|
||||
|
||||
attrs = node.GetAttributes()
|
||||
require.Len(t, attrs, 2)
|
||||
|
||||
found := false
|
||||
|
||||
for i := range attrs {
|
||||
if attrs[i].GetKey() == subnetAttrKey("0") {
|
||||
require.Equal(t, "False", attrs[i].GetValue())
|
||||
found = true
|
||||
}
|
||||
}
|
||||
|
||||
require.True(t, found)
|
||||
})
|
||||
|
||||
t.Run("non-zero", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
attr netmap.Attribute
|
||||
)
|
||||
|
||||
attr.SetKey(subnetAttrKey("99"))
|
||||
attr.SetValue("True")
|
||||
|
||||
attrs := []netmap.Attribute{attr}
|
||||
node.SetAttributes(attrs)
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
if !refs.IsZeroSubnet(&id) {
|
||||
return netmap.ErrRemoveSubnet
|
||||
}
|
||||
|
||||
return nil
|
||||
})
|
||||
|
||||
require.NoError(t, err)
|
||||
|
||||
attrs = node.GetAttributes()
|
||||
require.Empty(t, attrs)
|
||||
})
|
||||
|
||||
t.Run("all", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
attrs []netmap.Attribute
|
||||
)
|
||||
|
||||
// enter to some non-zero subnet so that zero is not the only one
|
||||
for i := 1; i <= 5; i++ {
|
||||
var attr netmap.Attribute
|
||||
|
||||
attr.SetKey(subnetAttrKey(strconv.Itoa(i)))
|
||||
attr.SetValue("True")
|
||||
|
||||
attrs = append(attrs, attr)
|
||||
}
|
||||
|
||||
node.SetAttributes(attrs)
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
return netmap.ErrRemoveSubnet
|
||||
})
|
||||
|
||||
require.Error(t, err)
|
||||
})
|
||||
})
|
||||
|
||||
t.Run("zero subnet removal via attribute", func(t *testing.T) {
|
||||
var (
|
||||
node netmap.NodeInfo
|
||||
|
||||
attrZero, attrOther netmap.Attribute
|
||||
)
|
||||
|
||||
attrZero.SetKey(subnetAttrKey("0"))
|
||||
attrZero.SetValue("False")
|
||||
|
||||
attrOther.SetKey(subnetAttrKey("1"))
|
||||
attrOther.SetValue("True")
|
||||
|
||||
node.SetAttributes([]netmap.Attribute{attrZero, attrOther})
|
||||
|
||||
calledCount := 0
|
||||
|
||||
err := netmap.IterateSubnets(&node, func(id refs.SubnetID) error {
|
||||
require.False(t, refs.IsZeroSubnet(&id))
|
||||
calledCount++
|
||||
return nil
|
||||
})
|
||||
|
||||
require.NoError(t, err)
|
||||
require.EqualValues(t, 1, calledCount)
|
||||
})
|
||||
}
|
|
@ -198,7 +198,6 @@ func (p *PlacementPolicy) ToGRPCMessage() grpc.Message {
|
|||
m.SetSelectors(SelectorsToGRPC(p.selectors))
|
||||
m.SetReplicas(ReplicasToGRPC(p.replicas))
|
||||
m.SetContainerBackupFactor(p.backupFactor)
|
||||
m.SetSubnetID(p.subnetID.ToGRPCMessage().(*refsGRPC.SubnetID))
|
||||
}
|
||||
|
||||
return m
|
||||
|
@ -227,20 +226,6 @@ func (p *PlacementPolicy) FromGRPCMessage(m grpc.Message) error {
|
|||
return err
|
||||
}
|
||||
|
||||
subnetID := v.GetSubnetId()
|
||||
if subnetID == nil {
|
||||
p.subnetID = nil
|
||||
} else {
|
||||
if p.subnetID == nil {
|
||||
p.subnetID = new(refs.SubnetID)
|
||||
}
|
||||
|
||||
err = p.subnetID.FromGRPCMessage(subnetID)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
p.backupFactor = v.GetContainerBackupFactor()
|
||||
|
||||
return nil
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package netmap
|
||||
|
||||
import refs "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs/grpc"
|
||||
|
||||
// SetReplicas of placement policy.
|
||||
func (m *PlacementPolicy) SetReplicas(v []*Replica) {
|
||||
m.Replicas = v
|
||||
|
@ -22,11 +20,6 @@ func (m *PlacementPolicy) SetFilters(v []*Filter) {
|
|||
m.Filters = v
|
||||
}
|
||||
|
||||
// SetSubnetID sets ID of subnet.
|
||||
func (m *PlacementPolicy) SetSubnetID(v *refs.SubnetID) {
|
||||
m.SubnetId = v
|
||||
}
|
||||
|
||||
// SetName of placement filter.
|
||||
func (m *Filter) SetName(v string) {
|
||||
m.Name = v
|
||||
|
|
259
netmap/grpc/types.pb.go
generated
259
netmap/grpc/types.pb.go
generated
|
@ -7,7 +7,6 @@
|
|||
package netmap
|
||||
|
||||
import (
|
||||
grpc "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/refs/grpc"
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
|
@ -464,9 +463,6 @@ type PlacementPolicy struct {
|
|||
Selectors []*Selector `protobuf:"bytes,3,rep,name=selectors,proto3" json:"selectors,omitempty"`
|
||||
// List of named filters to reference in selectors
|
||||
Filters []*Filter `protobuf:"bytes,4,rep,name=filters,proto3" json:"filters,omitempty"`
|
||||
// Subnetwork ID to select nodes from. Zero subnet (default) represents
|
||||
// all of the nodes which didn't explicitly opt out of membership.
|
||||
SubnetId *grpc.SubnetID `protobuf:"bytes,5,opt,name=subnet_id,json=subnetId,proto3" json:"subnet_id,omitempty"`
|
||||
}
|
||||
|
||||
func (x *PlacementPolicy) Reset() {
|
||||
|
@ -529,13 +525,6 @@ func (x *PlacementPolicy) GetFilters() []*Filter {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (x *PlacementPolicy) GetSubnetId() *grpc.SubnetID {
|
||||
if x != nil {
|
||||
return x.SubnetId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// NeoFS node description
|
||||
type NodeInfo struct {
|
||||
state protoimpl.MessageState
|
||||
|
@ -827,14 +816,6 @@ func (x *NetworkInfo) GetNetworkConfig() *NetworkConfig {
|
|||
// attributes it's a string presenting floating point number with comma or
|
||||
// point delimiter for decimal part. In the Network Map it will be saved as
|
||||
// 64-bit unsigned integer representing number of minimal token fractions.
|
||||
// - [ __SYSTEM__SUBNET_%s ] \
|
||||
// (`__NEOFS__SUBNET_%s` is deprecated) \
|
||||
// `True` or `False`. Defines if the node is included in the `%s` subnetwork
|
||||
// or not. `%s` must be an existing subnetwork's ID (non-negative integer number).
|
||||
// A node can be included in more than one subnetwork and, therefore, can contain
|
||||
// more than one subnet attribute. A missing attribute is equivalent to the
|
||||
// presence of the attribute with `False` value (except default zero subnetwork
|
||||
// (with `%s` == 0) for which missing attribute means inclusion in that network).
|
||||
// - UN-LOCODE \
|
||||
// Node's geographic location in
|
||||
// [UN/LOCODE](https://www.unece.org/cefact/codesfortrade/codes_index.html)
|
||||
|
@ -956,13 +937,6 @@ func (x *NodeInfo_Attribute) GetParents() []string {
|
|||
// - **ContainerFee** \
|
||||
// Fee paid for container creation by the container owner.
|
||||
// Value: little-endian integer. Default: 0.
|
||||
// - **EigenTrustAlpha** \
|
||||
// Alpha parameter of EigenTrust algorithm used in the Reputation system.
|
||||
// Value: decimal floating-point number in UTF-8 string representation.
|
||||
// Default: 0.
|
||||
// - **EigenTrustIterations** \
|
||||
// Number of EigenTrust algorithm iterations to pass in the Reputation system.
|
||||
// Value: little-endian integer. Default: 0.
|
||||
// - **EpochDuration** \
|
||||
// NeoFS epoch duration measured in Sidechain blocks.
|
||||
// Value: little-endian integer. Default: 0.
|
||||
|
@ -1043,116 +1017,111 @@ var File_netmap_grpc_types_proto protoreflect.FileDescriptor
|
|||
var file_netmap_grpc_types_proto_rawDesc = []byte{
|
||||
0x0a, 0x17, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x74, 0x79,
|
||||
0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x10, 0x6e, 0x65, 0x6f, 0x2e, 0x66,
|
||||
0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x1a, 0x15, 0x72, 0x65, 0x66,
|
||||
0x73, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x22, 0xa5, 0x01, 0x0a, 0x06, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d,
|
||||
0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
||||
0x6b, 0x65, 0x79, 0x12, 0x2b, 0x0a, 0x02, 0x6f, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32,
|
||||
0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d,
|
||||
0x61, 0x70, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x02, 0x6f, 0x70,
|
||||
0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72,
|
||||
0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73,
|
||||
0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x46, 0x69, 0x6c, 0x74, 0x65,
|
||||
0x72, 0x52, 0x07, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73, 0x22, 0x9c, 0x01, 0x0a, 0x08, 0x53,
|
||||
0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63,
|
||||
0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e,
|
||||
0x74, 0x12, 0x30, 0x0a, 0x06, 0x63, 0x6c, 0x61, 0x75, 0x73, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x0e, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65,
|
||||
0x74, 0x6d, 0x61, 0x70, 0x2e, 0x43, 0x6c, 0x61, 0x75, 0x73, 0x65, 0x52, 0x06, 0x63, 0x6c, 0x61,
|
||||
0x75, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65,
|
||||
0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
|
||||
0x65, 0x12, 0x16, 0x0a, 0x06, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x06, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x22, 0x3b, 0x0a, 0x07, 0x52, 0x65, 0x70,
|
||||
0x6c, 0x69, 0x63, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x0d, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65,
|
||||
0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x65,
|
||||
0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x22, 0xa5, 0x02, 0x0a, 0x0f, 0x50, 0x6c, 0x61, 0x63, 0x65,
|
||||
0x6d, 0x65, 0x6e, 0x74, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x35, 0x0a, 0x08, 0x72, 0x65,
|
||||
0x70, 0x6c, 0x69, 0x63, 0x61, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e,
|
||||
0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e,
|
||||
0x52, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x52, 0x08, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61,
|
||||
0x73, 0x12, 0x36, 0x0a, 0x17, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x62,
|
||||
0x61, 0x63, 0x6b, 0x75, 0x70, 0x5f, 0x66, 0x61, 0x63, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x0d, 0x52, 0x15, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x42, 0x61, 0x63,
|
||||
0x6b, 0x75, 0x70, 0x46, 0x61, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x38, 0x0a, 0x09, 0x73, 0x65, 0x6c,
|
||||
0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e,
|
||||
0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e,
|
||||
0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x09, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74,
|
||||
0x6f, 0x72, 0x73, 0x12, 0x32, 0x0a, 0x07, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73, 0x18, 0x04,
|
||||
0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32,
|
||||
0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x07,
|
||||
0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73, 0x12, 0x35, 0x0a, 0x09, 0x73, 0x75, 0x62, 0x6e, 0x65,
|
||||
0x74, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f,
|
||||
0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x75, 0x62, 0x6e,
|
||||
0x65, 0x74, 0x49, 0x44, 0x52, 0x08, 0x73, 0x75, 0x62, 0x6e, 0x65, 0x74, 0x49, 0x64, 0x22, 0xd8,
|
||||
0x02, 0x0a, 0x08, 0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1d, 0x0a, 0x0a, 0x70,
|
||||
0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52,
|
||||
0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x64,
|
||||
0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x61,
|
||||
0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x12, 0x44, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x72,
|
||||
0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e,
|
||||
0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e,
|
||||
0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75,
|
||||
0x74, 0x65, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x36,
|
||||
0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x20, 0x2e,
|
||||
0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x22, 0xa5, 0x01, 0x0a, 0x06,
|
||||
0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65,
|
||||
0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2b, 0x0a, 0x02,
|
||||
0x6f, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66,
|
||||
0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4f, 0x70, 0x65, 0x72,
|
||||
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x02, 0x6f, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
|
||||
0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12,
|
||||
0x32, 0x0a, 0x07, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b,
|
||||
0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74,
|
||||
0x6d, 0x61, 0x70, 0x2e, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x07, 0x66, 0x69, 0x6c, 0x74,
|
||||
0x65, 0x72, 0x73, 0x22, 0x9c, 0x01, 0x0a, 0x08, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72,
|
||||
0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
|
||||
0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20,
|
||||
0x01, 0x28, 0x0d, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x30, 0x0a, 0x06, 0x63, 0x6c,
|
||||
0x61, 0x75, 0x73, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f,
|
||||
0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x43, 0x6c,
|
||||
0x61, 0x75, 0x73, 0x65, 0x52, 0x06, 0x63, 0x6c, 0x61, 0x75, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09,
|
||||
0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x09, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x66, 0x69,
|
||||
0x6c, 0x74, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x66, 0x69, 0x6c, 0x74,
|
||||
0x65, 0x72, 0x22, 0x3b, 0x0a, 0x07, 0x52, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x12, 0x14, 0x0a,
|
||||
0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x63, 0x6f,
|
||||
0x75, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x18,
|
||||
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x22,
|
||||
0xee, 0x01, 0x0a, 0x0f, 0x50, 0x6c, 0x61, 0x63, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x50, 0x6f, 0x6c,
|
||||
0x69, 0x63, 0x79, 0x12, 0x35, 0x0a, 0x08, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x73, 0x18,
|
||||
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76,
|
||||
0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x52, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61,
|
||||
0x52, 0x08, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x73, 0x12, 0x36, 0x0a, 0x17, 0x63, 0x6f,
|
||||
0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x62, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x5f, 0x66,
|
||||
0x61, 0x63, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x15, 0x63, 0x6f, 0x6e,
|
||||
0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x42, 0x61, 0x63, 0x6b, 0x75, 0x70, 0x46, 0x61, 0x63, 0x74,
|
||||
0x6f, 0x72, 0x12, 0x38, 0x0a, 0x09, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x18,
|
||||
0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76,
|
||||
0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f,
|
||||
0x72, 0x52, 0x09, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x12, 0x32, 0x0a, 0x07,
|
||||
0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e,
|
||||
0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70,
|
||||
0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52,
|
||||
0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x1a, 0x4d, 0x0a, 0x09, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62,
|
||||
0x75, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70,
|
||||
0x61, 0x72, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x70, 0x61,
|
||||
0x72, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x42, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x0f,
|
||||
0x0a, 0x0b, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12,
|
||||
0x0a, 0x0a, 0x06, 0x4f, 0x4e, 0x4c, 0x49, 0x4e, 0x45, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x4f,
|
||||
0x46, 0x46, 0x4c, 0x49, 0x4e, 0x45, 0x10, 0x02, 0x12, 0x0f, 0x0a, 0x0b, 0x4d, 0x41, 0x49, 0x4e,
|
||||
0x54, 0x45, 0x4e, 0x41, 0x4e, 0x43, 0x45, 0x10, 0x03, 0x22, 0x50, 0x0a, 0x06, 0x4e, 0x65, 0x74,
|
||||
0x6d, 0x61, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x30, 0x0a, 0x05, 0x6e, 0x6f, 0x64,
|
||||
0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66,
|
||||
0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4e, 0x6f, 0x64, 0x65,
|
||||
0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x22, 0x8f, 0x01, 0x0a, 0x0d,
|
||||
0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x49, 0x0a,
|
||||
0x0a, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28,
|
||||
0x0b, 0x32, 0x29, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65,
|
||||
0x2e, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x07, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x73,
|
||||
0x22, 0xd8, 0x02, 0x0a, 0x08, 0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1d, 0x0a,
|
||||
0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x0c, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1c, 0x0a, 0x09,
|
||||
0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52,
|
||||
0x09, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x12, 0x44, 0x0a, 0x0a, 0x61, 0x74,
|
||||
0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24,
|
||||
0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61,
|
||||
0x70, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69,
|
||||
0x62, 0x75, 0x74, 0x65, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73,
|
||||
0x12, 0x36, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32,
|
||||
0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d,
|
||||
0x61, 0x70, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x53, 0x74, 0x61, 0x74,
|
||||
0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x1a, 0x4d, 0x0a, 0x09, 0x41, 0x74, 0x74, 0x72,
|
||||
0x69, 0x62, 0x75, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x18, 0x0a,
|
||||
0x07, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07,
|
||||
0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x42, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65,
|
||||
0x12, 0x0f, 0x0a, 0x0b, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10,
|
||||
0x00, 0x12, 0x0a, 0x0a, 0x06, 0x4f, 0x4e, 0x4c, 0x49, 0x4e, 0x45, 0x10, 0x01, 0x12, 0x0b, 0x0a,
|
||||
0x07, 0x4f, 0x46, 0x46, 0x4c, 0x49, 0x4e, 0x45, 0x10, 0x02, 0x12, 0x0f, 0x0a, 0x0b, 0x4d, 0x41,
|
||||
0x49, 0x4e, 0x54, 0x45, 0x4e, 0x41, 0x4e, 0x43, 0x45, 0x10, 0x03, 0x22, 0x50, 0x0a, 0x06, 0x4e,
|
||||
0x65, 0x74, 0x6d, 0x61, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x30, 0x0a, 0x05, 0x6e,
|
||||
0x6f, 0x64, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f,
|
||||
0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4e, 0x6f,
|
||||
0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x05, 0x6e, 0x6f, 0x64, 0x65, 0x73, 0x22, 0x8f, 0x01,
|
||||
0x0a, 0x0d, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12,
|
||||
0x49, 0x0a, 0x0a, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20,
|
||||
0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e,
|
||||
0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f,
|
||||
0x6e, 0x66, 0x69, 0x67, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x52, 0x0a,
|
||||
0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x1a, 0x33, 0x0a, 0x09, 0x50, 0x61,
|
||||
0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c,
|
||||
0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22,
|
||||
0xbf, 0x01, 0x0a, 0x0b, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x12,
|
||||
0x23, 0x0a, 0x0d, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x45,
|
||||
0x70, 0x6f, 0x63, 0x68, 0x12, 0x21, 0x0a, 0x0c, 0x6d, 0x61, 0x67, 0x69, 0x63, 0x5f, 0x6e, 0x75,
|
||||
0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x6d, 0x61, 0x67, 0x69,
|
||||
0x63, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x20, 0x0a, 0x0c, 0x6d, 0x73, 0x5f, 0x70, 0x65,
|
||||
0x72, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x6d,
|
||||
0x73, 0x50, 0x65, 0x72, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x46, 0x0a, 0x0e, 0x6e, 0x65, 0x74,
|
||||
0x77, 0x6f, 0x72, 0x6b, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28,
|
||||
0x0b, 0x32, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65,
|
||||
0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66,
|
||||
0x69, 0x67, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x52, 0x0a, 0x70, 0x61,
|
||||
0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x1a, 0x33, 0x0a, 0x09, 0x50, 0x61, 0x72, 0x61,
|
||||
0x6d, 0x65, 0x74, 0x65, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x0c, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xbf, 0x01,
|
||||
0x0a, 0x0b, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x23, 0x0a,
|
||||
0x0d, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x45, 0x70, 0x6f,
|
||||
0x63, 0x68, 0x12, 0x21, 0x0a, 0x0c, 0x6d, 0x61, 0x67, 0x69, 0x63, 0x5f, 0x6e, 0x75, 0x6d, 0x62,
|
||||
0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x6d, 0x61, 0x67, 0x69, 0x63, 0x4e,
|
||||
0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x20, 0x0a, 0x0c, 0x6d, 0x73, 0x5f, 0x70, 0x65, 0x72, 0x5f,
|
||||
0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x6d, 0x73, 0x50,
|
||||
0x65, 0x72, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x46, 0x0a, 0x0e, 0x6e, 0x65, 0x74, 0x77, 0x6f,
|
||||
0x72, 0x6b, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d,
|
||||
0x61, 0x70, 0x2e, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
|
||||
0x52, 0x0d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2a,
|
||||
0x67, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x19, 0x0a, 0x15,
|
||||
0x4f, 0x50, 0x45, 0x52, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43,
|
||||
0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x06, 0x0a, 0x02, 0x45, 0x51, 0x10, 0x01, 0x12,
|
||||
0x06, 0x0a, 0x02, 0x4e, 0x45, 0x10, 0x02, 0x12, 0x06, 0x0a, 0x02, 0x47, 0x54, 0x10, 0x03, 0x12,
|
||||
0x06, 0x0a, 0x02, 0x47, 0x45, 0x10, 0x04, 0x12, 0x06, 0x0a, 0x02, 0x4c, 0x54, 0x10, 0x05, 0x12,
|
||||
0x06, 0x0a, 0x02, 0x4c, 0x45, 0x10, 0x06, 0x12, 0x06, 0x0a, 0x02, 0x4f, 0x52, 0x10, 0x07, 0x12,
|
||||
0x07, 0x0a, 0x03, 0x41, 0x4e, 0x44, 0x10, 0x08, 0x2a, 0x38, 0x0a, 0x06, 0x43, 0x6c, 0x61, 0x75,
|
||||
0x73, 0x65, 0x12, 0x16, 0x0a, 0x12, 0x43, 0x4c, 0x41, 0x55, 0x53, 0x45, 0x5f, 0x55, 0x4e, 0x53,
|
||||
0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x53, 0x41,
|
||||
0x4d, 0x45, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x49, 0x53, 0x54, 0x49, 0x4e, 0x43, 0x54,
|
||||
0x10, 0x02, 0x42, 0x61, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66,
|
||||
0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64,
|
||||
0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d,
|
||||
0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2f, 0x67, 0x72, 0x70,
|
||||
0x63, 0x3b, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0xaa, 0x02, 0x1a, 0x4e, 0x65, 0x6f, 0x2e, 0x46,
|
||||
0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x4e,
|
||||
0x65, 0x74, 0x6d, 0x61, 0x70, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x69, 0x67, 0x52, 0x0d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69,
|
||||
0x67, 0x2a, 0x67, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x19,
|
||||
0x0a, 0x15, 0x4f, 0x50, 0x45, 0x52, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50,
|
||||
0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x06, 0x0a, 0x02, 0x45, 0x51, 0x10,
|
||||
0x01, 0x12, 0x06, 0x0a, 0x02, 0x4e, 0x45, 0x10, 0x02, 0x12, 0x06, 0x0a, 0x02, 0x47, 0x54, 0x10,
|
||||
0x03, 0x12, 0x06, 0x0a, 0x02, 0x47, 0x45, 0x10, 0x04, 0x12, 0x06, 0x0a, 0x02, 0x4c, 0x54, 0x10,
|
||||
0x05, 0x12, 0x06, 0x0a, 0x02, 0x4c, 0x45, 0x10, 0x06, 0x12, 0x06, 0x0a, 0x02, 0x4f, 0x52, 0x10,
|
||||
0x07, 0x12, 0x07, 0x0a, 0x03, 0x41, 0x4e, 0x44, 0x10, 0x08, 0x2a, 0x38, 0x0a, 0x06, 0x43, 0x6c,
|
||||
0x61, 0x75, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x12, 0x43, 0x4c, 0x41, 0x55, 0x53, 0x45, 0x5f, 0x55,
|
||||
0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04,
|
||||
0x53, 0x41, 0x4d, 0x45, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x49, 0x53, 0x54, 0x49, 0x4e,
|
||||
0x43, 0x54, 0x10, 0x02, 0x42, 0x61, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73,
|
||||
0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f,
|
||||
0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70,
|
||||
0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2f, 0x67,
|
||||
0x72, 0x70, 0x63, 0x3b, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0xaa, 0x02, 0x1a, 0x4e, 0x65, 0x6f,
|
||||
0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49,
|
||||
0x2e, 0x4e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
@ -1183,7 +1152,6 @@ var file_netmap_grpc_types_proto_goTypes = []interface{}{
|
|||
(*NetworkInfo)(nil), // 10: neo.fs.v2.netmap.NetworkInfo
|
||||
(*NodeInfo_Attribute)(nil), // 11: neo.fs.v2.netmap.NodeInfo.Attribute
|
||||
(*NetworkConfig_Parameter)(nil), // 12: neo.fs.v2.netmap.NetworkConfig.Parameter
|
||||
(*grpc.SubnetID)(nil), // 13: neo.fs.v2.refs.SubnetID
|
||||
}
|
||||
var file_netmap_grpc_types_proto_depIdxs = []int32{
|
||||
0, // 0: neo.fs.v2.netmap.Filter.op:type_name -> neo.fs.v2.netmap.Operation
|
||||
|
@ -1192,17 +1160,16 @@ var file_netmap_grpc_types_proto_depIdxs = []int32{
|
|||
5, // 3: neo.fs.v2.netmap.PlacementPolicy.replicas:type_name -> neo.fs.v2.netmap.Replica
|
||||
4, // 4: neo.fs.v2.netmap.PlacementPolicy.selectors:type_name -> neo.fs.v2.netmap.Selector
|
||||
3, // 5: neo.fs.v2.netmap.PlacementPolicy.filters:type_name -> neo.fs.v2.netmap.Filter
|
||||
13, // 6: neo.fs.v2.netmap.PlacementPolicy.subnet_id:type_name -> neo.fs.v2.refs.SubnetID
|
||||
11, // 7: neo.fs.v2.netmap.NodeInfo.attributes:type_name -> neo.fs.v2.netmap.NodeInfo.Attribute
|
||||
2, // 8: neo.fs.v2.netmap.NodeInfo.state:type_name -> neo.fs.v2.netmap.NodeInfo.State
|
||||
7, // 9: neo.fs.v2.netmap.Netmap.nodes:type_name -> neo.fs.v2.netmap.NodeInfo
|
||||
12, // 10: neo.fs.v2.netmap.NetworkConfig.parameters:type_name -> neo.fs.v2.netmap.NetworkConfig.Parameter
|
||||
9, // 11: neo.fs.v2.netmap.NetworkInfo.network_config:type_name -> neo.fs.v2.netmap.NetworkConfig
|
||||
12, // [12:12] is the sub-list for method output_type
|
||||
12, // [12:12] is the sub-list for method input_type
|
||||
12, // [12:12] is the sub-list for extension type_name
|
||||
12, // [12:12] is the sub-list for extension extendee
|
||||
0, // [0:12] is the sub-list for field type_name
|
||||
11, // 6: neo.fs.v2.netmap.NodeInfo.attributes:type_name -> neo.fs.v2.netmap.NodeInfo.Attribute
|
||||
2, // 7: neo.fs.v2.netmap.NodeInfo.state:type_name -> neo.fs.v2.netmap.NodeInfo.State
|
||||
7, // 8: neo.fs.v2.netmap.Netmap.nodes:type_name -> neo.fs.v2.netmap.NodeInfo
|
||||
12, // 9: neo.fs.v2.netmap.NetworkConfig.parameters:type_name -> neo.fs.v2.netmap.NetworkConfig.Parameter
|
||||
9, // 10: neo.fs.v2.netmap.NetworkInfo.network_config:type_name -> neo.fs.v2.netmap.NetworkConfig
|
||||
11, // [11:11] is the sub-list for method output_type
|
||||
11, // [11:11] is the sub-list for method input_type
|
||||
11, // [11:11] is the sub-list for extension type_name
|
||||
11, // [11:11] is the sub-list for extension extendee
|
||||
0, // [0:11] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_netmap_grpc_types_proto_init() }
|
||||
|
|
|
@ -26,7 +26,6 @@ const (
|
|||
backupPolicyField = 2
|
||||
selectorsPolicyField = 3
|
||||
filtersPolicyField = 4
|
||||
subnetIDPolicyField = 5
|
||||
|
||||
keyAttributeField = 1
|
||||
valueAttributeField = 2
|
||||
|
@ -167,8 +166,6 @@ func (p *PlacementPolicy) StableMarshal(buf []byte) []byte {
|
|||
offset += protoutil.NestedStructureMarshal(filtersPolicyField, buf[offset:], &p.filters[i])
|
||||
}
|
||||
|
||||
protoutil.NestedStructureMarshal(subnetIDPolicyField, buf[offset:], p.subnetID)
|
||||
|
||||
return buf
|
||||
}
|
||||
|
||||
|
@ -187,8 +184,6 @@ func (p *PlacementPolicy) StableSize() (size int) {
|
|||
size += protoutil.NestedStructureSize(filtersPolicyField, &p.filters[i])
|
||||
}
|
||||
|
||||
size += protoutil.NestedStructureSize(subnetIDPolicyField, p.subnetID)
|
||||
|
||||
return size
|
||||
}
|
||||
|
||||
|
|
|
@ -102,7 +102,6 @@ func GeneratePlacementPolicy(empty bool) *netmap.PlacementPolicy {
|
|||
m.SetFilters(GenerateFilters(false))
|
||||
m.SetSelectors(GenerateSelectors(false))
|
||||
m.SetReplicas(GenerateReplicas(false))
|
||||
m.SetSubnetID(refstest.GenerateSubnetID(false))
|
||||
}
|
||||
|
||||
return m
|
||||
|
|
|
@ -59,7 +59,6 @@ type PlacementPolicy struct {
|
|||
backupFactor uint32
|
||||
selectors []Selector
|
||||
filters []Filter
|
||||
subnetID *refs.SubnetID
|
||||
}
|
||||
|
||||
// Attribute of storage node.
|
||||
|
@ -302,14 +301,6 @@ func (p *PlacementPolicy) SetReplicas(replicas []Replica) {
|
|||
p.replicas = replicas
|
||||
}
|
||||
|
||||
func (p *PlacementPolicy) GetSubnetID() *refs.SubnetID {
|
||||
return p.subnetID
|
||||
}
|
||||
|
||||
func (p *PlacementPolicy) SetSubnetID(id *refs.SubnetID) {
|
||||
p.subnetID = id
|
||||
}
|
||||
|
||||
func (a *Attribute) GetKey() string {
|
||||
if a != nil {
|
||||
return a.key
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue