diff --git a/storagegroup/convert.go b/storagegroup/convert.go index b36101f..3dac399 100644 --- a/storagegroup/convert.go +++ b/storagegroup/convert.go @@ -15,6 +15,7 @@ func (s *StorageGroup) ToGRPCMessage() grpc.Message { m = new(sg.StorageGroup) m.SetMembers(refs.ObjectIDListToGRPCMessage(s.members)) + //nolint:staticcheck m.SetExpirationEpoch(s.exp) m.SetValidationDataSize(s.size) m.SetValidationHash(s.hash.ToGRPCMessage().(*refsGRPC.Checksum)) @@ -50,7 +51,7 @@ func (s *StorageGroup) FromGRPCMessage(m grpc.Message) error { return err } - //nolint: staticcheck + //nolint:staticcheck s.exp = v.GetExpirationEpoch() s.size = v.GetValidationDataSize() diff --git a/storagegroup/grpc/types.go b/storagegroup/grpc/types.go index 1c7a8a8..86280d3 100644 --- a/storagegroup/grpc/types.go +++ b/storagegroup/grpc/types.go @@ -15,6 +15,8 @@ func (m *StorageGroup) SetValidationHash(v *refs.Checksum) { } // SetExpirationEpoch sets number of the last epoch of the storage group lifetime. +// +// Deprecated: do not use, `expiration_epoch` field is deprecated in protocol. func (m *StorageGroup) SetExpirationEpoch(v uint64) { m.ExpirationEpoch = v } diff --git a/storagegroup/test/generate.go b/storagegroup/test/generate.go index 048ec24..80ba7b9 100644 --- a/storagegroup/test/generate.go +++ b/storagegroup/test/generate.go @@ -10,6 +10,7 @@ func GenerateStorageGroup(empty bool) *storagegroup.StorageGroup { if !empty { m.SetValidationDataSize(44) + //nolint:staticcheck m.SetExpirationEpoch(55) m.SetMembers(refstest.GenerateObjectIDs(false)) } diff --git a/storagegroup/types.go b/storagegroup/types.go index a1926c7..a03faf3 100644 --- a/storagegroup/types.go +++ b/storagegroup/types.go @@ -45,6 +45,8 @@ func (s *StorageGroup) SetValidationHash(v *refs.Checksum) { } // GetExpirationEpoch of unified storage group structure. +// +// Deprecated: Do not use. func (s *StorageGroup) GetExpirationEpoch() uint64 { if s != nil { return s.exp @@ -54,6 +56,8 @@ func (s *StorageGroup) GetExpirationEpoch() uint64 { } // SetExpirationEpoch into unified storage group structure. +// +// Deprecated: Do not use. func (s *StorageGroup) SetExpirationEpoch(v uint64) { s.exp = v }