如何解决Cacence CLI 无法注册新域:BadRequestError{消息:集群名称无效:}
我正在尝试按照 cadence
的文档注册一个新域。
当我尝试 domain describe 命令时,它按预期工作:
docker run --rm ubercadence/cli:master --address host.docker.internal:7933 --domain samples-domain domain describe
Error: Domain samples-domain does not exist.
Error Details: EntityNotExistsError{Message: Domain samples-domain does not exist.}
('export CADENCE_CLI_SHOW_STACKS=1' to see stack traces)
当我运行域注册命令时,它给出了这个错误
docker run --rm ubercadence/cli:master --address host.docker.internal:7933 --domain samples-domain domain register
Error: Register Domain operation failed.
Error Details: BadRequestError{Message: Invalid cluster name: }
('export CADENCE_CLI_SHOW_STACKS=1' to see stack traces)
我也用 --gd false
选项尝试了相同的命令,结果仍然相同。
这是堆栈跟踪输出:
Stack trace:
goroutine 1 [running]:
runtime/debug.Stack(0xd,0x0,0x0)
/usr/local/go/src/runtime/debug/stack.go:24 +0x9d
runtime/debug.PrintStack()
/usr/local/go/src/runtime/debug/stack.go:16 +0x22
github.com/uber/cadence/tools/cli.printError(0x206594b,0x21,0x2559ce0,0xc000496020)
/cadence/tools/cli/util.go:536 +0x2ad
github.com/uber/cadence/tools/cli.ErrorAndExit(0x206594b,0xc000496020)
/cadence/tools/cli/util.go:547 +0x49
github.com/uber/cadence/tools/cli.(*domainCLIImpl).RegisterDomain(0xc000415600,0xc0000dcf20)
/cadence/tools/cli/domainCommands.go:150 +0x8cd
github.com/uber/cadence/tools/cli.newDomainCommands.func1(0xc0000dcf20)
/cadence/tools/cli/domain.go:73 +0x48
github.com/urfave/cli.HandleAction(0x1c20dc0,0x20ed500,0xc0000dcf20,0x0)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/app.go:528 +0x127
github.com/urfave/cli.Command.Run(0x2030e21,0x8,0xc0002da9a0,0x1,0x204f0c0,0x18,...)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/command.go:174 +0x528
github.com/urfave/cli.(*App).RunAsSubcommand(0xc00034b340,0xc0000dcc60,0x0)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/app.go:407 +0x882
github.com/urfave/cli.Command.startApp(0x202d311,0x6,0xc0002dae90,0x204a264,0x16,...)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/command.go:373 +0x845
github.com/urfave/cli.Command.Run(0x202d311,...)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/command.go:102 +0x9d6
github.com/urfave/cli.(*App).Run(0xc00034b180,0xc00003a070,0x7,0x0)
/go/pkg/mod/github.com/urfave/cli@v1.22.4/app.go:279 +0x731
main.main()
/cadence/cmd/tools/cli/main.go:36 +0x4f
我不确定到底出了什么问题。
解决方法
以下命令对我有用:
docker run --rm ubercadence/cli:master --address host.docker.internal:7933 --domain samples-domain domain register --active_cluster active
看起来有一个错误,希望它会在未来的版本中得到解决。 https://github.com/uber/cadence/issues/4054
,在 v0.18.2 中已修复:https://github.com/uber/cadence/releases/tag/v0.18.2
我在本地测试过:
$./cadence --do test123 d re
Domain test123 successfully registered.
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。