From 66bc59da5c0227db0271ec2cd94be0523a88493b Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Mon, 21 Feb 2022 15:10:16 +0300 Subject: [PATCH] [#146] pool: Set private key in object HEAD/DELETE Use call private key parameterized in `HeadObject` / `DeleteObject` methods of `Pool` as corresponding key for `ObjectHead` / `ObjectDelete` methods of `Client`. Signed-off-by: Leonard Lyubich --- pool/pool.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pool/pool.go b/pool/pool.go index 6be6ce40..e0639f08 100644 --- a/pool/pool.go +++ b/pool/pool.go @@ -820,6 +820,8 @@ func (p *pool) DeleteObject(ctx context.Context, addr address.Address, opts ...C prm.ByID(*obj) } + prm.UseKey(*cc.key) + return p.callWithRetry(&cc, func() error { _, err := cc.client.ObjectDelete(ctx, prm) if err != nil { @@ -919,6 +921,8 @@ func (p *pool) HeadObject(ctx context.Context, addr address.Address, opts ...Cal prm.ByID(*obj) } + prm.UseKey(*cc.key) + var obj object.Object err = p.callWithRetry(&cc, func() error {