From 6199e5af833ed194aa7a5808bd601473f3c54271 Mon Sep 17 00:00:00 2001 From: Dmitrii Stepanov Date: Mon, 23 Sep 2024 09:00:44 +0300 Subject: [PATCH] [#9999] lens: Drop unused Signed-off-by: Dmitrii Stepanov --- cmd/frostfs-lens/internal/schema/common/raw.go | 6 +++--- cmd/frostfs-lens/internal/schema/writecache/parsers.go | 4 +--- cmd/frostfs-lens/internal/schema/writecache/types.go | 1 - 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/cmd/frostfs-lens/internal/schema/common/raw.go b/cmd/frostfs-lens/internal/schema/common/raw.go index 0990e24c3..7e0a0a78f 100644 --- a/cmd/frostfs-lens/internal/schema/common/raw.go +++ b/cmd/frostfs-lens/internal/schema/common/raw.go @@ -7,13 +7,13 @@ import ( ) type RawEntry struct { - key, value []byte + key []byte } var RawParser Parser = rawParser -func rawParser(key, value []byte) (SchemaEntry, Parser, error) { - return &RawEntry{key: key, value: value}, rawParser, nil +func rawParser(key, _ []byte) (SchemaEntry, Parser, error) { + return &RawEntry{key: key}, rawParser, nil } func (r *RawEntry) String() string { diff --git a/cmd/frostfs-lens/internal/schema/writecache/parsers.go b/cmd/frostfs-lens/internal/schema/writecache/parsers.go index 7d70b27b2..fca1159e1 100644 --- a/cmd/frostfs-lens/internal/schema/writecache/parsers.go +++ b/cmd/frostfs-lens/internal/schema/writecache/parsers.go @@ -27,7 +27,7 @@ func DefaultBucketParser(key, value []byte) (common.SchemaEntry, common.Parser, return &DefaultBucket{}, DefaultRecordParser, nil } -func DefaultRecordParser(key, value []byte) (common.SchemaEntry, common.Parser, error) { +func DefaultRecordParser(key, _ []byte) (common.SchemaEntry, common.Parser, error) { parts := strings.Split(string(key), "/") if len(parts) != 2 { @@ -57,7 +57,5 @@ func DefaultRecordParser(key, value []byte) (common.SchemaEntry, common.Parser, r.addr.SetContainer(cnr) r.addr.SetObject(obj) - r.data = value[:] - return &r, nil, nil } diff --git a/cmd/frostfs-lens/internal/schema/writecache/types.go b/cmd/frostfs-lens/internal/schema/writecache/types.go index 3f71c5366..7d77d0854 100644 --- a/cmd/frostfs-lens/internal/schema/writecache/types.go +++ b/cmd/frostfs-lens/internal/schema/writecache/types.go @@ -16,7 +16,6 @@ type ( DefaultRecord struct { addr oid.Address - data []byte } )