forked from TrueCloudLab/xk6-frostfs
Added read status to obj
Signed-off-by: m.malygina <m.malygina@yadro.com>
This commit is contained in:
parent
034e319809
commit
0477552ee5
2 changed files with 2 additions and 2 deletions
|
@ -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)
|
||||
|
|
|
@ -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");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue