forked from TrueCloudLab/frostfs-node
[#2152] cli: Do not search for LOCK objects when delete container when session provided
Signed-off-by: Anton Nikiforov <an.nikiforov@yadro.com>
This commit is contained in:
parent
04b5ec759b
commit
33d279a3f2
2 changed files with 19 additions and 14 deletions
|
@ -66,6 +66,7 @@ Changelog for NeoFS Node
|
|||
- Force object removal via control service (#2145)
|
||||
- Synchronizing a tree now longer reports an error for a single-node container (#2154)
|
||||
- Prevent leaking goroutines in the tree service (#2162)
|
||||
- Do not search for LOCK objects when delete container when session provided (#2152)
|
||||
|
||||
### Removed
|
||||
- `-g` option from `neofs-cli control ...` and `neofs-cli container create` commands (#2089)
|
||||
|
|
|
@ -57,6 +57,9 @@ Only owner of the container has a permission to remove container.`,
|
|||
|
||||
common.PrintVerbose("Account matches the container owner.")
|
||||
|
||||
if tok != nil {
|
||||
common.PrintVerbose("Skip searching for LOCK objects - session provided.")
|
||||
} else {
|
||||
fs := objectSDK.NewSearchFilters()
|
||||
fs.AddTypeFilter(objectSDK.MatchStringEqual, objectSDK.TypeLock)
|
||||
|
||||
|
@ -77,6 +80,7 @@ Only owner of the container has a permission to remove container.`,
|
|||
"Use --%s flag to remove anyway.", commonflags.ForceFlag))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var delPrm internalclient.DeleteContainerPrm
|
||||
delPrm.SetClient(cli)
|
||||
|
|
Loading…
Reference in a new issue