forked from TrueCloudLab/frostfs-node
[#243] cmd/cli: Write tombstone address in Object.Delete cmd
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
fe3906c295
commit
09916f21b5
3 changed files with 4 additions and 3 deletions
|
@ -248,7 +248,8 @@ func deleteObject(cmd *cobra.Command, _ []string) error {
|
|||
if err != nil {
|
||||
return err
|
||||
}
|
||||
err = cli.DeleteObject(ctx,
|
||||
|
||||
tombstoneAddr, err := client.DeleteObject(cli, ctx,
|
||||
new(client.DeleteObjectParams).WithAddress(objAddr),
|
||||
client.WithTTL(getTTL()),
|
||||
client.WithSession(tok),
|
||||
|
@ -258,7 +259,7 @@ func deleteObject(cmd *cobra.Command, _ []string) error {
|
|||
}
|
||||
|
||||
cmd.Println("Object removed successfully.")
|
||||
cmd.Printf(" ID: %s\n CID: %s\n", objAddr.ObjectID(), objAddr.ContainerID())
|
||||
cmd.Printf(" ID: %s\n CID: %s\n", tombstoneAddr.ObjectID(), tombstoneAddr.ContainerID())
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
2
go.mod
2
go.mod
|
@ -17,7 +17,7 @@ require (
|
|||
github.com/multiformats/go-multihash v0.0.13 // indirect
|
||||
github.com/nspcc-dev/hrw v1.0.9
|
||||
github.com/nspcc-dev/neo-go v0.91.1-pre.0.20201030072836-71216865717b
|
||||
github.com/nspcc-dev/neofs-api-go v1.20.3-0.20201210152623-803c91b3eb2b
|
||||
github.com/nspcc-dev/neofs-api-go v1.20.3-0.20201211081945-1bc91466aa7b
|
||||
github.com/nspcc-dev/neofs-crypto v0.3.0
|
||||
github.com/nspcc-dev/tzhash v1.4.0
|
||||
github.com/panjf2000/ants/v2 v2.3.0
|
||||
|
|
BIN
go.sum
BIN
go.sum
Binary file not shown.
Loading…
Reference in a new issue