to instruct kitexcall calling etcd-lookup -host 127.0.0.1:2379 -key value EchoService who shall return a list of instances which can be used with client.WithHostPorts.
Another approach may be to send the arguments via stdin in JSON format, since "-key value" are more likely bound to golang, which is not convenient for tools in other languages.
To implement a mechanism (protocol) for invoking external command for service discovery.
For example, by introducing following arguments:
to instruct kitexcall calling
etcd-lookup -host 127.0.0.1:2379 -key value EchoService
who shall return a list of instances which can be used withclient.WithHostPorts
.