@VisibleForTesting
    CompletableFuture<List<Node>> service(String serviceName, @Nullable String datacenter,
                                          @Nullable String filter) {
        requireNonNull(serviceName, "serviceName");
        final StringBuilder path = new StringBuilder("/catalog/service/");
        PercentEncoder.encodeComponent(path, serviceName);
        final QueryParams params = ConsulClientUtil.queryParams(datacenter, filter);
        if (!params.isEmpty()) {
            path.append('?').append(params.toQueryString());
        }
        return client.prepare()
                     .get(path.toString())
                     .asJson(collectionTypeForNode)
                     .as(HttpEntity::content)
                     .execute();
    }
Returns node list by service name.
consul/src/main/java/com/linecorp/armeria/internal/consul/CatalogClient.java