@Override
    public void fetch(Handler<Buffer> resultHandler) {
        int port = uri.getPort();
        if (port == -1) {
            if (isHttps) {
                port = 443;
            } else {
                port = 80;
            }
        }

        HttpClientRequest httpClientRequest = vertx.createHttpClient(new HttpClientOptions().setSsl(isHttps))
            .get(port, uri.getHost(), uri.getPath(), clientResponse -> {
                if (clientResponse.statusCode() / 100 == 2) {
                    clientResponse.handler(data -> {
                        rawData.appendBuffer(data);
                    })
                    .endHandler(end -> resultHandler.handle(rawData))
                    .exceptionHandler(exceptionHandler);
                } else {
                    exceptionHandler.handle(new BadResponseCodeError("Unexpected response code when trying to retrieve config: " //$NON-NLS-1$
                            + clientResponse.statusCode()));
                }
            })
            .exceptionHandler(exceptionHandler);

        authenticator.authenticate(vertx, config, httpClientRequest.headers(), authResult -> {
            if (authResult.succeeded()) {
                // The client request is executed when HttpClientRequest#end is invoked.
                httpClientRequest.end();
            } else {
                exceptionHandler.handle(authResult.cause());
            }
        });
    }
Fetch HTTP and HTTPS resources, with Auth options including BASIC and various OAuth2
permutations.

<ul>
  <li>auth: auth type, one of {@link AuthType}. Otherwise <tt>None</tt> by default.<li>
</ul>

Refer to {@link AuthType} for available options, such as BASIC, OAuth2, Keycloak, etc.

@see AuthType
@author Marc Savy {@literal <marc@rhymewithgravy.com>}
gateway/engine/vertx-polling/src/main/java/io/apiman/gateway/engine/vertx/polling/fetchers/HttpResourceFetcher.java