[#1917] neofs-cli: Support timeout in control commands

Signed-off-by: Evgenii Stratonikov <evgeniy@morphbits.ru>
This commit is contained in:
Evgenii Stratonikov 2022-10-17 18:37:15 +03:00 committed by fyrchik
parent 4c63be6629
commit 0a1530afa0
13 changed files with 22 additions and 34 deletions

View file

@ -3,7 +3,6 @@ package control
import (
"github.com/nspcc-dev/neofs-api-go/v2/rpc/client"
"github.com/nspcc-dev/neofs-node/cmd/neofs-cli/internal/common"
"github.com/nspcc-dev/neofs-node/cmd/neofs-cli/internal/commonflags"
"github.com/nspcc-dev/neofs-node/cmd/neofs-cli/internal/key"
"github.com/nspcc-dev/neofs-node/pkg/services/control"
"github.com/spf13/cobra"
@ -40,10 +39,9 @@ func flushCache(cmd *cobra.Command, _ []string) {
}
func initControlFlushCacheCmd() {
commonflags.InitWithoutRPC(flushCacheCmd)
initControlFlags(flushCacheCmd)
ff := flushCacheCmd.Flags()
ff.String(controlRPC, controlRPCDefault, controlRPCUsage)
ff.StringSlice(shardIDFlag, nil, "List of shard IDs in base58 encoding")
ff.Bool(shardAllFlag, false, "Process all shards")