Class HttpSendDynamicAware

  • All Implemented Interfaces:
    org.apache.camel.spi.SendDynamicAware

    public class HttpSendDynamicAware
    extends Object
    implements org.apache.camel.spi.SendDynamicAware
    HTTP based SendDynamicAware which allows to optimise HTTP components with the toD (dynamic to) DSL in Camel. This implementation optimises by allowing to provide dynamic parameters via Exchange.HTTP_PATH and Exchange.HTTP_QUERY headers instead of the endpoint uri. That allows to use a static endpoint and its producer to service dynamic requests.
    • Constructor Detail

      • HttpSendDynamicAware

        public HttpSendDynamicAware()
    • Method Detail

      • setScheme

        public void setScheme​(String scheme)
        Specified by:
        setScheme in interface org.apache.camel.spi.SendDynamicAware
      • getScheme

        public String getScheme()
        Specified by:
        getScheme in interface org.apache.camel.spi.SendDynamicAware
      • prepare

        public org.apache.camel.spi.SendDynamicAware.DynamicAwareEntry prepare​(org.apache.camel.Exchange exchange,
                                                                               String uri,
                                                                               String originalUri)
                                                                        throws Exception
        Specified by:
        prepare in interface org.apache.camel.spi.SendDynamicAware
        Throws:
        Exception
      • resolveStaticUri

        public String resolveStaticUri​(org.apache.camel.Exchange exchange,
                                       org.apache.camel.spi.SendDynamicAware.DynamicAwareEntry entry)
                                throws Exception
        Specified by:
        resolveStaticUri in interface org.apache.camel.spi.SendDynamicAware
        Throws:
        Exception
      • createPreProcessor

        public org.apache.camel.Processor createPreProcessor​(org.apache.camel.Exchange exchange,
                                                             org.apache.camel.spi.SendDynamicAware.DynamicAwareEntry entry)
                                                      throws Exception
        Specified by:
        createPreProcessor in interface org.apache.camel.spi.SendDynamicAware
        Throws:
        Exception
      • createPostProcessor

        public org.apache.camel.Processor createPostProcessor​(org.apache.camel.Exchange exchange,
                                                              org.apache.camel.spi.SendDynamicAware.DynamicAwareEntry entry)
                                                       throws Exception
        Specified by:
        createPostProcessor in interface org.apache.camel.spi.SendDynamicAware
        Throws:
        Exception
      • parseUri

        public String[] parseUri​(org.apache.camel.spi.SendDynamicAware.DynamicAwareEntry entry)