[#xxx] Upgrade NeoFS SDK Go with changed container sessions

After recent changes in NeoFS SDK Go library session tokens aren't
embedded into `container.Container` and `eacl.Table` structures.

Group value, session token and signature in a structure for container
and eACL.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
Leonard Lyubich 2022-06-22 13:55:31 +03:00 committed by fyrchik
parent 633b4e7d2d
commit b67974a8d3
26 changed files with 152 additions and 168 deletions

View file

@ -98,7 +98,6 @@ It will be stored in sidechain when inner ring will accepts it.`,
issuer := tok.Issuer()
cnr.SetOwnerID(&issuer)
cnr.SetSessionToken(tok)
} else {
var idOwner user.ID
user.IDFromKey(&idOwner, key.PublicKey)
@ -113,7 +112,6 @@ It will be stored in sidechain when inner ring will accepts it.`,
cnr.SetBasicACL(basicACL)
cnr.SetAttributes(attributes)
cnr.SetNonceUUID(nonce)
cnr.SetSessionToken(tok)
cli := internalclient.GetSDKClientByFlag(cmd, key, commonflags.RPC)
@ -121,6 +119,10 @@ It will be stored in sidechain when inner ring will accepts it.`,
putPrm.SetClient(cli)
putPrm.SetContainer(*cnr)
if tok != nil {
putPrm.WithinSession(*tok)
}
res, err := internalclient.PutContainer(putPrm)
common.ExitOnErr(cmd, "rpc error: %w", err)