Class DefaultVertxHttpBinding

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void handleResponse​(VertxHttpEndpoint endpoint, org.apache.camel.Exchange exchange, io.vertx.core.AsyncResult<io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer>> response)
      Handles the HttpResponse returned from the HTTP endpoint invocation
      Throwable handleResponseFailure​(VertxHttpEndpoint endpoint, org.apache.camel.Exchange exchange, io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> result)
      Handles failures returned in the HttpResponse
      void populateRequestHeaders​(org.apache.camel.Exchange exchange, io.vertx.ext.web.client.HttpRequest<io.vertx.core.buffer.Buffer> request, org.apache.camel.spi.HeaderFilterStrategy strategy)
      Populates request headers on the HttpRequest using the supplied HeaderFilterStrategy
      void populateResponseHeaders​(org.apache.camel.Exchange exchange, io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> response, org.apache.camel.spi.HeaderFilterStrategy strategy)
      Populates response headers on the exchange from the HttpResponse using the supplied HeaderFilterStrategy
      io.vertx.ext.web.client.HttpRequest<io.vertx.core.buffer.Buffer> prepareHttpRequest​(VertxHttpEndpoint endpoint, org.apache.camel.Exchange exchange)
      Prepares a HttpRequest by setting up the required host, port & part details specified on the endpoint configuration
      Object processResponseBody​(VertxHttpEndpoint endpoint, org.apache.camel.Exchange exchange, io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> result)  
      Object processResponseBody​(VertxHttpEndpoint endpoint, org.apache.camel.Exchange exchange, io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> result, boolean exceptionOnly)
      Processes the received Buffer response body in the HttpResponse
    • Constructor Detail

      • DefaultVertxHttpBinding

        public DefaultVertxHttpBinding()
    • Method Detail

      • prepareHttpRequest

        public io.vertx.ext.web.client.HttpRequest<io.vertx.core.buffer.Buffer> prepareHttpRequest​(VertxHttpEndpoint endpoint,
                                                                                                   org.apache.camel.Exchange exchange)
                                                                                            throws Exception
        Description copied from interface: VertxHttpBinding
        Prepares a HttpRequest by setting up the required host, port & part details specified on the endpoint configuration
        Specified by:
        prepareHttpRequest in interface VertxHttpBinding
        Throws:
        Exception
      • populateRequestHeaders

        public void populateRequestHeaders​(org.apache.camel.Exchange exchange,
                                           io.vertx.ext.web.client.HttpRequest<io.vertx.core.buffer.Buffer> request,
                                           org.apache.camel.spi.HeaderFilterStrategy strategy)
        Description copied from interface: VertxHttpBinding
        Populates request headers on the HttpRequest using the supplied HeaderFilterStrategy
        Specified by:
        populateRequestHeaders in interface VertxHttpBinding
      • handleResponse

        public void handleResponse​(VertxHttpEndpoint endpoint,
                                   org.apache.camel.Exchange exchange,
                                   io.vertx.core.AsyncResult<io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer>> response)
                            throws Exception
        Description copied from interface: VertxHttpBinding
        Handles the HttpResponse returned from the HTTP endpoint invocation
        Specified by:
        handleResponse in interface VertxHttpBinding
        Throws:
        Exception
      • populateResponseHeaders

        public void populateResponseHeaders​(org.apache.camel.Exchange exchange,
                                            io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> response,
                                            org.apache.camel.spi.HeaderFilterStrategy strategy)
        Description copied from interface: VertxHttpBinding
        Populates response headers on the exchange from the HttpResponse using the supplied HeaderFilterStrategy
        Specified by:
        populateResponseHeaders in interface VertxHttpBinding
      • processResponseBody

        public Object processResponseBody​(VertxHttpEndpoint endpoint,
                                          org.apache.camel.Exchange exchange,
                                          io.vertx.ext.web.client.HttpResponse<io.vertx.core.buffer.Buffer> result)
                                   throws Exception
        Throws:
        Exception