public static String buildServiceId(ProviderConfig config, ServerConfig server) {
        return String.join("-", buildUniqueName(config, server.getProtocol()), getServerHost(server),
            String.valueOf(server.getPort()));
    }
Key can only contain A-Z a-z 0-9 _ and -.
@param key
@return
registry/registry-consul/src/main/java/com/alipay/sofa/rpc/registry/consul/ConsulUtils.java