From 0477552ee51c0016bcf72d901b1a6786a05a4bb1 Mon Sep 17 00:00:00 2001 From: "m.malygina" Date: Wed, 5 Jun 2024 17:29:27 +0300 Subject: [PATCH] Added read status to obj Signed-off-by: m.malygina --- internal/registry/obj_registry.go | 2 +- scenarios/s3longevity.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/registry/obj_registry.go b/internal/registry/obj_registry.go index f19d1c4..887ef89 100644 --- a/internal/registry/obj_registry.go +++ b/internal/registry/obj_registry.go @@ -83,7 +83,7 @@ func (o *ObjRegistry) SetObjectStatus(id uint64, oldStatus, newStatus string) er key := encodeId(id) objBytes := oldB.Get(key) if objBytes == nil { - return fmt.Errorf("object %w doesn't exist", key) + return fmt.Errorf("object %s doesn't exist", key) } if err := oldB.Delete(key); err != nil { return fmt.Errorf("bucket.Delete: %w", err) diff --git a/scenarios/s3longevity.js b/scenarios/s3longevity.js index 54f24af..4790110 100644 --- a/scenarios/s3longevity.js +++ b/scenarios/s3longevity.js @@ -188,7 +188,7 @@ export function obj_read() { log.withFields({bucket : obj.s3_bucket, key : obj.s3_key, status: obj.status, op: `READ`}) .error(resp.error); } else { - obj_registry.setObjectStatus(obj.id, obj.status, "read"); + //obj_registry.setObjectStatus(obj.id, obj.status, "read"); log.withFields({bucket : obj.s3_bucket, key : obj.s3_key}) .info("read successfully"); }