diff --git a/netmap/grpc/types.pb.go b/netmap/grpc/types.pb.go index f1d5ef0..9c6c489 100644 Binary files a/netmap/grpc/types.pb.go and b/netmap/grpc/types.pb.go differ diff --git a/netmap/types.go b/netmap/types.go index 27fc2ff..aece7cf 100644 --- a/netmap/types.go +++ b/netmap/types.go @@ -55,6 +55,7 @@ type Replica struct { type Operation uint32 type PlacementPolicy struct { + unique bool replicas []Replica backupFactor uint32 selectors []Selector @@ -106,6 +107,7 @@ const ( LE OR AND + NOT ) const ( @@ -257,6 +259,17 @@ func (r *Replica) SetCount(count uint32) { r.count = count } +func (p *PlacementPolicy) GetUnique() bool { + if p != nil { + return p.unique + } + return false +} + +func (p *PlacementPolicy) SetUnique(unique bool) { + p.unique = unique +} + func (p *PlacementPolicy) GetFilters() []Filter { if p != nil { return p.filters