Class HttpResourceFetcher

  • All Implemented Interfaces:
    ResourceFetcher

    public class HttpResourceFetcher
    extends Object
    implements ResourceFetcher
    Fetch HTTP and HTTPS resources, with Auth options including BASIC and various OAuth2 permutations.
    • auth: auth type, one of AuthType. Otherwise None by default.
    Refer to AuthType for available options, such as BASIC, OAuth2, Keycloak, etc.
    Author:
    Marc Savy <marc@rhymewithgravy.com>
    See Also:
    AuthType
    • Constructor Detail

      • HttpResourceFetcher

        public HttpResourceFetcher​(io.vertx.core.Vertx vertx,
                                   URI uri,
                                   Map<String,​String> config,
                                   boolean isHttps)
    • Method Detail

      • fetch

        public void fetch​(io.vertx.core.Handler<io.vertx.core.buffer.Buffer> resultHandler)
        Description copied from interface: ResourceFetcher
        Fetch a resource and return its content via the resultHandler
        Specified by:
        fetch in interface ResourceFetcher
        Parameters:
        resultHandler - the result handler