--- apiVersion: v1 kind: List items: - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-ahc version: 1.1.24 group: io.fabric8.funktion.connector name: ahc data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc spec: containers: - image: fabric8/connector-ahc:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: ahc syntax: ahc:httpUri title: AHC description: To call external HTTP services using Async Http Client. label: http deprecated: false async: true producerOnly: true lenientProperties: true javaType: org.apache.camel.component.ahc.AhcComponent groupId: org.apache.camel artifactId: camel-ahc version: 2.18.1 componentProperties: client: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClient deprecated: false secret: false description: To use a custom AsyncHttpClient binding: kind: property type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. clientConfig: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. sslContextParameters: kind: property type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. allowJavaSerializedObject: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. headerFilterStrategy: kind: property type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. properties: httpUri: kind: path group: producer required: true type: string javaType: java.net.URI deprecated: false secret: false description: The URI to use such as http://hostname:port/path binding: kind: parameter group: producer type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. bridgeEndpoint: kind: parameter group: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. bufferSize: kind: parameter group: producer type: integer javaType: int deprecated: false secret: false defaultValue: "4096" description: The initial in-memory buffer size used when transferring data between Camel and AHC Client. connectionClose: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default headerFilterStrategy: kind: parameter group: producer type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. throwExceptionOnFailure: kind: parameter group: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. transferException: kind: parameter group: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. clientConfig: kind: parameter group: advanced label: advanced type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. clientConfigOptions: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: asyncHttpClientConfig. multiValue: true deprecated: false secret: false description: To configure the AsyncHttpClientConfig using the key/values from the Map. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). sslContextParameters: kind: parameter group: security label: security type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. documentation.adoc: |+ [[AHC-AsyncHttpClientComponent]] Async Http Client Component ~~~~~~~~~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.8* The *ahc:* component provides HTTP based link:endpoint.html[endpoints] for consuming external HTTP resources (as a client to call external servers using HTTP). + The component uses the https://github.com/AsyncHttpClient/async-http-client[Async Http Client] library. Maven users will need to add the following dependency to their `pom.xml` for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-ahc x.x.x ------------------------------------------------------------ [[AHC-URIformat]] URI format ^^^^^^^^^^ [source,java] --------------------------------------------------- ahc:http://hostname[:port][/resourceUri][?options] ahc:https://hostname[:port][/resourceUri][?options] --------------------------------------------------- Will by default use port 80 for HTTP and 443 for HTTPS. You can append query options to the URI in the following format, `?option=value&option=value&...` [[AHC-AhcEndpointOptions]] AhcEndpoint Options ^^^^^^^^^^^^^^^^^^^ // endpoint options: START The AHC component supports 12 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | httpUri | producer | | URI | *Required* The URI to use such as http://hostname:port/path | binding | producer | | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | bridgeEndpoint | producer | false | boolean | If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. | bufferSize | producer | 4096 | int | The initial in-memory buffer size used when transferring data between Camel and AHC Client. | connectionClose | producer | false | boolean | Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default | headerFilterStrategy | producer | | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. | throwExceptionOnFailure | producer | true | boolean | Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. | transferException | producer | false | boolean | If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | clientConfig | advanced | | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | clientConfigOptions | advanced | | Map | To configure the AsyncHttpClientConfig using the key/values from the Map. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | sslContextParameters | security | | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. |======================================================================= {% endraw %} // endpoint options: END [[AHC-AhcComponentOptions]] AhcComponent Options ^^^^^^^^^^^^^^^^^^^^ // component options: START The AHC component supports 6 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | client | AsyncHttpClient | To use a custom AsyncHttpClient | binding | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | clientConfig | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | sslContextParameters | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. | allowJavaSerializedObject | boolean | Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | headerFilterStrategy | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. |======================================================================= {% endraw %} // component options: END Notice that setting any of the options on the `AhcComponent` will propagate those options to `AhcEndpoints` being created. However the `AhcEndpoint` can also configure/override a custom option. Options set on endpoints will always take precedence over options from the `AhcComponent`. [[AHC-MessageHeaders]] Message Headers ^^^^^^^^^^^^^^^ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Name |Type |Description |`Exchange.HTTP_URI` |`String` |URI to call. Will override existing URI set directly on the endpoint. |`Exchange.HTTP_PATH` |`String` |Request URI's path, the header will be used to build the request URI with the HTTP_URI. If the path is start with "/", http producer will try to find the relative path based on the Exchange.HTTP_BASE_URI header or the `exchange.getFromEndpoint().getEndpointUri();` |`Exchange.HTTP_QUERY` |`String` |*Camel 2.11 onwards:* URI parameters. Will override existing URI parameters set directly on the endpoint. |`Exchange.HTTP_RESPONSE_CODE` |`int` |The HTTP response code from the external server. Is 200 for OK. |`Exchange.HTTP_CHARACTER_ENCODING` |`String` |Character encoding. |`Exchange.CONTENT_TYPE` |`String` |The HTTP content type. Is set on both the IN and OUT message to provide a content type, such as `text/html`. |`Exchange.CONTENT_ENCODING` |`String` |The HTTP content encoding. Is set on both the IN and OUT message to provide a content encoding, such as `gzip`. |======================================================================= [[AHC-MessageBody]] Message Body ^^^^^^^^^^^^ Camel will store the HTTP response from the external server on the OUT body. All headers from the IN message will be copied to the OUT message, so headers are preserved during routing. Additionally Camel will add the HTTP response headers as well to the OUT message headers. [[AHC-Responsecode]] Response code ^^^^^^^^^^^^^ Camel will handle according to the HTTP response code: * Response code is in the range 100..299, Camel regards it as a success response. * Response code is in the range 300..399, Camel regards it as a redirection response and will throw a `AhcOperationFailedException` with the information. * Response code is 400+, Camel regards it as an external server failure and will throw a `AhcOperationFailedException` with the information. + throwExceptionOnFailure + The option, `throwExceptionOnFailure`, can be set to `false` to prevent the `AhcOperationFailedException` from being thrown for failed response codes. This allows you to get any response from the remote server. [[AHC-AhcOperationFailedException]] AhcOperationFailedException ^^^^^^^^^^^^^^^^^^^^^^^^^^^ This exception contains the following information: * The HTTP status code * The HTTP status line (text of the status code) * Redirect location, if server returned a redirect * Response body as a `java.lang.String`, if server provided a body as response [[AHC-CallingusingGETorPOST]] Calling using GET or POST ^^^^^^^^^^^^^^^^^^^^^^^^^ The following algorithm is used to determine if either `GET` or `POST` HTTP method should be used: + 1. Use method provided in header. + 2. `GET` if query string is provided in header. + 3. `GET` if endpoint is configured with a query string. + 4. `POST` if there is data to send (body is not null). + 5. `GET` otherwise. [[AHC-ConfiguringURItocall]] Configuring URI to call ^^^^^^^^^^^^^^^^^^^^^^^ You can set the HTTP producer's URI directly form the endpoint URI. In the route below, Camel will call out to the external server, `oldhost`, using HTTP. [source,java] ---------------------------------- from("direct:start") .to("ahc:http://oldhost"); ---------------------------------- And the equivalent Spring sample: [source,xml] --------------------------------------------------------------------- --------------------------------------------------------------------- You can override the HTTP endpoint URI by adding a header with the key, `Exchange.HTTP_URI`, on the message. [source,java] ------------------------------------------------------------- from("direct:start") .setHeader(Exchange.HTTP_URI, constant("http://newhost")) .to("ahc:http://oldhost"); ------------------------------------------------------------- [[AHC-ConfiguringURIParameters]] Configuring URI Parameters ^^^^^^^^^^^^^^^^^^^^^^^^^^ The *ahc* producer supports URI parameters to be sent to the HTTP server. The URI parameters can either be set directly on the endpoint URI or as a header with the key `Exchange.HTTP_QUERY` on the message. [source,java] --------------------------------------------------------- from("direct:start") .to("ahc:http://oldhost?order=123&detail=short"); --------------------------------------------------------- Or options provided in a header: [source,java] ------------------------------------------------------------------------------- from("direct:start") .setHeader(Exchange.HTTP_QUERY, constant("order=123&detail=short")) .to("ahc:http://oldhost"); ------------------------------------------------------------------------------- [[AHC-HowtosetthehttpmethodtotheHTTPproducer]] How to set the http method to the HTTP producer ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ The HTTP component provides a way to set the HTTP request method by setting the message header. Here is an example; [source,java] -------------------------------------------------------------- from("direct:start") .setHeader(Exchange.HTTP_METHOD, constant("POST")) .to("ahc:http://www.google.com") .to("mock:results"); -------------------------------------------------------------- And the equivalent Spring sample: [source,xml] --------------------------------------------------------------------- POST --------------------------------------------------------------------- [[AHC-Configuringcharset]] Configuring charset ^^^^^^^^^^^^^^^^^^^ If you are using `POST` to send data you can configure the `charset` using the `Exchange` property: [source,java] ---------------------------------------------------------- exchange.setProperty(Exchange.CHARSET_NAME, "iso-8859-1"); ---------------------------------------------------------- [[AHC-URIParametersfromtheendpointURI]] URI Parameters from the endpoint URI ++++++++++++++++++++++++++++++++++++ In this sample we have the complete URI endpoint that is just what you would have typed in a web browser. Multiple URI parameters can of course be set using the `&` character as separator, just as you would in the web browser. Camel does no tricks here. [source,java] -------------------------------------------------------------------- // we query for Camel at the Google page template.sendBody("ahc:http://www.google.com/search?q=Camel", null); -------------------------------------------------------------------- [[AHC-URIParametersfromtheMessage]] URI Parameters from the Message +++++++++++++++++++++++++++++++ [source,java] --------------------------------------------------------------------- Map headers = new HashMap(); headers.put(Exchange.HTTP_QUERY, "q=Camel&lr=lang_en"); // we query for Camel and English language at Google template.sendBody("ahc:http://www.google.com/search", null, headers); --------------------------------------------------------------------- In the header value above notice that it should *not* be prefixed with `?` and you can separate parameters as usual with the `&` char. [[AHC-GettingtheResponseCode]] Getting the Response Code +++++++++++++++++++++++++ You can get the HTTP response code from the AHC component by getting the value from the Out message header with `Exchange.HTTP_RESPONSE_CODE`. [source,java] ---------------------------------------------------------------------------------------------- Exchange exchange = template.send("ahc:http://www.google.com/search", new Processor() { public void process(Exchange exchange) throws Exception { exchange.getIn().setHeader(Exchange.HTTP_QUERY, constant("hl=en&q=activemq")); } }); Message out = exchange.getOut(); int responseCode = out.getHeader(Exchange.HTTP_RESPONSE_CODE, Integer.class); ---------------------------------------------------------------------------------------------- [[AHC-ConfiguringAsyncHttpClient]] Configuring AsyncHttpClient ^^^^^^^^^^^^^^^^^^^^^^^^^^^ The `AsyncHttpClient` client uses a `AsyncHttpClientConfig` to configure the client. See the documentation at + http://github.com/sonatype/async-http-client[Async Http Client] for more details. In Camel *2.8*, configuration is limited to using the builder pattern provided by `AsyncHttpClientConfig.Builder`. In Camel 2.8, the `AsyncHttpClientConfig` doesn't support getters/setters so its not easy to create/configure using a Spring bean style (eg the tag in the XML file). The example below shows how to use a builder to create the `AsyncHttpClientConfig` which we configure on the `AhcComponent`. In Camel *2.9*, the AHC component uses Async HTTP library 1.6.4. This newer version provides added support for plain bean style configuration. The `AsyncHttpClientConfigBean` class provides getters and setters for the configuration options available in `AsyncHttpClientConfig`. An instance of `AsyncHttpClientConfigBean` may be passed directly to the AHC component or referenced in an endpoint URI using the `clientConfig` URI parameter. Also available in Camel *2.9* is the ability to set configuration options directly in the URI. URI parameters starting with "clientConfig." can be used to set the various configurable properties of `AsyncHttpClientConfig`. The properties specified in the endpoint URI are merged with those specified in the configuration referenced by the "clientConfig" URI parameter with those being set using the "clientConfig." parameter taking priority. The `AsyncHttpClientConfig` instance referenced is always copied for each endpoint such that settings on one endpoint will remain independent of settings on any previously created endpoints. The example below shows how to configure the AHC component using the "clientConfig." type URI parameters. [source,java] --------------------------------------------------------------------------------------------------------- from("direct:start") .to("ahc:http://localhost:8080/foo?clientConfig.maxRequestRetry=3&clientConfig.followRedirects=true") --------------------------------------------------------------------------------------------------------- [[AHC-SSLSupport]] SSL Support (HTTPS) ^^^^^^^^^^^^^^^^^^^ [[AHC-UsingtheJSSEConfigurationUtility]] Using the JSSE Configuration Utility As of Camel 2.9, the AHC component supports SSL/TLS configuration through the link:camel-configuration-utilities.html[Camel JSSE Configuration Utility].?? This utility greatly decreases the amount of component specific code you need to write and is configurable at the endpoint and component levels.?? The following examples demonstrate how to use the utility with the AHC component. [[AHC-Programmaticconfigurationofthecomponent]] Programmatic configuration of the component [source,java] ------------------------------------------------------------------------- KeyStoreParameters ksp = new KeyStoreParameters(); ksp.setResource("/users/home/server/keystore.jks"); ksp.setPassword("keystorePassword"); KeyManagersParameters kmp = new KeyManagersParameters(); kmp.setKeyStore(ksp); kmp.setKeyPassword("keyPassword"); SSLContextParameters scp = new SSLContextParameters(); scp.setKeyManagers(kmp); AhcComponent component = context.getComponent("ahc", AhcComponent.class); component.setSslContextParameters(scp)); ------------------------------------------------------------------------- [[AHC-SpringDSLbasedconfigurationofendpoint]] Spring DSL based configuration of endpoint [source,xml] ---------------------------------------------------------------------------------- ... ... ... ... ---------------------------------------------------------------------------------- [[AHC-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:jetty.html[Jetty] * link:http.html[HTTP] * link:http4.html[HTTP4] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-ahc-ws version: 1.1.24 group: io.fabric8.funktion.connector name: ahc-ws data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc-ws spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc-ws spec: containers: - image: fabric8/connector-ahc-ws:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: ahc-ws extendsScheme: ahc alternativeSchemes: ahc-ws,ahc-wss syntax: ahc-ws:httpUri title: AHC Websocket description: To exchange data with external Websocket servers using Async Http Client. label: websocket deprecated: false async: true javaType: org.apache.camel.component.ahc.ws.WsComponent groupId: org.apache.camel artifactId: camel-ahc-ws version: 2.18.1 componentProperties: client: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClient deprecated: false secret: false description: To use a custom AsyncHttpClient binding: kind: property type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. clientConfig: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. sslContextParameters: kind: property type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. allowJavaSerializedObject: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. headerFilterStrategy: kind: property type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. properties: httpUri: kind: path group: common required: true type: string javaType: java.net.URI deprecated: false secret: false description: The URI to use such as http://hostname:port/path binding: kind: parameter group: common type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. bridgeEndpoint: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. bufferSize: kind: parameter group: common type: integer javaType: int deprecated: false secret: false defaultValue: "4096" description: The initial in-memory buffer size used when transferring data between Camel and AHC Client. headerFilterStrategy: kind: parameter group: common type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. throwExceptionOnFailure: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. transferException: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. sendMessageOnError: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to send an message if the web-socket listener received an error. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. connectionClose: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default useStreaming: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: To enable streaming to send data as multiple text fragments. clientConfig: kind: parameter group: advanced label: advanced type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. clientConfigOptions: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: asyncHttpClientConfig. multiValue: true deprecated: false secret: false description: To configure the AsyncHttpClientConfig using the key/values from the Map. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). sslContextParameters: kind: parameter group: security label: security type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. documentation.adoc: |+ [[AHC-WS-AsyncHttpClientWebsocketClientComponent]] Async Http Client (AHC) Websocket Client Component ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.14* The??*ahc-ws*??component provides Websocket based??link:endpoint.html[endpoints]??for a client communicating with external servers over Websocket (as a client opening a websocket connection to an external server). + The component uses the link:ahc.html[AHC] component that in turn uses the??https://github.com/AsyncHttpClient/async-http-client[Async Http Client]??library. Maven users will need to add the following dependency to their??`pom.xml`??for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-ahc-ws x.x.x ------------------------------------------------------------ [[AHC-WS-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------------------------------- ahc-ws://hostname[:port][/resourceUri][?options] ahc-wss://hostname[:port][/resourceUri][?options] ------------------------------------------------- Will by default use port 80 for ahc-ws and 443 for ahc-wss. [[AHC-WS-AHC-WSOptions]] AHC-WS Options ^^^^^^^^^^^^^^ As the AHC-WS component is based on the AHC component, you can use the various configuration options of the AHC component. // component options: START The AHC Websocket component supports 6 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | client | AsyncHttpClient | To use a custom AsyncHttpClient | binding | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | clientConfig | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | sslContextParameters | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. | allowJavaSerializedObject | boolean | Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | headerFilterStrategy | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. |======================================================================= {% endraw %} // component options: END // endpoint options: START The AHC Websocket component supports 17 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | httpUri | common | | URI | *Required* The URI to use such as http://hostname:port/path | binding | common | | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | bridgeEndpoint | common | false | boolean | If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. | bufferSize | common | 4096 | int | The initial in-memory buffer size used when transferring data between Camel and AHC Client. | headerFilterStrategy | common | | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. | throwExceptionOnFailure | common | true | boolean | Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. | transferException | common | false | boolean | If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | sendMessageOnError | consumer | false | boolean | Whether to send an message if the web-socket listener received an error. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | connectionClose | producer | false | boolean | Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default | useStreaming | producer | false | boolean | To enable streaming to send data as multiple text fragments. | clientConfig | advanced | | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | clientConfigOptions | advanced | | Map | To configure the AsyncHttpClientConfig using the key/values from the Map. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | sslContextParameters | security | | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. |======================================================================= {% endraw %} // endpoint options: END [[AHC-WS-WritingandReadingDataoverWebsocket]] Writing and Reading Data over Websocket ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ An ahc-ws endpoint can either write data to the socket or read from the socket, depending on whether the endpoint is configured as the producer or the consumer, respectively. [[AHC-WS-ConfiguringURItoWriteorReadData]] Configuring URI to Write or Read Data ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ In the route below, Camel will write to the specified websocket connection. [source,java] ----------------------------------- from("direct:start") .to("ahc-ws://targethost"); ----------------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ In the route below, Camel will read from the specified websocket connection. [source,java] --------------------------- from("ahc-ws://targethost") .to("direct:next"); --------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ ?? [[AHC-WS-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:../../../../camel-ahc/src/main/docs/readme.html[AHC] * link:atmosphere-websocket.html[Atmosphere-Websocket] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-ahc-wss version: 1.1.24 group: io.fabric8.funktion.connector name: ahc-wss data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc-wss spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: ahc-wss spec: containers: - image: fabric8/connector-ahc-wss:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: ahc-wss extendsScheme: ahc alternativeSchemes: ahc-ws,ahc-wss syntax: ahc-wss:httpUri title: AHC Secure Websocket description: To exchange data with external Websocket servers using Async Http Client. label: websocket deprecated: false async: true javaType: org.apache.camel.component.ahc.ws.WsComponent groupId: org.apache.camel artifactId: camel-ahc-ws version: 2.18.1 componentProperties: client: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClient deprecated: false secret: false description: To use a custom AsyncHttpClient binding: kind: property type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. clientConfig: kind: property type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. sslContextParameters: kind: property type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. allowJavaSerializedObject: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. headerFilterStrategy: kind: property type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. properties: httpUri: kind: path group: common required: true type: string javaType: java.net.URI deprecated: false secret: false description: The URI to use such as http://hostname:port/path binding: kind: parameter group: common type: object javaType: org.apache.camel.component.ahc.AhcBinding deprecated: false secret: false description: To use a custom AhcBinding which allows to control how to bind between AHC and Camel. bridgeEndpoint: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. bufferSize: kind: parameter group: common type: integer javaType: int deprecated: false secret: false defaultValue: "4096" description: The initial in-memory buffer size used when transferring data between Camel and AHC Client. headerFilterStrategy: kind: parameter group: common type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. throwExceptionOnFailure: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. transferException: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. sendMessageOnError: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to send an message if the web-socket listener received an error. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. connectionClose: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default useStreaming: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: To enable streaming to send data as multiple text fragments. clientConfig: kind: parameter group: advanced label: advanced type: object javaType: org.asynchttpclient.AsyncHttpClientConfig deprecated: false secret: false description: To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. clientConfigOptions: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: asyncHttpClientConfig. multiValue: true deprecated: false secret: false description: To configure the AsyncHttpClientConfig using the key/values from the Map. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). sslContextParameters: kind: parameter group: security label: security type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. documentation.adoc: |+ [[AHC-WS-AsyncHttpClientWebsocketClientComponent]] Async Http Client (AHC) Websocket Client Component ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.14* The??*ahc-ws*??component provides Websocket based??link:endpoint.html[endpoints]??for a client communicating with external servers over Websocket (as a client opening a websocket connection to an external server). + The component uses the link:ahc.html[AHC] component that in turn uses the??https://github.com/AsyncHttpClient/async-http-client[Async Http Client]??library. Maven users will need to add the following dependency to their??`pom.xml`??for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-ahc-ws x.x.x ------------------------------------------------------------ [[AHC-WS-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------------------------------- ahc-ws://hostname[:port][/resourceUri][?options] ahc-wss://hostname[:port][/resourceUri][?options] ------------------------------------------------- Will by default use port 80 for ahc-ws and 443 for ahc-wss. [[AHC-WS-AHC-WSOptions]] AHC-WS Options ^^^^^^^^^^^^^^ As the AHC-WS component is based on the AHC component, you can use the various configuration options of the AHC component. // component options: START The AHC Websocket component supports 6 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | client | AsyncHttpClient | To use a custom AsyncHttpClient | binding | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | clientConfig | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | sslContextParameters | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. | allowJavaSerializedObject | boolean | Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | headerFilterStrategy | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. |======================================================================= {% endraw %} // component options: END // endpoint options: START The AHC Websocket component supports 17 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | httpUri | common | | URI | *Required* The URI to use such as http://hostname:port/path | binding | common | | AhcBinding | To use a custom AhcBinding which allows to control how to bind between AHC and Camel. | bridgeEndpoint | common | false | boolean | If the option is true then the Exchange.HTTP_URI header is ignored and use the endpoint's URI for request. You may also set the throwExceptionOnFailure to be false to let the AhcProducer send all the fault response back. | bufferSize | common | 4096 | int | The initial in-memory buffer size used when transferring data between Camel and AHC Client. | headerFilterStrategy | common | | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. | throwExceptionOnFailure | common | true | boolean | Option to disable throwing the AhcOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. | transferException | common | false | boolean | If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type (for example using Jetty or Servlet Camel components). On the producer side the exception will be deserialized and thrown as is instead of the AhcOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | sendMessageOnError | consumer | false | boolean | Whether to send an message if the web-socket listener received an error. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | connectionClose | producer | false | boolean | Define if the Connection Close header has to be added to HTTP Request. This parameter is false by default | useStreaming | producer | false | boolean | To enable streaming to send data as multiple text fragments. | clientConfig | advanced | | AsyncHttpClientConfig | To configure the AsyncHttpClient to use a custom com.ning.http.client.AsyncHttpClientConfig instance. | clientConfigOptions | advanced | | Map | To configure the AsyncHttpClientConfig using the key/values from the Map. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | sslContextParameters | security | | SSLContextParameters | Reference to a org.apache.camel.util.jsse.SSLContextParameters in the Registry. This reference overrides any configured SSLContextParameters at the component level. See Using the JSSE Configuration Utility. Note that configuring this option will override any SSL/TLS configuration options provided through the clientConfig option at the endpoint or component level. |======================================================================= {% endraw %} // endpoint options: END [[AHC-WS-WritingandReadingDataoverWebsocket]] Writing and Reading Data over Websocket ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ An ahc-ws endpoint can either write data to the socket or read from the socket, depending on whether the endpoint is configured as the producer or the consumer, respectively. [[AHC-WS-ConfiguringURItoWriteorReadData]] Configuring URI to Write or Read Data ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ In the route below, Camel will write to the specified websocket connection. [source,java] ----------------------------------- from("direct:start") .to("ahc-ws://targethost"); ----------------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ In the route below, Camel will read from the specified websocket connection. [source,java] --------------------------- from("ahc-ws://targethost") .to("direct:next"); --------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ ?? [[AHC-WS-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:../../../../camel-ahc/src/main/docs/readme.html[AHC] * link:atmosphere-websocket.html[Atmosphere-Websocket] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-amqp version: 1.1.24 group: io.fabric8.funktion.connector name: amqp data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: amqp spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: amqp spec: containers: - image: fabric8/connector-amqp:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: amqp extendsScheme: jms syntax: amqp:destinationType:destinationName title: AMQP description: Messaging with AMQP protocol using Apache QPid Client. label: messaging deprecated: false async: true javaType: org.apache.camel.component.amqp.AMQPComponent groupId: org.apache.camel artifactId: camel-amqp version: 2.18.1 componentProperties: configuration: kind: property type: object javaType: org.apache.camel.component.jms.JmsConfiguration deprecated: false secret: false description: To use a shared JMS configuration acceptMessagesWhileStopping: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether the consumer accept messages while it is stopping. You may consider enabling this option if you start and stop JMS routes at runtime while there are still messages enqued on the queue. If this option is false and you stop the JMS route then messages may be rejected and the JMS broker would have to attempt redeliveries which yet again may be rejected and eventually the message may be moved at a dead letter queue on the JMS broker. To avoid this its recommended to enable this option. allowReplyManagerQuickStop: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether the DefaultMessageListenerContainer used in the reply managers for request-reply messaging allow the DefaultMessageListenerContainer.runningAllowed flag to quick stop in case JmsConfigurationisAcceptMessagesWhileStopping is enabled and org.apache.camel.CamelContext is currently being stopped. This quick stop ability is enabled by default in the regular JMS consumers but to enable for reply managers you must enable this flag. acknowledgementMode: kind: property type: integer javaType: int deprecated: false secret: false description: The JMS acknowledgement mode defined as an Integer. Allows you to set vendor-specific extensions to the acknowledgment mode. For the regular modes it is preferable to use the acknowledgementModeName instead. eagerLoadingOfProperties: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Enables eager loading of JMS properties as soon as a message is loaded which generally is inefficient as the JMS properties may not be required but sometimes can catch early any issues with the underlying JMS provider and the use of JMS properties acknowledgementModeName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: 'The JMS acknowledgement name which is one of: SESSION_TRANSACTED CLIENT_ACKNOWLEDGE AUTO_ACKNOWLEDGE DUPS_OK_ACKNOWLEDGE' autoStartup: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether the consumer container should auto-startup. cacheLevel: kind: property type: integer javaType: int deprecated: false secret: false description: Sets the cache level by ID for the underlying JMS resources. See cacheLevelName option for more details. cacheLevelName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: 'Sets the cache level by name for the underlying JMS resources. Possible values are: CACHE_AUTO CACHE_CONNECTION CACHE_CONSUMER CACHE_NONE and CACHE_SESSION. The default setting is CACHE_AUTO. See the Spring documentation and Transactions Cache Levels for more information.' replyToCacheLevelName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: 'Sets the cache level by name for the reply consumer when doing request/reply over JMS. This option only applies when using fixed reply queues (not temporary). Camel will by default use: CACHE_CONSUMER for exclusive or shared w/ replyToSelectorName. And CACHE_SESSION for shared without replyToSelectorName. Some JMS brokers such as IBM WebSphere may require to set the replyToCacheLevelName=CACHE_NONE to work. Note: If using temporary queues then CACHE_NONE is not allowed and you must use a higher value such as CACHE_CONSUMER or CACHE_SESSION.' clientId: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: Sets the JMS client ID to use. Note that this value if specified must be unique and can only be used by a single JMS connection instance. It is typically only required for durable topic subscriptions. If using Apache ActiveMQ you may prefer to use Virtual Topics instead. concurrentConsumers: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the default number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToConcurrentConsumers is used to control number of concurrent consumers on the reply message listener. replyToConcurrentConsumers: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the default number of concurrent consumers when doing request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. connectionFactory: kind: property type: object javaType: javax.jms.ConnectionFactory deprecated: false secret: false description: Sets the default connection factory to be use username: kind: property required: false type: string javaType: java.lang.String deprecated: false secret: true description: Username to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. password: kind: property required: false type: string javaType: java.lang.String deprecated: false secret: true description: Password to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. deliveryPersistent: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether persistent delivery is used by default. deliveryMode: kind: property type: integer javaType: java.lang.Integer deprecated: false secret: false description: Specifies the delivery mode to be used. Possible values are Possibles values are those defined by javax.jms.DeliveryMode. NON_PERSISTENT = 1 and PERSISTENT = 2. durableSubscriptionName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: The durable subscriber name for specifying durable topic subscriptions. The clientId option must be configured as well. exceptionListener: kind: property type: object javaType: javax.jms.ExceptionListener deprecated: false secret: false description: Specifies the JMS Exception Listener that is to be notified of any underlying JMS exceptions. errorHandler: kind: property type: object javaType: org.springframework.util.ErrorHandler deprecated: false secret: false description: Specifies a org.springframework.util.ErrorHandler to be invoked in case of any uncaught exceptions thrown while processing a Message. By default these exceptions will be logged at the WARN level if no errorHandler has been configured. You can configure logging level and whether stack traces should be logged using errorHandlerLoggingLevel and errorHandlerLogStackTrace options. This makes it much easier to configure than having to code a custom errorHandler. errorHandlerLoggingLevel: kind: property type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF deprecated: false secret: false description: Allows to configure the default errorHandler logging level for logging uncaught exceptions. errorHandlerLogStackTrace: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Allows to control whether stacktraces should be logged or not by the default errorHandler. explicitQosEnabled: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Set if the deliveryMode priority or timeToLive qualities of service should be used when sending messages. This option is based on Spring's JmsTemplate. The deliveryMode priority and timeToLive options are applied to the current endpoint. This contrasts with the preserveMessageQos option which operates at message granularity reading QoS properties exclusively from the Camel In message headers. exposeListenerSession: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether the listener session should be exposed when consuming messages. idleTaskExecutionLimit: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the limit for idle executions of a receive task not having received any message within its execution. If this limit is reached the task will shut down and leave receiving to other executing tasks (in the case of dynamic scheduling; see the maxConcurrentConsumers setting). There is additional doc available from Spring. idleConsumerLimit: kind: property type: integer javaType: int deprecated: false secret: false description: Specify the limit for the number of consumers that are allowed to be idle at any given time. maxConcurrentConsumers: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the maximum number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToMaxConcurrentConsumers is used to control number of concurrent consumers on the reply message listener. replyToMaxConcurrentConsumers: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the maximum number of concurrent consumers when using request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. replyOnTimeoutToMaxConcurrentConsumers: kind: property type: integer javaType: int deprecated: false secret: false description: Specifies the maximum number of concurrent consumers for continue routing when timeout occurred when using request/reply over JMS. maxMessagesPerTask: kind: property type: integer javaType: int deprecated: false secret: false description: The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required. messageConverter: kind: property type: object javaType: org.springframework.jms.support.converter.MessageConverter deprecated: false secret: false description: To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message. mapJmsMessage: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc. See section about how mapping works below for more details. messageIdEnabled: kind: property type: boolean javaType: boolean deprecated: false secret: false description: When sending specifies whether message IDs should be added. messageTimestampEnabled: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether timestamps should be enabled by default on sending messages. alwaysCopyMessage: kind: property type: boolean javaType: boolean deprecated: false secret: false description: If true Camel will always make a JMS message copy of the message when it is passed to the producer for sending. Copying the message is needed in some situations such as when a replyToDestinationSelectorName is set (incidentally Camel will set the alwaysCopyMessage option to true if a replyToDestinationSelectorName is set) useMessageIDAsCorrelationID: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. priority: kind: property type: integer javaType: int deprecated: false secret: false description: Values greater than 1 specify the message priority when sending (where 0 is the lowest priority and 9 is the highest). The explicitQosEnabled option must also be enabled in order for this option to have any effect. pubSubNoLocal: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether to inhibit the delivery of messages published by its own connection. receiveTimeout: kind: property type: integer javaType: long deprecated: false secret: false description: The timeout for receiving messages (in milliseconds). recoveryInterval: kind: property type: integer javaType: long deprecated: false secret: false description: Specifies the interval between recovery attempts i.e. when a connection is being refreshed in milliseconds. The default is 5000 ms that is 5 seconds. subscriptionDurable: kind: property type: boolean javaType: boolean deprecated: true secret: false description: 'Deprecated: Enabled by default if you specify a durableSubscriptionName and a clientId.' taskExecutor: kind: property type: object javaType: org.springframework.core.task.TaskExecutor deprecated: false secret: false description: Allows you to specify a custom task executor for consuming messages. timeToLive: kind: property type: integer javaType: long deprecated: false secret: false description: When sending messages specifies the time-to-live of the message (in milliseconds). transacted: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether to use transacted mode lazyCreateTransactionManager: kind: property type: boolean javaType: boolean deprecated: false secret: false description: If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true. transactionManager: kind: property type: object javaType: org.springframework.transaction.PlatformTransactionManager deprecated: false secret: false description: The Spring transaction manager to use. transactionName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: The name of the transaction to use. transactionTimeout: kind: property type: integer javaType: int deprecated: false secret: false description: The timeout value of the transaction (in seconds) if using transacted mode. testConnectionOnStartup: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well. asyncStartListener: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to startup the JmsConsumer message listener asynchronously when starting a route. For example if a JmsConsumer cannot get a connection to a remote JMS broker then it may block while retrying and/or failover. This will cause Camel to block while starting routes. By setting this option to true you will let routes startup while the JmsConsumer connects to the JMS broker using a dedicated thread in asynchronous mode. If this option is used then beware that if the connection could not be established then an exception is logged at WARN level and the consumer will not be able to receive messages; You can then restart the route to retry. asyncStopListener: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to stop the JmsConsumer message listener asynchronously when stopping a route. forceSendOriginalMessage: kind: property type: boolean javaType: boolean deprecated: false secret: false description: When using mapJmsMessage=false Camel will create a new JMS message to send to a new JMS destination if you touch the headers (get or set) during the route. Set this option to true to force Camel to send the original JMS message that was received. requestTimeout: kind: property type: integer javaType: long deprecated: false secret: false description: The timeout for waiting for a reply when using the InOut Exchange Pattern (in milliseconds). The default is 20 seconds. You can include the header CamelJmsRequestTimeout to override this endpoint configured timeout value and thus have per message individual timeout values. See also the requestTimeoutCheckerInterval option. requestTimeoutCheckerInterval: kind: property type: integer javaType: long deprecated: false secret: false description: Configures how often Camel should check for timed out Exchanges when doing request/reply over JMS. By default Camel checks once per second. But if you must react faster when a timeout occurs then you can lower this interval to check more frequently. The timeout is determined by the option requestTimeout. transferExchange: kind: property type: boolean javaType: boolean deprecated: false secret: false description: 'You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body Out body Fault body In headers Out headers Fault headers exchange properties exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side so Camel knows the payloads is an Exchange and not a regular payload.' transferException: kind: property type: boolean javaType: boolean deprecated: false secret: false description: If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled this option takes precedence. The caught exception is required to be serializable. The original Exception on the consumer side can be wrapped in an outer exception such as org.apache.camel.RuntimeCamelException when returned to the producer. transferFault: kind: property type: boolean javaType: boolean deprecated: false secret: false description: If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side then the fault flag on link org.apache.camel.MessageisFault() will be send back in the response as a JMS header with the key link JmsConstantsJMS_TRANSFER_FAULT. If the client is Camel the returned fault flag will be set on the link org.apache.camel.MessagesetFault(boolean). You may want to enable this when using Camel components that support faults such as SOAP based such as cxf or spring-ws. jmsOperations: kind: property type: object javaType: org.springframework.jms.core.JmsOperations deprecated: false secret: false description: Allows you to use your own implementation of the org.springframework.jms.core.JmsOperations interface. Camel uses JmsTemplate as default. Can be used for testing purpose but not used much as stated in the spring API docs. destinationResolver: kind: property type: object javaType: org.springframework.jms.support.destination.DestinationResolver deprecated: false secret: false description: A pluggable org.springframework.jms.support.destination.DestinationResolver that allows you to use your own resolver (for example to lookup the real destination in a JNDI registry). replyToType: kind: property type: string javaType: org.apache.camel.component.jms.ReplyToType enum: - Temporary - Shared - Exclusive deprecated: false secret: false description: 'Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary Shared or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details and especially the notes about the implications if running in a clustered environment and the fact that Shared reply queues has lower performance than its alternatives Temporary and Exclusive.' preserveMessageQos: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Set to true if you want to send message using the QoS settings specified on the message instead of the QoS settings on the JMS endpoint. The following three headers are considered JMSPriority JMSDeliveryMode and JMSExpiration. You can provide all or only some of them. If not provided Camel will fall back to use the values from the endpoint instead. So when using this option the headers override the values from the endpoint. The explicitQosEnabled option by contrast will only use options set on the endpoint and not values from the message header. asyncConsumer: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether the JmsConsumer processes the Exchange asynchronously. If enabled then the JmsConsumer may pickup the next message from the JMS queue while the previous message is being processed asynchronously (by the Asynchronous Routing Engine). This means that messages may be processed not 100 strictly in order. If disabled (as default) then the Exchange is fully processed before the JmsConsumer will pickup the next message from the JMS queue. Note if transacted has been enabled then asyncConsumer=true does not run asynchronously as transaction must be executed synchronously (Camel 3.0 may support async transactions). allowNullBody: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to allow sending messages with no body. If this option is false and the message body is null then an JMSException is thrown. includeSentJMSMessageID: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Only applicable when sending to JMS destination using InOnly (eg fire and forget). Enabling this option will enrich the Camel Exchange with the actual JMSMessageID that was used by the JMS client when the message was sent to the JMS destination. includeAllJMSXProperties: kind: property type: boolean javaType: boolean deprecated: false secret: false description: 'Whether to include all JMSXxxx properties when mapping from JMS to Camel Message. Setting this to true will include properties such as JMSXAppID and JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then this option does not apply.' defaultTaskExecutorType: kind: property type: string javaType: org.apache.camel.component.jms.DefaultTaskExecutorType enum: - ThreadPool - SimpleAsync deprecated: false secret: false description: 'Specifies what default TaskExecutor type to use in the DefaultMessageListenerContainer for both consumer endpoints and the ReplyTo consumer of producer endpoints. Possible values: SimpleAsync (uses Spring''s SimpleAsyncTaskExecutor) or ThreadPool (uses Spring''s ThreadPoolTaskExecutor with optimal values - cached threadpool-like). If not set it defaults to the previous behaviour which uses a cached thread pool for consumer endpoints and SimpleAsync for reply consumers. The use of ThreadPool is recommended to reduce thread trash in elastic configurations with dynamically increasing and decreasing concurrent consumers.' jmsKeyFormatStrategy: kind: property type: object javaType: org.apache.camel.component.jms.JmsKeyFormatStrategy deprecated: false secret: false description: 'Pluggable strategy for encoding and decoding JMS keys so they can be compliant with the JMS specification. Camel provides two implementations out of the box: default and passthrough. The default strategy will safely marshal dots and hyphens (. and -). The passthrough strategy leaves the key as is. Can be used for JMS brokers which do not care whether JMS header keys contain illegal characters. You can provide your own implementation of the org.apache.camel.component.jms.JmsKeyFormatStrategy and refer to it using the notation.' applicationContext: kind: property type: object javaType: org.springframework.context.ApplicationContext deprecated: false secret: false description: Sets the Spring ApplicationContext to use queueBrowseStrategy: kind: property type: object javaType: org.apache.camel.component.jms.QueueBrowseStrategy deprecated: false secret: false description: To use a custom QueueBrowseStrategy when browsing queues headerFilterStrategy: kind: property type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. messageCreatedStrategy: kind: property type: object javaType: org.apache.camel.component.jms.MessageCreatedStrategy deprecated: false secret: false description: To use the given MessageCreatedStrategy which are invoked when Camel creates new instances of javax.jms.Message objects when Camel is sending a JMS message. waitForProvisionCorrelationToBeUpdatedCounter: kind: property type: integer javaType: int deprecated: false secret: false description: Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. waitForProvisionCorrelationToBeUpdatedThreadSleepingTime: kind: property type: integer javaType: long deprecated: false secret: false description: Interval in millis to sleep each time while waiting for provisional correlation id to be updated. properties: destinationType: kind: path group: common type: string javaType: java.lang.String enum: - queue - topic - temp:queue - temp:topic deprecated: false secret: false defaultValue: queue description: The kind of destination to use destinationName: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Name of the queue or topic to use as destination clientId: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Sets the JMS client ID to use. Note that this value if specified must be unique and can only be used by a single JMS connection instance. It is typically only required for durable topic subscriptions. If using Apache ActiveMQ you may prefer to use Virtual Topics instead. connectionFactory: kind: parameter group: common type: object javaType: javax.jms.ConnectionFactory deprecated: false secret: false description: The connection factory to be use. A connection factory must be configured either on the component or endpoint. disableReplyTo: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If true a producer will behave like a InOnly exchange with the exception that JMSReplyTo header is sent out and not be suppressed like in the case of InOnly. Like InOnly the producer will not wait for a reply. A consumer with this flag will behave like InOnly. This feature can be used to bridge InOut requests to another queue so that a route on the other queue will send its response directly back to the original JMSReplyTo. durableSubscriptionName: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The durable subscriber name for specifying durable topic subscriptions. The clientId option must be configured as well. jmsMessageType: kind: parameter group: common type: string javaType: org.apache.camel.component.jms.JmsMessageType enum: - Bytes - Map - Object - Stream - Text deprecated: false secret: false description: 'Allows you to force the use of a specific javax.jms.Message implementation for sending JMS messages. Possible values are: Bytes Map Object Stream Text. By default Camel would determine which JMS message type to use from the In body type. This option allows you to specify it.' testConnectionOnStartup: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well. acknowledgementModeName: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String enum: - SESSION_TRANSACTED - CLIENT_ACKNOWLEDGE - AUTO_ACKNOWLEDGE - DUPS_OK_ACKNOWLEDGE deprecated: false secret: false defaultValue: AUTO_ACKNOWLEDGE description: 'The JMS acknowledgement name which is one of: SESSION_TRANSACTED CLIENT_ACKNOWLEDGE AUTO_ACKNOWLEDGE DUPS_OK_ACKNOWLEDGE' asyncConsumer: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether the JmsConsumer processes the Exchange asynchronously. If enabled then the JmsConsumer may pickup the next message from the JMS queue while the previous message is being processed asynchronously (by the Asynchronous Routing Engine). This means that messages may be processed not 100 strictly in order. If disabled (as default) then the Exchange is fully processed before the JmsConsumer will pickup the next message from the JMS queue. Note if transacted has been enabled then asyncConsumer=true does not run asynchronously as transaction must be executed synchronously (Camel 3.0 may support async transactions). autoStartup: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Specifies whether the consumer container should auto-startup. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. cacheLevelName: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String enum: - CACHE_AUTO - CACHE_CONNECTION - CACHE_CONSUMER - CACHE_NONE - CACHE_SESSION deprecated: false secret: false defaultValue: CACHE_AUTO description: 'Sets the cache level by name for the underlying JMS resources. Possible values are: CACHE_AUTO CACHE_CONNECTION CACHE_CONSUMER CACHE_NONE and CACHE_SESSION. The default setting is CACHE_AUTO. See the Spring documentation and Transactions Cache Levels for more information.' concurrentConsumers: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Specifies the default number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToConcurrentConsumers is used to control number of concurrent consumers on the reply message listener. maxConcurrentConsumers: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false description: Specifies the maximum number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToMaxConcurrentConsumers is used to control number of concurrent consumers on the reply message listener. replyTo: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Provides an explicit ReplyTo destination which overrides any incoming value of Message.getJMSReplyTo(). replyToDeliveryPersistent: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Specifies whether to use persistent delivery by default for replies. selector: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Sets the JMS selector to use acceptMessagesWhileStopping: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether the consumer accept messages while it is stopping. You may consider enabling this option if you start and stop JMS routes at runtime while there are still messages enqued on the queue. If this option is false and you stop the JMS route then messages may be rejected and the JMS broker would have to attempt redeliveries which yet again may be rejected and eventually the message may be moved at a dead letter queue on the JMS broker. To avoid this its recommended to enable this option. allowReplyManagerQuickStop: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether the DefaultMessageListenerContainer used in the reply managers for request-reply messaging allow the DefaultMessageListenerContainer.runningAllowed flag to quick stop in case JmsConfigurationisAcceptMessagesWhileStopping is enabled and org.apache.camel.CamelContext is currently being stopped. This quick stop ability is enabled by default in the regular JMS consumers but to enable for reply managers you must enable this flag. consumerType: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.component.jms.ConsumerType enum: - Simple - Default - Custom deprecated: false secret: false defaultValue: Default description: 'The consumer type to use which can be one of: Simple Default or Custom. The consumer type determines which Spring JMS listener to use. Default will use org.springframework.jms.listener.DefaultMessageListenerContainer Simple will use org.springframework.jms.listener.SimpleMessageListenerContainer. When Custom is specified the MessageListenerContainerFactory defined by the messageListenerContainerFactory option will determine what org.springframework.jms.listener.AbstractMessageListenerContainer to use.' defaultTaskExecutorType: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.component.jms.DefaultTaskExecutorType enum: - ThreadPool - SimpleAsync deprecated: false secret: false description: 'Specifies what default TaskExecutor type to use in the DefaultMessageListenerContainer for both consumer endpoints and the ReplyTo consumer of producer endpoints. Possible values: SimpleAsync (uses Spring''s SimpleAsyncTaskExecutor) or ThreadPool (uses Spring''s ThreadPoolTaskExecutor with optimal values - cached threadpool-like). If not set it defaults to the previous behaviour which uses a cached thread pool for consumer endpoints and SimpleAsync for reply consumers. The use of ThreadPool is recommended to reduce thread trash in elastic configurations with dynamically increasing and decreasing concurrent consumers.' eagerLoadingOfProperties: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Enables eager loading of JMS properties as soon as a message is loaded which generally is inefficient as the JMS properties may not be required but sometimes can catch early any issues with the underlying JMS provider and the use of JMS properties exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. exposeListenerSession: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether the listener session should be exposed when consuming messages. replyToSameDestinationAllowed: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether a JMS consumer is allowed to send a reply message to the same destination that the consumer is using to consume from. This prevents an endless loop by consuming and sending back the same message to itself. deliveryMode: kind: parameter group: producer label: producer type: string javaType: java.lang.Integer enum: - "1" - "2" deprecated: false secret: false description: Specifies the delivery mode to be used. Possibles values are those defined by javax.jms.DeliveryMode. NON_PERSISTENT = 1 and PERSISTENT = 2. deliveryPersistent: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Specifies whether persistent delivery is used by default. explicitQosEnabled: kind: parameter group: producer label: producer type: boolean javaType: java.lang.Boolean deprecated: false secret: false defaultValue: false description: Set if the deliveryMode priority or timeToLive qualities of service should be used when sending messages. This option is based on Spring's JmsTemplate. The deliveryMode priority and timeToLive options are applied to the current endpoint. This contrasts with the preserveMessageQos option which operates at message granularity reading QoS properties exclusively from the Camel In message headers. preserveMessageQos: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Set to true if you want to send message using the QoS settings specified on the message instead of the QoS settings on the JMS endpoint. The following three headers are considered JMSPriority JMSDeliveryMode and JMSExpiration. You can provide all or only some of them. If not provided Camel will fall back to use the values from the endpoint instead. So when using this option the headers override the values from the endpoint. The explicitQosEnabled option by contrast will only use options set on the endpoint and not values from the message header. priority: kind: parameter group: producer label: producer type: string javaType: int enum: - "1" - "2" - "3" - "4" - "5" - "6" - "7" - "8" - "9" deprecated: false secret: false defaultValue: "4" description: Values greater than 1 specify the message priority when sending (where 0 is the lowest priority and 9 is the highest). The explicitQosEnabled option must also be enabled in order for this option to have any effect. replyToConcurrentConsumers: kind: parameter group: producer label: producer type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Specifies the default number of concurrent consumers when doing request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. replyToMaxConcurrentConsumers: kind: parameter group: producer label: producer type: integer javaType: int deprecated: false secret: false description: Specifies the maximum number of concurrent consumers when using request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. replyToOnTimeoutMaxConcurrentConsumers: kind: parameter group: producer label: producer type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Specifies the maximum number of concurrent consumers for continue routing when timeout occurred when using request/reply over JMS. replyToOverride: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false description: Provides an explicit ReplyTo destination in the JMS message which overrides the setting of replyTo. It is useful if you want to forward the message to a remote Queue and receive the reply message from the ReplyTo destination. replyToType: kind: parameter group: producer label: producer type: string javaType: org.apache.camel.component.jms.ReplyToType enum: - Temporary - Shared - Exclusive deprecated: false secret: false description: 'Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary Shared or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details and especially the notes about the implications if running in a clustered environment and the fact that Shared reply queues has lower performance than its alternatives Temporary and Exclusive.' requestTimeout: kind: parameter group: producer label: producer type: integer javaType: long deprecated: false secret: false defaultValue: "20000" description: The timeout for waiting for a reply when using the InOut Exchange Pattern (in milliseconds). The default is 20 seconds. You can include the header CamelJmsRequestTimeout to override this endpoint configured timeout value and thus have per message individual timeout values. See also the requestTimeoutCheckerInterval option. timeToLive: kind: parameter group: producer label: producer type: integer javaType: long deprecated: false secret: false defaultValue: -1 description: When sending messages specifies the time-to-live of the message (in milliseconds). allowNullBody: kind: parameter group: producer (advanced) label: producer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Whether to allow sending messages with no body. If this option is false and the message body is null then an JMSException is thrown. alwaysCopyMessage: kind: parameter group: producer (advanced) label: producer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If true Camel will always make a JMS message copy of the message when it is passed to the producer for sending. Copying the message is needed in some situations such as when a replyToDestinationSelectorName is set (incidentally Camel will set the alwaysCopyMessage option to true if a replyToDestinationSelectorName is set) disableTimeToLive: kind: parameter group: producer (advanced) label: producer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Use this option to force disabling time to live. For example when you do request/reply over JMS then Camel will by default use the requestTimeout value as time to live on the message being sent. The problem is that the sender and receiver systems have to have their clocks synchronized so they are in sync. This is not always so easy to archive. So you can use disableTimeToLive=true to not set a time to live value on the sent message. Then the message will not expire on the receiver system. See below in section About time to live for more details. forceSendOriginalMessage: kind: parameter group: producer (advanced) label: producer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: When using mapJmsMessage=false Camel will create a new JMS message to send to a new JMS destination if you touch the headers (get or set) during the route. Set this option to true to force Camel to send the original JMS message that was received. includeSentJMSMessageID: kind: parameter group: producer (advanced) label: producer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Only applicable when sending to JMS destination using InOnly (eg fire and forget). Enabling this option will enrich the Camel Exchange with the actual JMSMessageID that was used by the JMS client when the message was sent to the JMS destination. replyToCacheLevelName: kind: parameter group: producer (advanced) label: producer,advanced type: string javaType: java.lang.String deprecated: false secret: false description: 'Sets the cache level by name for the reply consumer when doing request/reply over JMS. This option only applies when using fixed reply queues (not temporary). Camel will by default use: CACHE_CONSUMER for exclusive or shared w/ replyToSelectorName. And CACHE_SESSION for shared without replyToSelectorName. Some JMS brokers such as IBM WebSphere may require to set the replyToCacheLevelName=CACHE_NONE to work. Note: If using temporary queues then CACHE_NONE is not allowed and you must use a higher value such as CACHE_CONSUMER or CACHE_SESSION.' replyToDestinationSelectorName: kind: parameter group: producer (advanced) label: producer,advanced type: string javaType: java.lang.String deprecated: false secret: false description: Sets the JMS Selector using the fixed name to be used so you can filter out your own replies from the others when using a shared queue (that is if you are not using a temporary reply queue). asyncStartListener: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to startup the JmsConsumer message listener asynchronously when starting a route. For example if a JmsConsumer cannot get a connection to a remote JMS broker then it may block while retrying and/or failover. This will cause Camel to block while starting routes. By setting this option to true you will let routes startup while the JmsConsumer connects to the JMS broker using a dedicated thread in asynchronous mode. If this option is used then beware that if the connection could not be established then an exception is logged at WARN level and the consumer will not be able to receive messages; You can then restart the route to retry. asyncStopListener: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to stop the JmsConsumer message listener asynchronously when stopping a route. destinationResolver: kind: parameter group: advanced label: advanced type: object javaType: org.springframework.jms.support.destination.DestinationResolver deprecated: false secret: false description: A pluggable org.springframework.jms.support.destination.DestinationResolver that allows you to use your own resolver (for example to lookup the real destination in a JNDI registry). errorHandler: kind: parameter group: advanced label: advanced type: object javaType: org.springframework.util.ErrorHandler deprecated: false secret: false description: Specifies a org.springframework.util.ErrorHandler to be invoked in case of any uncaught exceptions thrown while processing a Message. By default these exceptions will be logged at the WARN level if no errorHandler has been configured. You can configure logging level and whether stack traces should be logged using errorHandlerLoggingLevel and errorHandlerLogStackTrace options. This makes it much easier to configure than having to code a custom errorHandler. errorHandlerLoggingLevel: kind: parameter group: advanced label: advanced type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF deprecated: false secret: false defaultValue: WARN description: Allows to configure the default errorHandler logging level for logging uncaught exceptions. errorHandlerLogStackTrace: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Allows to control whether stacktraces should be logged or not by the default errorHandler. exceptionListener: kind: parameter group: advanced label: advanced type: object javaType: javax.jms.ExceptionListener deprecated: false secret: false description: Specifies the JMS Exception Listener that is to be notified of any underlying JMS exceptions. headerFilterStrategy: kind: parameter group: advanced label: advanced type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. idleConsumerLimit: kind: parameter group: advanced label: advanced type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Specify the limit for the number of consumers that are allowed to be idle at any given time. idleTaskExecutionLimit: kind: parameter group: advanced label: advanced type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Specifies the limit for idle executions of a receive task not having received any message within its execution. If this limit is reached the task will shut down and leave receiving to other executing tasks (in the case of dynamic scheduling; see the maxConcurrentConsumers setting). There is additional doc available from Spring. includeAllJMSXProperties: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: 'Whether to include all JMSXxxx properties when mapping from JMS to Camel Message. Setting this to true will include properties such as JMSXAppID and JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then this option does not apply.' jmsKeyFormatStrategy: kind: parameter group: advanced label: advanced type: string javaType: java.lang.String enum: - default - passthrough deprecated: false secret: false description: 'Pluggable strategy for encoding and decoding JMS keys so they can be compliant with the JMS specification. Camel provides two implementations out of the box: default and passthrough. The default strategy will safely marshal dots and hyphens (. and -). The passthrough strategy leaves the key as is. Can be used for JMS brokers which do not care whether JMS header keys contain illegal characters. You can provide your own implementation of the org.apache.camel.component.jms.JmsKeyFormatStrategy and refer to it using the notation.' mapJmsMessage: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc. maxMessagesPerTask: kind: parameter group: advanced label: advanced type: integer javaType: int deprecated: false secret: false defaultValue: -1 description: The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required. messageConverter: kind: parameter group: advanced label: advanced type: object javaType: org.springframework.jms.support.converter.MessageConverter deprecated: false secret: false description: To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message. messageCreatedStrategy: kind: parameter group: advanced label: advanced type: object javaType: org.apache.camel.component.jms.MessageCreatedStrategy deprecated: false secret: false description: To use the given MessageCreatedStrategy which are invoked when Camel creates new instances of javax.jms.Message objects when Camel is sending a JMS message. messageIdEnabled: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: When sending specifies whether message IDs should be added. This is just an hint to the JMS broker.If the JMS provider accepts this hint these messages must have the message ID set to null; if the provider ignores the hint the message ID must be set to its normal unique value messageListenerContainerFactory: kind: parameter group: advanced label: advanced type: object javaType: org.apache.camel.component.jms.MessageListenerContainerFactory deprecated: false secret: false description: Registry ID of the MessageListenerContainerFactory used to determine what org.springframework.jms.listener.AbstractMessageListenerContainer to use to consume messages. Setting this will automatically set consumerType to Custom. messageTimestampEnabled: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Specifies whether timestamps should be enabled by default on sending messages. This is just an hint to the JMS broker.If the JMS provider accepts this hint these messages must have the timestamp set to zero; if the provider ignores the hint the timestamp must be set to its normal value pubSubNoLocal: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether to inhibit the delivery of messages published by its own connection. receiveTimeout: kind: parameter group: advanced label: advanced type: integer javaType: long deprecated: false secret: false defaultValue: "1000" description: The timeout for receiving messages (in milliseconds). recoveryInterval: kind: parameter group: advanced label: advanced type: integer javaType: long deprecated: false secret: false defaultValue: "5000" description: Specifies the interval between recovery attempts i.e. when a connection is being refreshed in milliseconds. The default is 5000 ms that is 5 seconds. requestTimeoutCheckerInterval: kind: parameter group: advanced label: advanced type: integer javaType: long deprecated: false secret: false defaultValue: "1000" description: Configures how often Camel should check for timed out Exchanges when doing request/reply over JMS. By default Camel checks once per second. But if you must react faster when a timeout occurs then you can lower this interval to check more frequently. The timeout is determined by the option requestTimeout. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). transferException: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled this option takes precedence. The caught exception is required to be serializable. The original Exception on the consumer side can be wrapped in an outer exception such as org.apache.camel.RuntimeCamelException when returned to the producer. transferExchange: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: 'You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body Out body Fault body In headers Out headers Fault headers exchange properties exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side so Camel knows the payloads is an Exchange and not a regular payload.' transferFault: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side then the fault flag on MessageisFault() will be send back in the response as a JMS header with the key org.apache.camel.component.jms.JmsConstantsJMS_TRANSFER_FAULTJMS_TRANSFER_FAULT. If the client is Camel the returned fault flag will be set on the link org.apache.camel.MessagesetFault(boolean). You may want to enable this when using Camel components that support faults such as SOAP based such as cxf or spring-ws. useMessageIDAsCorrelationID: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. waitForProvisionCorrelationToBeUpdatedCounter: kind: parameter group: advanced label: advanced type: integer javaType: int deprecated: false secret: false defaultValue: "50" description: Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. waitForProvisionCorrelationToBeUpdatedThreadSleepingTime: kind: parameter group: advanced label: advanced type: integer javaType: long deprecated: false secret: false defaultValue: "100" description: Interval in millis to sleep each time while waiting for provisional correlation id to be updated. password: kind: parameter group: security label: security type: string javaType: java.lang.String deprecated: false secret: true description: Password to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. username: kind: parameter group: security label: security type: string javaType: java.lang.String deprecated: false secret: true description: Username to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. transacted: kind: parameter group: transaction label: transaction type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether to use transacted mode lazyCreateTransactionManager: kind: parameter group: transaction (advanced) label: transaction,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true. transactionManager: kind: parameter group: transaction (advanced) label: transaction,advanced type: object javaType: org.springframework.transaction.PlatformTransactionManager deprecated: false secret: false description: The Spring transaction manager to use. transactionName: kind: parameter group: transaction (advanced) label: transaction,advanced type: string javaType: java.lang.String deprecated: false secret: false description: The name of the transaction to use. transactionTimeout: kind: parameter group: transaction (advanced) label: transaction,advanced type: integer javaType: int deprecated: false secret: false defaultValue: -1 description: The timeout value of the transaction (in seconds) if using transacted mode. documentation.adoc: "[[AMQP-AMQP]]\nAMQP\n~~~~\n\nThe *amqp:* component supports\ \ the http://www.amqp.org/[AMQP 1.0\nprotocol] using the JMS Client API of the\ \ http://qpid.apache.org/[Qpid]\nproject. In case you want to use AMQP 0.9 (in\ \ particular RabbitMQ) you\nmight also be interested in the link:rabbitmq.html[Camel\ \ RabbitMQ]\ncomponent. Please keep in mind that prior to the Camel 2.17.0 AMQP\n\ component supported AMQP 0.9 and above, however since Camel 2.17.0 it\nsupports\ \ only AMQP 1.0.\n\nMaven users will need to add the following dependency to\ \ their `pom.xml`\nfor this component:\n\n[source,xml]\n------------------------------------------------------------------------------------------------\n\ \n org.apache.camel\n camel-amqp\n\ \ ${camel.version} \n\n------------------------------------------------------------------------------------------------\n\ \n[[AMQP-URIformat]]\nURI format\n^^^^^^^^^^\n\n[source,java]\n---------------------------------------------\n\ amqp:[queue:|topic:]destinationName[?options]\n---------------------------------------------\n\ \n[[AMQP-AMQPOptions]]\nAMQP Options\n^^^^^^^^^^^^\n\nYou can specify all of\ \ the various configuration options of the\nlink:../../../../camel-jms/src/main/docs/readme.html[JMS]\ \ component after the destination name.\n\n\n\n\n// component options: START\n\ The AMQP component supports 74 options which are listed below.\n\n\n\n{% raw\ \ %}\n[width=\"100%\",cols=\"2,1m,7\",options=\"header\"]\n|=======================================================================\n\ | Name | Java Type | Description\n| configuration | JmsConfiguration | To use\ \ a shared JMS configuration\n| acceptMessagesWhileStopping | boolean | Specifies\ \ whether the consumer accept messages while it is stopping. You may consider\ \ enabling this option if you start and stop JMS routes at runtime while there\ \ are still messages enqued on the queue. If this option is false and you stop\ \ the JMS route then messages may be rejected and the JMS broker would have\ \ to attempt redeliveries which yet again may be rejected and eventually the\ \ message may be moved at a dead letter queue on the JMS broker. To avoid this\ \ its recommended to enable this option.\n| allowReplyManagerQuickStop | boolean\ \ | Whether the DefaultMessageListenerContainer used in the reply managers for\ \ request-reply messaging allow the DefaultMessageListenerContainer.runningAllowed\ \ flag to quick stop in case JmsConfigurationisAcceptMessagesWhileStopping is\ \ enabled and org.apache.camel.CamelContext is currently being stopped. This\ \ quick stop ability is enabled by default in the regular JMS consumers but\ \ to enable for reply managers you must enable this flag.\n| acknowledgementMode\ \ | int | The JMS acknowledgement mode defined as an Integer. Allows you to\ \ set vendor-specific extensions to the acknowledgment mode. For the regular\ \ modes it is preferable to use the acknowledgementModeName instead.\n| eagerLoadingOfProperties\ \ | boolean | Enables eager loading of JMS properties as soon as a message is\ \ loaded which generally is inefficient as the JMS properties may not be required\ \ but sometimes can catch early any issues with the underlying JMS provider\ \ and the use of JMS properties\n| acknowledgementModeName | String | The JMS\ \ acknowledgement name which is one of: SESSION_TRANSACTED CLIENT_ACKNOWLEDGE\ \ AUTO_ACKNOWLEDGE DUPS_OK_ACKNOWLEDGE\n| autoStartup | boolean | Specifies\ \ whether the consumer container should auto-startup.\n| cacheLevel | int |\ \ Sets the cache level by ID for the underlying JMS resources. See cacheLevelName\ \ option for more details.\n| cacheLevelName | String | Sets the cache level\ \ by name for the underlying JMS resources. Possible values are: CACHE_AUTO\ \ CACHE_CONNECTION CACHE_CONSUMER CACHE_NONE and CACHE_SESSION. The default\ \ setting is CACHE_AUTO. See the Spring documentation and Transactions Cache\ \ Levels for more information.\n| replyToCacheLevelName | String | Sets the\ \ cache level by name for the reply consumer when doing request/reply over JMS.\ \ This option only applies when using fixed reply queues (not temporary). Camel\ \ will by default use: CACHE_CONSUMER for exclusive or shared w/ replyToSelectorName.\ \ And CACHE_SESSION for shared without replyToSelectorName. Some JMS brokers\ \ such as IBM WebSphere may require to set the replyToCacheLevelName=CACHE_NONE\ \ to work. Note: If using temporary queues then CACHE_NONE is not allowed and\ \ you must use a higher value such as CACHE_CONSUMER or CACHE_SESSION.\n| clientId\ \ | String | Sets the JMS client ID to use. Note that this value if specified\ \ must be unique and can only be used by a single JMS connection instance. It\ \ is typically only required for durable topic subscriptions. If using Apache\ \ ActiveMQ you may prefer to use Virtual Topics instead.\n| concurrentConsumers\ \ | int | Specifies the default number of concurrent consumers when consuming\ \ from JMS (not for request/reply over JMS). See also the maxMessagesPerTask\ \ option to control dynamic scaling up/down of threads. When doing request/reply\ \ over JMS then the option replyToConcurrentConsumers is used to control number\ \ of concurrent consumers on the reply message listener.\n| replyToConcurrentConsumers\ \ | int | Specifies the default number of concurrent consumers when doing request/reply\ \ over JMS. See also the maxMessagesPerTask option to control dynamic scaling\ \ up/down of threads.\n| connectionFactory | ConnectionFactory | Sets the default\ \ connection factory to be use\n| username | String | Username to use with the\ \ ConnectionFactory. You can also configure username/password directly on the\ \ ConnectionFactory.\n| password | String | Password to use with the ConnectionFactory.\ \ You can also configure username/password directly on the ConnectionFactory.\n\ | deliveryPersistent | boolean | Specifies whether persistent delivery is used\ \ by default.\n| deliveryMode | Integer | Specifies the delivery mode to be\ \ used. Possible values are Possibles values are those defined by javax.jms.DeliveryMode.\ \ NON_PERSISTENT = 1 and PERSISTENT = 2.\n| durableSubscriptionName | String\ \ | The durable subscriber name for specifying durable topic subscriptions.\ \ The clientId option must be configured as well.\n| exceptionListener | ExceptionListener\ \ | Specifies the JMS Exception Listener that is to be notified of any underlying\ \ JMS exceptions.\n| errorHandler | ErrorHandler | Specifies a org.springframework.util.ErrorHandler\ \ to be invoked in case of any uncaught exceptions thrown while processing a\ \ Message. By default these exceptions will be logged at the WARN level if no\ \ errorHandler has been configured. You can configure logging level and whether\ \ stack traces should be logged using errorHandlerLoggingLevel and errorHandlerLogStackTrace\ \ options. This makes it much easier to configure than having to code a custom\ \ errorHandler.\n| errorHandlerLoggingLevel | LoggingLevel | Allows to configure\ \ the default errorHandler logging level for logging uncaught exceptions.\n\ | errorHandlerLogStackTrace | boolean | Allows to control whether stacktraces\ \ should be logged or not by the default errorHandler.\n| explicitQosEnabled\ \ | boolean | Set if the deliveryMode priority or timeToLive qualities of service\ \ should be used when sending messages. This option is based on Spring's JmsTemplate.\ \ The deliveryMode priority and timeToLive options are applied to the current\ \ endpoint. This contrasts with the preserveMessageQos option which operates\ \ at message granularity reading QoS properties exclusively from the Camel In\ \ message headers.\n| exposeListenerSession | boolean | Specifies whether the\ \ listener session should be exposed when consuming messages.\n| idleTaskExecutionLimit\ \ | int | Specifies the limit for idle executions of a receive task not having\ \ received any message within its execution. If this limit is reached the task\ \ will shut down and leave receiving to other executing tasks (in the case of\ \ dynamic scheduling; see the maxConcurrentConsumers setting). There is additional\ \ doc available from Spring.\n| idleConsumerLimit | int | Specify the limit\ \ for the number of consumers that are allowed to be idle at any given time.\n\ | maxConcurrentConsumers | int | Specifies the maximum number of concurrent\ \ consumers when consuming from JMS (not for request/reply over JMS). See also\ \ the maxMessagesPerTask option to control dynamic scaling up/down of threads.\ \ When doing request/reply over JMS then the option replyToMaxConcurrentConsumers\ \ is used to control number of concurrent consumers on the reply message listener.\n\ | replyToMaxConcurrentConsumers | int | Specifies the maximum number of concurrent\ \ consumers when using request/reply over JMS. See also the maxMessagesPerTask\ \ option to control dynamic scaling up/down of threads.\n| replyOnTimeoutToMaxConcurrentConsumers\ \ | int | Specifies the maximum number of concurrent consumers for continue\ \ routing when timeout occurred when using request/reply over JMS.\n| maxMessagesPerTask\ \ | int | The number of messages per task. -1 is unlimited. If you use a range\ \ for concurrent consumers (eg min max) then this option can be used to set\ \ a value to eg 100 to control how fast the consumers will shrink when less\ \ work is required.\n| messageConverter | MessageConverter | To use a custom\ \ Spring org.springframework.jms.support.converter.MessageConverter so you can\ \ be in control how to map to/from a javax.jms.Message.\n| mapJmsMessage | boolean\ \ | Specifies whether Camel should auto map the received JMS message to a suited\ \ payload type such as javax.jms.TextMessage to a String etc. See section about\ \ how mapping works below for more details.\n| messageIdEnabled | boolean |\ \ When sending specifies whether message IDs should be added.\n| messageTimestampEnabled\ \ | boolean | Specifies whether timestamps should be enabled by default on sending\ \ messages.\n| alwaysCopyMessage | boolean | If true Camel will always make\ \ a JMS message copy of the message when it is passed to the producer for sending.\ \ Copying the message is needed in some situations such as when a replyToDestinationSelectorName\ \ is set (incidentally Camel will set the alwaysCopyMessage option to true if\ \ a replyToDestinationSelectorName is set)\n| useMessageIDAsCorrelationID |\ \ boolean | Specifies whether JMSMessageID should always be used as JMSCorrelationID\ \ for InOut messages.\n| priority | int | Values greater than 1 specify the\ \ message priority when sending (where 0 is the lowest priority and 9 is the\ \ highest). The explicitQosEnabled option must also be enabled in order for\ \ this option to have any effect.\n| pubSubNoLocal | boolean | Specifies whether\ \ to inhibit the delivery of messages published by its own connection.\n| receiveTimeout\ \ | long | The timeout for receiving messages (in milliseconds).\n| recoveryInterval\ \ | long | Specifies the interval between recovery attempts i.e. when a connection\ \ is being refreshed in milliseconds. The default is 5000 ms that is 5 seconds.\n\ | subscriptionDurable | boolean | Deprecated: Enabled by default if you specify\ \ a durableSubscriptionName and a clientId.\n| taskExecutor | TaskExecutor |\ \ Allows you to specify a custom task executor for consuming messages.\n| timeToLive\ \ | long | When sending messages specifies the time-to-live of the message (in\ \ milliseconds).\n| transacted | boolean | Specifies whether to use transacted\ \ mode\n| lazyCreateTransactionManager | boolean | If true Camel will create\ \ a JmsTransactionManager if there is no transactionManager injected when option\ \ transacted=true.\n| transactionManager | PlatformTransactionManager | The\ \ Spring transaction manager to use.\n| transactionName | String | The name\ \ of the transaction to use.\n| transactionTimeout | int | The timeout value\ \ of the transaction (in seconds) if using transacted mode.\n| testConnectionOnStartup\ \ | boolean | Specifies whether to test the connection on startup. This ensures\ \ that when Camel starts that all the JMS consumers have a valid connection\ \ to the JMS broker. If a connection cannot be granted then Camel throws an\ \ exception on startup. This ensures that Camel is not started with failed connections.\ \ The JMS producers is tested as well.\n| asyncStartListener | boolean | Whether\ \ to startup the JmsConsumer message listener asynchronously when starting a\ \ route. For example if a JmsConsumer cannot get a connection to a remote JMS\ \ broker then it may block while retrying and/or failover. This will cause Camel\ \ to block while starting routes. By setting this option to true you will let\ \ routes startup while the JmsConsumer connects to the JMS broker using a dedicated\ \ thread in asynchronous mode. If this option is used then beware that if the\ \ connection could not be established then an exception is logged at WARN level\ \ and the consumer will not be able to receive messages; You can then restart\ \ the route to retry.\n| asyncStopListener | boolean | Whether to stop the JmsConsumer\ \ message listener asynchronously when stopping a route.\n| forceSendOriginalMessage\ \ | boolean | When using mapJmsMessage=false Camel will create a new JMS message\ \ to send to a new JMS destination if you touch the headers (get or set) during\ \ the route. Set this option to true to force Camel to send the original JMS\ \ message that was received.\n| requestTimeout | long | The timeout for waiting\ \ for a reply when using the InOut Exchange Pattern (in milliseconds). The default\ \ is 20 seconds. You can include the header CamelJmsRequestTimeout to override\ \ this endpoint configured timeout value and thus have per message individual\ \ timeout values. See also the requestTimeoutCheckerInterval option.\n| requestTimeoutCheckerInterval\ \ | long | Configures how often Camel should check for timed out Exchanges when\ \ doing request/reply over JMS. By default Camel checks once per second. But\ \ if you must react faster when a timeout occurs then you can lower this interval\ \ to check more frequently. The timeout is determined by the option requestTimeout.\n\ | transferExchange | boolean | You can transfer the exchange over the wire instead\ \ of just the body and headers. The following fields are transferred: In body\ \ Out body Fault body In headers Out headers Fault headers exchange properties\ \ exchange exception. This requires that the objects are serializable. Camel\ \ will exclude any non-serializable objects and log it at WARN level. You must\ \ enable this option on both the producer and consumer side so Camel knows the\ \ payloads is an Exchange and not a regular payload.\n| transferException |\ \ boolean | If enabled and you are using Request Reply messaging (InOut) and\ \ an Exchange failed on the consumer side then the caused Exception will be\ \ send back in response as a javax.jms.ObjectMessage. If the client is Camel\ \ the returned Exception is rethrown. This allows you to use Camel JMS as a\ \ bridge in your routing - for example using persistent queues to enable robust\ \ routing. Notice that if you also have transferExchange enabled this option\ \ takes precedence. The caught exception is required to be serializable. The\ \ original Exception on the consumer side can be wrapped in an outer exception\ \ such as org.apache.camel.RuntimeCamelException when returned to the producer.\n\ | transferFault | boolean | If enabled and you are using Request Reply messaging\ \ (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer\ \ side then the fault flag on link org.apache.camel.MessageisFault() will be\ \ send back in the response as a JMS header with the key link JmsConstantsJMS_TRANSFER_FAULT.\ \ If the client is Camel the returned fault flag will be set on the link org.apache.camel.MessagesetFault(boolean).\ \ You may want to enable this when using Camel components that support faults\ \ such as SOAP based such as cxf or spring-ws.\n| jmsOperations | JmsOperations\ \ | Allows you to use your own implementation of the org.springframework.jms.core.JmsOperations\ \ interface. Camel uses JmsTemplate as default. Can be used for testing purpose\ \ but not used much as stated in the spring API docs.\n| destinationResolver\ \ | DestinationResolver | A pluggable org.springframework.jms.support.destination.DestinationResolver\ \ that allows you to use your own resolver (for example to lookup the real destination\ \ in a JNDI registry).\n| replyToType | ReplyToType | Allows for explicitly\ \ specifying which kind of strategy to use for replyTo queues when doing request/reply\ \ over JMS. Possible values are: Temporary Shared or Exclusive. By default Camel\ \ will use temporary queues. However if replyTo has been configured then Shared\ \ is used by default. This option allows you to use exclusive queues instead\ \ of shared ones. See Camel JMS documentation for more details and especially\ \ the notes about the implications if running in a clustered environment and\ \ the fact that Shared reply queues has lower performance than its alternatives\ \ Temporary and Exclusive.\n| preserveMessageQos | boolean | Set to true if\ \ you want to send message using the QoS settings specified on the message instead\ \ of the QoS settings on the JMS endpoint. The following three headers are considered\ \ JMSPriority JMSDeliveryMode and JMSExpiration. You can provide all or only\ \ some of them. If not provided Camel will fall back to use the values from\ \ the endpoint instead. So when using this option the headers override the values\ \ from the endpoint. The explicitQosEnabled option by contrast will only use\ \ options set on the endpoint and not values from the message header.\n| asyncConsumer\ \ | boolean | Whether the JmsConsumer processes the Exchange asynchronously.\ \ If enabled then the JmsConsumer may pickup the next message from the JMS queue\ \ while the previous message is being processed asynchronously (by the Asynchronous\ \ Routing Engine). This means that messages may be processed not 100 strictly\ \ in order. If disabled (as default) then the Exchange is fully processed before\ \ the JmsConsumer will pickup the next message from the JMS queue. Note if transacted\ \ has been enabled then asyncConsumer=true does not run asynchronously as transaction\ \ must be executed synchronously (Camel 3.0 may support async transactions).\n\ | allowNullBody | boolean | Whether to allow sending messages with no body.\ \ If this option is false and the message body is null then an JMSException\ \ is thrown.\n| includeSentJMSMessageID | boolean | Only applicable when sending\ \ to JMS destination using InOnly (eg fire and forget). Enabling this option\ \ will enrich the Camel Exchange with the actual JMSMessageID that was used\ \ by the JMS client when the message was sent to the JMS destination.\n| includeAllJMSXProperties\ \ | boolean | Whether to include all JMSXxxx properties when mapping from JMS\ \ to Camel Message. Setting this to true will include properties such as JMSXAppID\ \ and JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then\ \ this option does not apply.\n| defaultTaskExecutorType | DefaultTaskExecutorType\ \ | Specifies what default TaskExecutor type to use in the DefaultMessageListenerContainer\ \ for both consumer endpoints and the ReplyTo consumer of producer endpoints.\ \ Possible values: SimpleAsync (uses Spring's SimpleAsyncTaskExecutor) or ThreadPool\ \ (uses Spring's ThreadPoolTaskExecutor with optimal values - cached threadpool-like).\ \ If not set it defaults to the previous behaviour which uses a cached thread\ \ pool for consumer endpoints and SimpleAsync for reply consumers. The use of\ \ ThreadPool is recommended to reduce thread trash in elastic configurations\ \ with dynamically increasing and decreasing concurrent consumers.\n| jmsKeyFormatStrategy\ \ | JmsKeyFormatStrategy | Pluggable strategy for encoding and decoding JMS\ \ keys so they can be compliant with the JMS specification. Camel provides two\ \ implementations out of the box: default and passthrough. The default strategy\ \ will safely marshal dots and hyphens (. and -). The passthrough strategy leaves\ \ the key as is. Can be used for JMS brokers which do not care whether JMS header\ \ keys contain illegal characters. You can provide your own implementation of\ \ the org.apache.camel.component.jms.JmsKeyFormatStrategy and refer to it using\ \ the notation.\n| applicationContext | ApplicationContext | Sets the Spring\ \ ApplicationContext to use\n| queueBrowseStrategy | QueueBrowseStrategy | To\ \ use a custom QueueBrowseStrategy when browsing queues\n| headerFilterStrategy\ \ | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header\ \ to and from Camel message.\n| messageCreatedStrategy | MessageCreatedStrategy\ \ | To use the given MessageCreatedStrategy which are invoked when Camel creates\ \ new instances of javax.jms.Message objects when Camel is sending a JMS message.\n\ | waitForProvisionCorrelationToBeUpdatedCounter | int | Number of times to wait\ \ for provisional correlation id to be updated to the actual correlation id\ \ when doing request/reply over JMS and when the option useMessageIDAsCorrelationID\ \ is enabled.\n| waitForProvisionCorrelationToBeUpdatedThreadSleepingTime |\ \ long | Interval in millis to sleep each time while waiting for provisional\ \ correlation id to be updated.\n|=======================================================================\n\ {% endraw %}\n// component options: END\n\n\n\n\n\n\n\n// endpoint options:\ \ START\nThe AMQP component supports 83 endpoint options which are listed below:\n\ \n{% raw %}\n[width=\"100%\",cols=\"2,1,1m,1m,5\",options=\"header\"]\n|=======================================================================\n\ | Name | Group | Default | Java Type | Description\n| destinationType | common\ \ | queue | String | The kind of destination to use\n| destinationName | common\ \ | | String | *Required* Name of the queue or topic to use as destination\n\ | clientId | common | | String | Sets the JMS client ID to use. Note that this\ \ value if specified must be unique and can only be used by a single JMS connection\ \ instance. It is typically only required for durable topic subscriptions. If\ \ using Apache ActiveMQ you may prefer to use Virtual Topics instead.\n| connectionFactory\ \ | common | | ConnectionFactory | The connection factory to be use. A connection\ \ factory must be configured either on the component or endpoint.\n| disableReplyTo\ \ | common | false | boolean | If true a producer will behave like a InOnly\ \ exchange with the exception that JMSReplyTo header is sent out and not be\ \ suppressed like in the case of InOnly. Like InOnly the producer will not wait\ \ for a reply. A consumer with this flag will behave like InOnly. This feature\ \ can be used to bridge InOut requests to another queue so that a route on the\ \ other queue will send its response directly back to the original JMSReplyTo.\n\ | durableSubscriptionName | common | | String | The durable subscriber name\ \ for specifying durable topic subscriptions. The clientId option must be configured\ \ as well.\n| jmsMessageType | common | | JmsMessageType | Allows you to force\ \ the use of a specific javax.jms.Message implementation for sending JMS messages.\ \ Possible values are: Bytes Map Object Stream Text. By default Camel would\ \ determine which JMS message type to use from the In body type. This option\ \ allows you to specify it.\n| testConnectionOnStartup | common | false | boolean\ \ | Specifies whether to test the connection on startup. This ensures that when\ \ Camel starts that all the JMS consumers have a valid connection to the JMS\ \ broker. If a connection cannot be granted then Camel throws an exception on\ \ startup. This ensures that Camel is not started with failed connections. The\ \ JMS producers is tested as well.\n| acknowledgementModeName | consumer | AUTO_ACKNOWLEDGE\ \ | String | The JMS acknowledgement name which is one of: SESSION_TRANSACTED\ \ CLIENT_ACKNOWLEDGE AUTO_ACKNOWLEDGE DUPS_OK_ACKNOWLEDGE\n| asyncConsumer |\ \ consumer | false | boolean | Whether the JmsConsumer processes the Exchange\ \ asynchronously. If enabled then the JmsConsumer may pickup the next message\ \ from the JMS queue while the previous message is being processed asynchronously\ \ (by the Asynchronous Routing Engine). This means that messages may be processed\ \ not 100 strictly in order. If disabled (as default) then the Exchange is fully\ \ processed before the JmsConsumer will pickup the next message from the JMS\ \ queue. Note if transacted has been enabled then asyncConsumer=true does not\ \ run asynchronously as transaction must be executed synchronously (Camel 3.0\ \ may support async transactions).\n| autoStartup | consumer | true | boolean\ \ | Specifies whether the consumer container should auto-startup.\n| bridgeErrorHandler\ \ | consumer | false | boolean | Allows for bridging the consumer to the Camel\ \ routing Error Handler which mean any exceptions occurred while the consumer\ \ is trying to pickup incoming messages or the likes will now be processed as\ \ a message and handled by the routing Error Handler. By default the consumer\ \ will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions\ \ that will be logged at WARN/ERROR level and ignored.\n| cacheLevelName | consumer\ \ | CACHE_AUTO | String | Sets the cache level by name for the underlying JMS\ \ resources. Possible values are: CACHE_AUTO CACHE_CONNECTION CACHE_CONSUMER\ \ CACHE_NONE and CACHE_SESSION. The default setting is CACHE_AUTO. See the Spring\ \ documentation and Transactions Cache Levels for more information.\n| concurrentConsumers\ \ | consumer | 1 | int | Specifies the default number of concurrent consumers\ \ when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask\ \ option to control dynamic scaling up/down of threads. When doing request/reply\ \ over JMS then the option replyToConcurrentConsumers is used to control number\ \ of concurrent consumers on the reply message listener.\n| maxConcurrentConsumers\ \ | consumer | | int | Specifies the maximum number of concurrent consumers\ \ when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask\ \ option to control dynamic scaling up/down of threads. When doing request/reply\ \ over JMS then the option replyToMaxConcurrentConsumers is used to control\ \ number of concurrent consumers on the reply message listener.\n| replyTo |\ \ consumer | | String | Provides an explicit ReplyTo destination which overrides\ \ any incoming value of Message.getJMSReplyTo().\n| replyToDeliveryPersistent\ \ | consumer | true | boolean | Specifies whether to use persistent delivery\ \ by default for replies.\n| selector | consumer | | String | Sets the JMS\ \ selector to use\n| acceptMessagesWhileStopping | consumer (advanced) | false\ \ | boolean | Specifies whether the consumer accept messages while it is stopping.\ \ You may consider enabling this option if you start and stop JMS routes at\ \ runtime while there are still messages enqued on the queue. If this option\ \ is false and you stop the JMS route then messages may be rejected and the\ \ JMS broker would have to attempt redeliveries which yet again may be rejected\ \ and eventually the message may be moved at a dead letter queue on the JMS\ \ broker. To avoid this its recommended to enable this option.\n| allowReplyManagerQuickStop\ \ | consumer (advanced) | false | boolean | Whether the DefaultMessageListenerContainer\ \ used in the reply managers for request-reply messaging allow the DefaultMessageListenerContainer.runningAllowed\ \ flag to quick stop in case JmsConfigurationisAcceptMessagesWhileStopping is\ \ enabled and org.apache.camel.CamelContext is currently being stopped. This\ \ quick stop ability is enabled by default in the regular JMS consumers but\ \ to enable for reply managers you must enable this flag.\n| consumerType |\ \ consumer (advanced) | Default | ConsumerType | The consumer type to use which\ \ can be one of: Simple Default or Custom. The consumer type determines which\ \ Spring JMS listener to use. Default will use org.springframework.jms.listener.DefaultMessageListenerContainer\ \ Simple will use org.springframework.jms.listener.SimpleMessageListenerContainer.\ \ When Custom is specified the MessageListenerContainerFactory defined by the\ \ messageListenerContainerFactory option will determine what org.springframework.jms.listener.AbstractMessageListenerContainer\ \ to use.\n| defaultTaskExecutorType | consumer (advanced) | | DefaultTaskExecutorType\ \ | Specifies what default TaskExecutor type to use in the DefaultMessageListenerContainer\ \ for both consumer endpoints and the ReplyTo consumer of producer endpoints.\ \ Possible values: SimpleAsync (uses Spring's SimpleAsyncTaskExecutor) or ThreadPool\ \ (uses Spring's ThreadPoolTaskExecutor with optimal values - cached threadpool-like).\ \ If not set it defaults to the previous behaviour which uses a cached thread\ \ pool for consumer endpoints and SimpleAsync for reply consumers. The use of\ \ ThreadPool is recommended to reduce thread trash in elastic configurations\ \ with dynamically increasing and decreasing concurrent consumers.\n| eagerLoadingOfProperties\ \ | consumer (advanced) | false | boolean | Enables eager loading of JMS properties\ \ as soon as a message is loaded which generally is inefficient as the JMS properties\ \ may not be required but sometimes can catch early any issues with the underlying\ \ JMS provider and the use of JMS properties\n| exceptionHandler | consumer\ \ (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler.\ \ Notice if the option bridgeErrorHandler is enabled then this options is not\ \ in use. By default the consumer will deal with exceptions that will be logged\ \ at WARN/ERROR level and ignored.\n| exchangePattern | consumer (advanced)\ \ | | ExchangePattern | Sets the exchange pattern when the consumer creates\ \ an exchange.\n| exposeListenerSession | consumer (advanced) | false | boolean\ \ | Specifies whether the listener session should be exposed when consuming\ \ messages.\n| replyToSameDestinationAllowed | consumer (advanced) | false |\ \ boolean | Whether a JMS consumer is allowed to send a reply message to the\ \ same destination that the consumer is using to consume from. This prevents\ \ an endless loop by consuming and sending back the same message to itself.\n\ | deliveryMode | producer | | Integer | Specifies the delivery mode to be used.\ \ Possibles values are those defined by javax.jms.DeliveryMode. NON_PERSISTENT\ \ = 1 and PERSISTENT = 2.\n| deliveryPersistent | producer | true | boolean\ \ | Specifies whether persistent delivery is used by default.\n| explicitQosEnabled\ \ | producer | false | Boolean | Set if the deliveryMode priority or timeToLive\ \ qualities of service should be used when sending messages. This option is\ \ based on Spring's JmsTemplate. The deliveryMode priority and timeToLive options\ \ are applied to the current endpoint. This contrasts with the preserveMessageQos\ \ option which operates at message granularity reading QoS properties exclusively\ \ from the Camel In message headers.\n| preserveMessageQos | producer | false\ \ | boolean | Set to true if you want to send message using the QoS settings\ \ specified on the message instead of the QoS settings on the JMS endpoint.\ \ The following three headers are considered JMSPriority JMSDeliveryMode and\ \ JMSExpiration. You can provide all or only some of them. If not provided Camel\ \ will fall back to use the values from the endpoint instead. So when using\ \ this option the headers override the values from the endpoint. The explicitQosEnabled\ \ option by contrast will only use options set on the endpoint and not values\ \ from the message header.\n| priority | producer | 4 | int | Values greater\ \ than 1 specify the message priority when sending (where 0 is the lowest priority\ \ and 9 is the highest). The explicitQosEnabled option must also be enabled\ \ in order for this option to have any effect.\n| replyToConcurrentConsumers\ \ | producer | 1 | int | Specifies the default number of concurrent consumers\ \ when doing request/reply over JMS. See also the maxMessagesPerTask option\ \ to control dynamic scaling up/down of threads.\n| replyToMaxConcurrentConsumers\ \ | producer | | int | Specifies the maximum number of concurrent consumers\ \ when using request/reply over JMS. See also the maxMessagesPerTask option\ \ to control dynamic scaling up/down of threads.\n| replyToOnTimeoutMaxConcurrentConsumers\ \ | producer | 1 | int | Specifies the maximum number of concurrent consumers\ \ for continue routing when timeout occurred when using request/reply over JMS.\n\ | replyToOverride | producer | | String | Provides an explicit ReplyTo destination\ \ in the JMS message which overrides the setting of replyTo. It is useful if\ \ you want to forward the message to a remote Queue and receive the reply message\ \ from the ReplyTo destination.\n| replyToType | producer | | ReplyToType |\ \ Allows for explicitly specifying which kind of strategy to use for replyTo\ \ queues when doing request/reply over JMS. Possible values are: Temporary Shared\ \ or Exclusive. By default Camel will use temporary queues. However if replyTo\ \ has been configured then Shared is used by default. This option allows you\ \ to use exclusive queues instead of shared ones. See Camel JMS documentation\ \ for more details and especially the notes about the implications if running\ \ in a clustered environment and the fact that Shared reply queues has lower\ \ performance than its alternatives Temporary and Exclusive.\n| requestTimeout\ \ | producer | 20000 | long | The timeout for waiting for a reply when using\ \ the InOut Exchange Pattern (in milliseconds). The default is 20 seconds. You\ \ can include the header CamelJmsRequestTimeout to override this endpoint configured\ \ timeout value and thus have per message individual timeout values. See also\ \ the requestTimeoutCheckerInterval option.\n| timeToLive | producer | -1 |\ \ long | When sending messages specifies the time-to-live of the message (in\ \ milliseconds).\n| allowNullBody | producer (advanced) | true | boolean | Whether\ \ to allow sending messages with no body. If this option is false and the message\ \ body is null then an JMSException is thrown.\n| alwaysCopyMessage | producer\ \ (advanced) | false | boolean | If true Camel will always make a JMS message\ \ copy of the message when it is passed to the producer for sending. Copying\ \ the message is needed in some situations such as when a replyToDestinationSelectorName\ \ is set (incidentally Camel will set the alwaysCopyMessage option to true if\ \ a replyToDestinationSelectorName is set)\n| disableTimeToLive | producer (advanced)\ \ | false | boolean | Use this option to force disabling time to live. For example\ \ when you do request/reply over JMS then Camel will by default use the requestTimeout\ \ value as time to live on the message being sent. The problem is that the sender\ \ and receiver systems have to have their clocks synchronized so they are in\ \ sync. This is not always so easy to archive. So you can use disableTimeToLive=true\ \ to not set a time to live value on the sent message. Then the message will\ \ not expire on the receiver system. See below in section About time to live\ \ for more details.\n| forceSendOriginalMessage | producer (advanced) | false\ \ | boolean | When using mapJmsMessage=false Camel will create a new JMS message\ \ to send to a new JMS destination if you touch the headers (get or set) during\ \ the route. Set this option to true to force Camel to send the original JMS\ \ message that was received.\n| includeSentJMSMessageID | producer (advanced)\ \ | false | boolean | Only applicable when sending to JMS destination using\ \ InOnly (eg fire and forget). Enabling this option will enrich the Camel Exchange\ \ with the actual JMSMessageID that was used by the JMS client when the message\ \ was sent to the JMS destination.\n| replyToCacheLevelName | producer (advanced)\ \ | | String | Sets the cache level by name for the reply consumer when doing\ \ request/reply over JMS. This option only applies when using fixed reply queues\ \ (not temporary). Camel will by default use: CACHE_CONSUMER for exclusive or\ \ shared w/ replyToSelectorName. And CACHE_SESSION for shared without replyToSelectorName.\ \ Some JMS brokers such as IBM WebSphere may require to set the replyToCacheLevelName=CACHE_NONE\ \ to work. Note: If using temporary queues then CACHE_NONE is not allowed and\ \ you must use a higher value such as CACHE_CONSUMER or CACHE_SESSION.\n| replyToDestinationSelectorName\ \ | producer (advanced) | | String | Sets the JMS Selector using the fixed\ \ name to be used so you can filter out your own replies from the others when\ \ using a shared queue (that is if you are not using a temporary reply queue).\n\ | asyncStartListener | advanced | false | boolean | Whether to startup the JmsConsumer\ \ message listener asynchronously when starting a route. For example if a JmsConsumer\ \ cannot get a connection to a remote JMS broker then it may block while retrying\ \ and/or failover. This will cause Camel to block while starting routes. By\ \ setting this option to true you will let routes startup while the JmsConsumer\ \ connects to the JMS broker using a dedicated thread in asynchronous mode.\ \ If this option is used then beware that if the connection could not be established\ \ then an exception is logged at WARN level and the consumer will not be able\ \ to receive messages; You can then restart the route to retry.\n| asyncStopListener\ \ | advanced | false | boolean | Whether to stop the JmsConsumer message listener\ \ asynchronously when stopping a route.\n| destinationResolver | advanced |\ \ | DestinationResolver | A pluggable org.springframework.jms.support.destination.DestinationResolver\ \ that allows you to use your own resolver (for example to lookup the real destination\ \ in a JNDI registry).\n| errorHandler | advanced | | ErrorHandler | Specifies\ \ a org.springframework.util.ErrorHandler to be invoked in case of any uncaught\ \ exceptions thrown while processing a Message. By default these exceptions\ \ will be logged at the WARN level if no errorHandler has been configured. You\ \ can configure logging level and whether stack traces should be logged using\ \ errorHandlerLoggingLevel and errorHandlerLogStackTrace options. This makes\ \ it much easier to configure than having to code a custom errorHandler.\n|\ \ errorHandlerLoggingLevel | advanced | WARN | LoggingLevel | Allows to configure\ \ the default errorHandler logging level for logging uncaught exceptions.\n\ | errorHandlerLogStackTrace | advanced | true | boolean | Allows to control\ \ whether stacktraces should be logged or not by the default errorHandler.\n\ | exceptionListener | advanced | | ExceptionListener | Specifies the JMS Exception\ \ Listener that is to be notified of any underlying JMS exceptions.\n| headerFilterStrategy\ \ | advanced | | HeaderFilterStrategy | To use a custom HeaderFilterStrategy\ \ to filter header to and from Camel message.\n| idleConsumerLimit | advanced\ \ | 1 | int | Specify the limit for the number of consumers that are allowed\ \ to be idle at any given time.\n| idleTaskExecutionLimit | advanced | 1 | int\ \ | Specifies the limit for idle executions of a receive task not having received\ \ any message within its execution. If this limit is reached the task will shut\ \ down and leave receiving to other executing tasks (in the case of dynamic\ \ scheduling; see the maxConcurrentConsumers setting). There is additional doc\ \ available from Spring.\n| includeAllJMSXProperties | advanced | false | boolean\ \ | Whether to include all JMSXxxx properties when mapping from JMS to Camel\ \ Message. Setting this to true will include properties such as JMSXAppID and\ \ JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then\ \ this option does not apply.\n| jmsKeyFormatStrategy | advanced | | String\ \ | Pluggable strategy for encoding and decoding JMS keys so they can be compliant\ \ with the JMS specification. Camel provides two implementations out of the\ \ box: default and passthrough. The default strategy will safely marshal dots\ \ and hyphens (. and -). The passthrough strategy leaves the key as is. Can\ \ be used for JMS brokers which do not care whether JMS header keys contain\ \ illegal characters. You can provide your own implementation of the org.apache.camel.component.jms.JmsKeyFormatStrategy\ \ and refer to it using the notation.\n| mapJmsMessage | advanced | true | boolean\ \ | Specifies whether Camel should auto map the received JMS message to a suited\ \ payload type such as javax.jms.TextMessage to a String etc.\n| maxMessagesPerTask\ \ | advanced | -1 | int | The number of messages per task. -1 is unlimited.\ \ If you use a range for concurrent consumers (eg min max) then this option\ \ can be used to set a value to eg 100 to control how fast the consumers will\ \ shrink when less work is required.\n| messageConverter | advanced | | MessageConverter\ \ | To use a custom Spring org.springframework.jms.support.converter.MessageConverter\ \ so you can be in control how to map to/from a javax.jms.Message.\n| messageCreatedStrategy\ \ | advanced | | MessageCreatedStrategy | To use the given MessageCreatedStrategy\ \ which are invoked when Camel creates new instances of javax.jms.Message objects\ \ when Camel is sending a JMS message.\n| messageIdEnabled | advanced | true\ \ | boolean | When sending specifies whether message IDs should be added. This\ \ is just an hint to the JMS broker.If the JMS provider accepts this hint these\ \ messages must have the message ID set to null; if the provider ignores the\ \ hint the message ID must be set to its normal unique value\n| messageListenerContainerFactory\ \ | advanced | | MessageListenerContainerFactory | Registry ID of the MessageListenerContainerFactory\ \ used to determine what org.springframework.jms.listener.AbstractMessageListenerContainer\ \ to use to consume messages. Setting this will automatically set consumerType\ \ to Custom.\n| messageTimestampEnabled | advanced | true | boolean | Specifies\ \ whether timestamps should be enabled by default on sending messages. This\ \ is just an hint to the JMS broker.If the JMS provider accepts this hint these\ \ messages must have the timestamp set to zero; if the provider ignores the\ \ hint the timestamp must be set to its normal value\n| pubSubNoLocal | advanced\ \ | false | boolean | Specifies whether to inhibit the delivery of messages\ \ published by its own connection.\n| receiveTimeout | advanced | 1000 | long\ \ | The timeout for receiving messages (in milliseconds).\n| recoveryInterval\ \ | advanced | 5000 | long | Specifies the interval between recovery attempts\ \ i.e. when a connection is being refreshed in milliseconds. The default is\ \ 5000 ms that is 5 seconds.\n| requestTimeoutCheckerInterval | advanced | 1000\ \ | long | Configures how often Camel should check for timed out Exchanges when\ \ doing request/reply over JMS. By default Camel checks once per second. But\ \ if you must react faster when a timeout occurs then you can lower this interval\ \ to check more frequently. The timeout is determined by the option requestTimeout.\n\ | synchronous | advanced | false | boolean | Sets whether synchronous processing\ \ should be strictly used or Camel is allowed to use asynchronous processing\ \ (if supported).\n| transferException | advanced | false | boolean | If enabled\ \ and you are using Request Reply messaging (InOut) and an Exchange failed on\ \ the consumer side then the caused Exception will be send back in response\ \ as a javax.jms.ObjectMessage. If the client is Camel the returned Exception\ \ is rethrown. This allows you to use Camel JMS as a bridge in your routing\ \ - for example using persistent queues to enable robust routing. Notice that\ \ if you also have transferExchange enabled this option takes precedence. The\ \ caught exception is required to be serializable. The original Exception on\ \ the consumer side can be wrapped in an outer exception such as org.apache.camel.RuntimeCamelException\ \ when returned to the producer.\n| transferExchange | advanced | false | boolean\ \ | You can transfer the exchange over the wire instead of just the body and\ \ headers. The following fields are transferred: In body Out body Fault body\ \ In headers Out headers Fault headers exchange properties exchange exception.\ \ This requires that the objects are serializable. Camel will exclude any non-serializable\ \ objects and log it at WARN level. You must enable this option on both the\ \ producer and consumer side so Camel knows the payloads is an Exchange and\ \ not a regular payload.\n| transferFault | advanced | false | boolean | If\ \ enabled and you are using Request Reply messaging (InOut) and an Exchange\ \ failed with a SOAP fault (not exception) on the consumer side then the fault\ \ flag on MessageisFault() will be send back in the response as a JMS header\ \ with the key org.apache.camel.component.jms.JmsConstantsJMS_TRANSFER_FAULTJMS_TRANSFER_FAULT.\ \ If the client is Camel the returned fault flag will be set on the link org.apache.camel.MessagesetFault(boolean).\ \ You may want to enable this when using Camel components that support faults\ \ such as SOAP based such as cxf or spring-ws.\n| useMessageIDAsCorrelationID\ \ | advanced | false | boolean | Specifies whether JMSMessageID should always\ \ be used as JMSCorrelationID for InOut messages.\n| waitForProvisionCorrelationToBeUpdatedCounter\ \ | advanced | 50 | int | Number of times to wait for provisional correlation\ \ id to be updated to the actual correlation id when doing request/reply over\ \ JMS and when the option useMessageIDAsCorrelationID is enabled.\n| waitForProvisionCorrelationToBeUpdatedThreadSleepingTime\ \ | advanced | 100 | long | Interval in millis to sleep each time while waiting\ \ for provisional correlation id to be updated.\n| password | security | |\ \ String | Password to use with the ConnectionFactory. You can also configure\ \ username/password directly on the ConnectionFactory.\n| username | security\ \ | | String | Username to use with the ConnectionFactory. You can also configure\ \ username/password directly on the ConnectionFactory.\n| transacted | transaction\ \ | false | boolean | Specifies whether to use transacted mode\n| lazyCreateTransactionManager\ \ | transaction (advanced) | true | boolean | If true Camel will create a JmsTransactionManager\ \ if there is no transactionManager injected when option transacted=true.\n\ | transactionManager | transaction (advanced) | | PlatformTransactionManager\ \ | The Spring transaction manager to use.\n| transactionName | transaction\ \ (advanced) | | String | The name of the transaction to use.\n| transactionTimeout\ \ | transaction (advanced) | -1 | int | The timeout value of the transaction\ \ (in seconds) if using transacted mode.\n|=======================================================================\n\ {% endraw %}\n// endpoint options: END\n\n\n\n\n[[AMQP-Usage]]\nUsage\n^^^^^\n\ \nAs AMQP component is inherited from JMS component, the usage of the\nformer\ \ is almost identical to the latter:\n\n*Using AMQP component*\n\n[source,java]\n\ ------------------------------------\n// Consuming from AMQP queue\nfrom(\"\ amqp:queue:incoming\").\n to(...);\n??\n// Sending message to the AMQP topic\n\ from(...).\n to(\"amqp:topic:notify\");\n------------------------------------\n\ \n[[AMQP-ConfiguringAMQPcomponent]]\nConfiguring AMQP component\n^^^^^^^^^^^^^^^^^^^^^^^^^^\n\ \nStarting from the Camel 2.16.1 you can also use the\n`AMQPComponent#amqp10Component(String\ \ connectionURI)` factory method to\nreturn the AMQP 1.0 component with the\ \ pre-configured??topic prefix:??\n\n*Creating AMQP 1.0 component*\n\n[source,java]\n\ -----------------------------------------------------------------------------------------\n\ \ AMQPComponent amqp = AMQPComponent.amqp10Component(\"amqp://guest:guest@localhost:5672\"\ );\n-----------------------------------------------------------------------------------------\n\ \nKeep in mind that starting from the\nCamel??2.17??the??`AMQPComponent#amqp10Component(String\ \ connectionURI)`??factory\nmethod has been deprecated on the behalf of the\n\ `AMQPComponent#amqpComponent(String connectionURI)`:??\n\n*Creating AMQP 1.0\ \ component*\n\n[source,java]\n--------------------------------------------------------------------------------------------------------\n\ AMQPComponent amqp = AMQPComponent.amqpComponent(\"amqp://localhost:5672\");\n\ ??\nAMQPComponent authorizedAmqp = AMQPComponent.amqpComponent(\"amqp://localhost:5672\"\ , \"user\", \"password\");\n--------------------------------------------------------------------------------------------------------\n\ \nStarting from Camel 2.17, in order to automatically configure the AMQP\ncomponent,\ \ you can also add an instance\nof??`org.apache.camel.component.amqp.AMQPConnectionDetails`\ \ to the\nregistry. For example for Spring Boot you just have to define??bean:\n\ \n*AMQP connection details auto-configuration*\n\n[source,java]\n-------------------------------------------------------------------------------------\n\ @Bean\nAMQPConnectionDetails amqpConnection() {\n return new AMQPConnectionDetails(\"\ amqp://localhost:5672\"); \n}\n??\n@Bean\nAMQPConnectionDetails securedAmqpConnection()\ \ {\n return new AMQPConnectionDetails(\"amqp://lcoalhost:5672\", \"username\"\ , \"password\"); \n}\n-------------------------------------------------------------------------------------\n\ \nLikewise, you can also use CDI producer methods when using Camel-CDI\n\n*AMQP\ \ connection details auto-configuration for CDI*\n\n[source,java]\n-------------------------------------------------------------------------------------\n\ @Produces\nAMQPConnectionDetails amqpConnection() {\n return new AMQPConnectionDetails(\"\ amqp://localhost:5672\");\n}\n-------------------------------------------------------------------------------------??\n\ \nYou can also rely on the link:properties.html[Camel properties] to read\n\ the AMQP connection details. Factory\nmethod??`AMQPConnectionDetails.discoverAMQP()`??attempts\ \ to read Camel\nproperties in a Kubernetes-like convention, just as demonstrated\ \ on the\nsnippet below:\n\n??\n\n*AMQP connection details auto-configuration*\n\ \n[source,java]\n-----------------------------------------------\nexport AMQP_SERVICE_HOST\ \ = \"mybroker.com\"\nexport AMQP_SERVICE_PORT = \"6666\"\nexport AMQP_SERVICE_USERNAME\ \ = \"username\"\nexport AMQP_SERVICE_PASSWORD = \"password\"\n??\n...\n??\n\ @Bean\nAMQPConnectionDetails amqpConnection() {\n return AMQPConnectionDetails.discoverAMQP();\ \ \n}\n-----------------------------------------------\n\n[[AMQP-Usingtopics]]\n\ Using topics\n^^^^^^^^^^^^\n\nTo have using topics working with??`camel-amqp`??you\ \ need to configure the\ncomponent to use??`topic://`??as topic prefix, as shown\ \ below:\n\n[source,java]\n-------------------------------------------------------------------------------------------------------------------------------\n\ \ \n \n \n \n \ \ \n \n \ \ \n \n-------------------------------------------------------------------------------------------------------------------------------\n\ \nKeep in mind that both????`AMQPComponent#amqpComponent()`??methods and\n`AMQPConnectionDetails`\ \ pre-configure the component with the topic\nprefix, so you don't have to configure\ \ it explicitly.\n\n[[AMQP-SeeAlso]]\nSee Also\n^^^^^^^^\n\n* link:configuring-camel.html[Configuring\ \ Camel]\n* link:component.html[Component]\n* link:endpoint.html[Endpoint]\n\ * link:getting-started.html[Getting Started]\n\n" - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-apns version: 1.1.24 group: io.fabric8.funktion.connector name: apns data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: apns spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: apns spec: containers: - image: fabric8/connector-apns:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: apns syntax: apns:name title: APNS description: For sending notifications to Apple iOS devices. label: eventbus,mobile deprecated: false async: false javaType: org.apache.camel.component.apns.ApnsComponent groupId: org.apache.camel artifactId: camel-apns version: 2.18.1 componentProperties: apnsService: kind: property type: object javaType: com.notnoop.apns.ApnsService deprecated: false secret: false description: To use a custom link ApnsService properties: name: kind: path group: common type: string javaType: java.lang.String deprecated: false secret: false description: Name of the endpoint tokens: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Configure this property in case you want to statically declare tokens related to devices you want to notify. Tokens are separated by comma. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[APNS-ApnsComponent]] Apns Component ~~~~~~~~~~~~~~ *Available as of Camel 2.8* The *apns* component is used for sending notifications to iOS devices. The apns components use https://github.com/notnoop/java-apns[javapns] library. + The component supports sending notifications to Apple Push Notification Servers (APNS) and consuming feedback from the servers. The consumer is configured with 3600 seconds for polling by default because it is a best practice to consume feedback stream from Apple Push Notification Servers only from time to time. For example: every 1 hour to avoid flooding the servers. The feedback stream gives informations about inactive devices. You only need to get this informations every some hours if your mobile application is not a heavily used one. Maven users will need to add the following dependency to their `pom.xml` for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-apns x.x.x ------------------------------------------------------------ [[APNS-URIformat]] URI format ^^^^^^^^^^ To send notifications: [source,java] --------------------- apns:notify[?options] --------------------- To consume feedback: [source,java] ----------------------- apns:consumer[?options] ----------------------- [[APNS-Options]] Options ^^^^^^^ // component options: START The APNS component supports 1 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | apnsService | ApnsService | To use a custom link ApnsService |======================================================================= {% endraw %} // component options: END // endpoint options: START The APNS component supports 21 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | name | common | | String | Name of the endpoint | tokens | common | | String | Configure this property in case you want to statically declare tokens related to devices you want to notify. Tokens are separated by comma. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END You can append query options to the URI in the following format, `?option=value&option=value&...` [[APNS-Component]] Component +++++++++ The `ApnsComponent` must be configured with a `com.notnoop.apns.ApnsService`. The service can be created and configured using the `org.apache.camel.component.apns.factory.ApnsServiceFactory`. See further below for an example. And as well in the https://svn.apache.org/repos/asf/camel/trunk/components/camel-apns/[test source code]. [[APNS-Exchangedataformat]] Exchange data format ^^^^^^^^^^^^^^^^^^^^ When Camel will fetch feedback data corresponding to inactive devices, it will retrieve a List of InactiveDevice objects. Each InactiveDevice object of the retrieved list will be setted as the In body, and then processed by the consumer endpoint. [[APNS-MessageHeaders]] Message Headers ^^^^^^^^^^^^^^^ Camel Apns uses these headers. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Property |Default |Description |`CamelApnsTokens` | |Empty by default. |`CamelApnsMessageType` |`STRING, PAYLOAD, APNS_NOTIFICATION`?? |In case you choose PAYLOAD for the message type, then the message will be considered as a APNS payload and sent as is. In case you choose STRING, message will be converted as a APNS payload. From *Camel 2.16* onwards APNS_NOTIFICATION is used for sending message body as com.notnoop.apns.ApnsNotification types. |======================================================================= [[APNS-ApnsServiceFactorybuildercallback]] ApnsServiceFactory builder callback ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `ApnsServiceFactory` comes with the empty callback method that could be used to configure (or even replace) the default `ApnsServiceBuilder` instance. The signature of the method could look as follows: [source,java] ---------------------------------------------------------------------------------------- protected ApnsServiceBuilder configureServiceBuilder(ApnsServiceBuilder serviceBuilder); ---------------------------------------------------------------------------------------- And could be used like as follows: [source,java] ------------------------------------------------------------------------------------------- ApnsServiceFactory proxiedApnsServiceFactory = new ApnsServiceFactory(){ ?? @Override protected ApnsServiceBuilder configureServiceBuilder(ApnsServiceBuilder serviceBuilder) { return serviceBuilder.withSocksProxy("my.proxy.com", 6666); } }; ------------------------------------------------------------------------------------------- [[APNS-Samples]] Samples ^^^^^^^ [[APNS-CamelXmlroute]] Camel Xml route +++++++++++++++ [source,xml] -------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------- [[APNS-CamelJavaroute]] Camel Java route ++++++++++++++++ [[APNS-Createcamelcontextanddeclareapnscomponentprogrammatically]] Create camel context and declare apns component programmatically [source,java] ---------------------------------------------------------------------------------- protected CamelContext createCamelContext() throws Exception { CamelContext camelContext = super.createCamelContext(); ApnsServiceFactory apnsServiceFactory = new ApnsServiceFactory(); apnsServiceFactory.setCertificatePath("classpath:/certificate.p12"); apnsServiceFactory.setCertificatePassword("MyCertPassword"); ApnsService apnsService = apnsServiceFactory.getApnsService(camelContext); ApnsComponent apnsComponent = new ApnsComponent(apnsService); camelContext.addComponent("apns", apnsComponent); return camelContext; } ---------------------------------------------------------------------------------- [[APNS-ApnsProducer-iOStargetdevicedynamicallyconfiguredviaheader:"CamelApnsTokens"]] ApnsProducer - iOS target device dynamically configured via header: `"CamelApnsTokens"` [source,java] --------------------------------------------------------------------------------------- protected RouteBuilder createRouteBuilder() throws Exception { return new RouteBuilder() { public void configure() throws Exception { from("direct:test") .setHeader(ApnsConstants.HEADER_TOKENS, constant(IOS_DEVICE_TOKEN)) .to("apns:notify"); } } } --------------------------------------------------------------------------------------- [[APNS-ApnsProducer-iOStargetdevicestaticallyconfiguredviauri]] ApnsProducer - iOS target device statically configured via uri [source,java] ------------------------------------------------------------------ protected RouteBuilder createRouteBuilder() throws Exception { return new RouteBuilder() { public void configure() throws Exception { from("direct:test"). to("apns:notify?tokens=" + IOS_DEVICE_TOKEN); } }; } ------------------------------------------------------------------ [[APNS-ApnsConsumer]] ApnsConsumer [source,java] -------------------------------------------------------------------------- from("apns:consumer?initialDelay=10&delay=3600&timeUnit=SECONDS") .to("log:com.apache.camel.component.apns?showAll=true&multiline=true") .to("mock:result"); -------------------------------------------------------------------------- [[APNS-SeeAlso]] See Also ^^^^^^^^ * http://camel.apache.org/component.html[Component] * http://camel.apache.org/endpoint.html[Endpoint] * http://blog.xebia.fr/2010/09/30/creer-un-composant-apache-camel-de-connexion-a-lapns-1-sur-3/[Blog about using APNS (in french)] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-asterisk version: 1.1.24 group: io.fabric8.funktion.connector name: asterisk data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: asterisk spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: asterisk spec: containers: - image: fabric8/connector-asterisk:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: asterisk syntax: asterisk:name title: Asterisk description: The asterisk component is used to interact with Asterisk PBX Server Asterisk PBX Server. label: voip deprecated: false async: false javaType: org.apache.camel.component.asterisk.AsteriskComponent groupId: org.apache.camel artifactId: camel-asterisk version: 2.18.1 componentProperties: {} properties: name: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Logical name hostname: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The hostname of the asterix server password: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: true description: Login password username: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: true description: Login username bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. action: kind: parameter group: producer label: producer type: string javaType: org.apache.camel.component.asterisk.AsteriskActionEnum enum: - QUEUE_STATUS - SIP_PEERS - EXTENSION_STATE deprecated: false secret: false description: What action to perform such as getting queue status sip peers or extension state. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: | [[AsteriskComponent-AsteriskComponent]] Asterisk Component ~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.18* The *asterisk:* component allows you to work easily with an Asterisk PBX Server http://www.asterisk.org/ using https://asterisk-java.org/[asterisk-java] This component help to interface with http://www.voip-info.org/wiki-Asterisk+manager+API[Asterisk Manager Interface] Maven users will need to add the following dependency to their `pom.xml` for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-asterisk x.x.x ------------------------------------------------------------ [[AsteriskComponent-URIformat]] URI format ^^^^^^^^^^ [source,java] ------------------------------------------------------------------------------------------------------------------------- asterisk:name[?options] ------------------------------------------------------------------------------------------------------------------------- [[AsteriskComponent-Options]] Options ^^^^^^^ // component options: START The Asterisk component has no options. // component options: END // endpoint options: START The Asterisk component supports 9 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | name | common | | String | *Required* Logical name | hostname | common | | String | The hostname of the asterix server | password | common | | String | Login password | username | common | | String | Login username | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | action | producer | | AsteriskActionEnum | What action to perform such as getting queue status sip peers or extension state. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END [[Asterisk-Actions]] Action ^^^^^^ Supported actions are: * QUEUE_STATUS, Queue Status * SIP_PEERS, List SIP Peers * EXTENSION_STATE, Check Extension Status - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-atmos version: 1.1.24 group: io.fabric8.funktion.connector name: atmos data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: atmos spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: atmos spec: containers: - image: fabric8/connector-atmos:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: atmos syntax: atmos:name/operation title: Atmos description: The atmos component is used for integrating with EMC's Atomos Storage. label: file,cloud deprecated: false async: false javaType: org.apache.camel.component.atmos.AtmosComponent groupId: org.apache.camel artifactId: camel-atmos version: 2.18.1 componentProperties: {} properties: name: kind: path group: common type: string javaType: java.lang.String deprecated: false secret: false description: Atmos name operation: kind: path group: common required: true type: string javaType: org.apache.camel.component.atmos.util.AtmosOperation enum: - put - del - search - get - move deprecated: false secret: false description: Operation to perform enableSslValidation: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Atmos SSL validation fullTokenId: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Atmos client fullTokenId localPath: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Local path to put files newRemotePath: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: New path on Atmos when moving files query: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Search query on Atmos remotePath: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Where to put files on Atmos secretKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Atmos shared secret uri: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Atomos server uri bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: | [[Atmos-Atmos]] Atmos Component ~~~~~~~~~~~~~~~ *Available as of Camel 2.15* *Camel-Gora* is an http://camel.apache.org/[Apache Camel] component that allows you to work with ViPR object data services using the https://github.com/emcvipr/dataservices-sdk-java[Atmos Client]. [source,java] ------------------------------- from("atmos:foo/get?remotePath=/path").to("mock:test"); ------------------------------- [[Atmos-Options]] Options ~~~~~~~ // component options: START The Atmos component has no options. // component options: END // endpoint options: START The Atmos component supports 14 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | name | common | | String | Atmos name | operation | common | | AtmosOperation | *Required* Operation to perform | enableSslValidation | common | false | boolean | Atmos SSL validation | fullTokenId | common | | String | Atmos client fullTokenId | localPath | common | | String | Local path to put files | newRemotePath | common | | String | New path on Atmos when moving files | query | common | | String | Search query on Atmos | remotePath | common | | String | Where to put files on Atmos | secretKey | common | | String | Atmos shared secret | uri | common | | String | Atomos server uri | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END [[Atmos-Dependencies]] Dependencies ^^^^^^^^^^^^ To use Atmos in your camel routes you need to add the dependency on *camel-atmos* which implements this data format. If you use maven you could just add the following to your pom.xml, substituting the version number for the latest & greatest release (see link:download.html[the download page for the latest versions]). [source,xml] ---------------------------------------------------------- org.apache.camel camel-atmos x.x.x ---------------------------------------------------------- - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-atmosphere-websocket version: 1.1.24 group: io.fabric8.funktion.connector name: atmosphere-websocket data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: atmosphere-websocket spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: atmosphere-websocket spec: containers: - image: fabric8/connector-atmosphere-websocket:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: atmosphere-websocket extendsScheme: servlet syntax: atmosphere-websocket:servicePath title: Atmosphere Websocket description: To exchange data with external Websocket clients using Atmosphere. label: websocket deprecated: false async: false javaType: org.apache.camel.component.atmosphere.websocket.WebsocketComponent groupId: org.apache.camel artifactId: camel-atmosphere-websocket version: 2.18.1 componentProperties: servletName: kind: property type: string javaType: java.lang.String deprecated: false secret: false description: Default name of servlet to use. The default name is CamelServlet. httpRegistry: kind: property type: object javaType: org.apache.camel.component.servlet.HttpRegistry deprecated: false secret: false description: To use a custom org.apache.camel.component.servlet.HttpRegistry. attachmentMultipartBinding: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to automatic bind multipart/form-data as attachments on the Camel Exchange. This is turn off by default as this may require servlet specific configuration to enable this when using Servlet's. httpBinding: kind: property type: object javaType: org.apache.camel.http.common.HttpBinding deprecated: false secret: false description: To use a custom HttpBinding to control the mapping between Camel message and HttpClient. httpConfiguration: kind: property type: object javaType: org.apache.camel.http.common.HttpConfiguration deprecated: false secret: false description: To use the shared HttpConfiguration as base configuration. allowJavaSerializedObject: kind: property type: boolean javaType: boolean deprecated: false secret: false description: Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. headerFilterStrategy: kind: property type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. properties: servicePath: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Name of websocket endpoint chunked: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If this option is false the Servlet will disable the HTTP streaming and set the content-length header on the response disableStreamCache: kind: parameter group: common label: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Determines whether or not the raw input stream from Servlet is cached or not (Camel will read the stream into a in memory/overflow to file Stream caching) cache. By default Camel will cache the Servlet input stream to support reading it multiple times to ensure it Camel can retrieve all data from the stream. However you can set this option to true when you for example need to access the raw stream such as streaming it directly to a file or other persistent store. DefaultHttpBinding will copy the request input stream into a stream cache and put it into message body if this option is false to support reading the stream multiple times. If you use Servlet to bridge/proxy an endpoint then consider enabling this option to improve performance in case you do not need to read the message payload multiple times. The http/http4 producer will by default cache the response body stream. If setting this option to true then the producers will not cache the response body stream but use the response stream as-is as the message body. headerFilterStrategy: kind: parameter group: common type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to filter header to and from Camel message. httpBinding: kind: parameter group: common type: object javaType: org.apache.camel.http.common.HttpBinding deprecated: false secret: false description: To use a custom HttpBinding to control the mapping between Camel message and HttpClient. sendToAll: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to send to all (broadcast) or send to a single receiver. transferException: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type. On the producer side the exception will be deserialized and thrown as is instead of the HttpOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. useStreaming: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: To enable streaming to send data as multiple text fragments. async: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Configure the consumer to work in async mode bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. eagerCheckContentAvailable: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to eager check whether the HTTP requests has content if the content-length header is 0 or not present. This can be turned on in case HTTP clients do not send streamed data. httpMethodRestrict: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Used to only allow consuming if the HttpMethod matches such as GET/POST/PUT etc. Multiple methods can be specified separated by comma. matchOnUriPrefix: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether or not the consumer should try to find a target consumer by matching the URI prefix if no exact match is found. optionsEnabled: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether to enable HTTP OPTIONS for this Servlet consumer. By default OPTIONS is turned off. responseBufferSize: kind: parameter group: consumer label: consumer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To use a custom buffer size on the javax.servlet.ServletResponse. servletName: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false defaultValue: CamelServlet description: Name of the servlet to use traceEnabled: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether to enable HTTP TRACE for this Servlet consumer. By default TRACE is turned off. attachmentMultipartBinding: kind: parameter group: consumer (advanced) label: consumer,advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether to automatic bind multipart/form-data as attachments on the Camel Exchange. This is turn off by default as this may require servlet specific configuration to enable this when using Servlet's. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. authMethodPriority: kind: parameter group: producer label: producer type: string javaType: java.lang.String enum: - Basic - Digest - NTLM deprecated: false secret: false description: Authentication method for proxy either as Basic Digest or NTLM. bridgeEndpoint: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If the option is true HttpProducer will ignore the Exchange.HTTP_URI header and use the endpoint's URI for request. You may also set the option throwExceptionOnFailure to be false to let the HttpProducer send all the fault response back. connectionClose: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Specifies whether a Connection Close header must be added to HTTP Request. By default connectionClose is false. copyHeaders: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If this option is true then IN exchange headers will be copied to OUT exchange headers according to copy strategy. Setting this to false allows to only include the headers from the HTTP response (not propagating IN headers). ignoreResponseBody: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If this option is true The http producer won't read response body and cache the input stream okStatusCodeRange: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false defaultValue: 200-299 description: The status codes which is considered a success response. The values are inclusive. The range must be defined as from-to with the dash included. preserveHostHeader: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If the option is true HttpProducer will set the Host header to the value contained in the current exchange Host header useful in reverse proxy applications where you want the Host header received by the downstream server to reflect the URL called by the upstream client this allows applications which use the Host header to generate accurate URL's for a proxied service proxyHost: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false description: The proxy host name proxyPort: kind: parameter group: producer label: producer type: integer javaType: int deprecated: false secret: false description: The proxy port number throwExceptionOnFailure: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Option to disable throwing the HttpOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. urlRewrite: kind: parameter group: producer (advanced) label: producer,advanced type: object javaType: org.apache.camel.http.common.UrlRewrite deprecated: false secret: false description: Refers to a custom org.apache.camel.component.http.UrlRewrite which allows you to rewrite urls when you bridge/proxy endpoints. See more details at http://camel.apache.org/urlrewrite.html mapHttpMessageBody: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If this option is true then IN exchange Body of the exchange will be mapped to HTTP body. Setting this to false will avoid the HTTP mapping. mapHttpMessageFormUrlEncodedBody: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If this option is true then IN exchange Form Encoded body of the exchange will be mapped to HTTP. Setting this to false will avoid the HTTP Form Encoded body mapping. mapHttpMessageHeaders: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: If this option is true then IN exchange Headers of the exchange will be mapped to HTTP headers. Setting this to false will avoid the HTTP Headers mapping. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[Atmosphere-Websocket-AtmosphereWebsocketServletComponent]] Atmosphere Websocket Servlet Component ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.14* The??*atmosphere-websocket:*??component provides Websocket based??link:endpoint.html[endpoints]??for a servlet communicating with external clients over Websocket (as a servlet accepting websocket connections from external clients). + The component uses the link:servlet.html[SERVLET] component and uses the??https://github.com/Atmosphere/atmosphere[Atmosphere]??library to support the Websocket transport in various Servlet containers (e..g., Jetty, Tomcat, ...). Unlike the https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=39621544[Websocket] component that starts the embedded Jetty server, this component uses the servlet provider of the container. Maven users will need to add the following dependency to their??`pom.xml`??for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-atmosphere-websocket x.x.x ------------------------------------------------------------ [[Atmosphere-Websocket-Options]] Atmosphere-Websocket Options ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // component options: START The Atmosphere Websocket component supports 7 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | servletName | String | Default name of servlet to use. The default name is CamelServlet. | httpRegistry | HttpRegistry | To use a custom org.apache.camel.component.servlet.HttpRegistry. | attachmentMultipartBinding | boolean | Whether to automatic bind multipart/form-data as attachments on the Camel Exchange. This is turn off by default as this may require servlet specific configuration to enable this when using Servlet's. | httpBinding | HttpBinding | To use a custom HttpBinding to control the mapping between Camel message and HttpClient. | httpConfiguration | HttpConfiguration | To use the shared HttpConfiguration as base configuration. | allowJavaSerializedObject | boolean | Whether to allow java serialization when a request uses context-type=application/x-java-serialized-object This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | headerFilterStrategy | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. |======================================================================= {% endraw %} // component options: END // endpoint options: START The Atmosphere Websocket component supports 35 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | servicePath | common | | String | *Required* Name of websocket endpoint | chunked | common | true | boolean | If this option is false the Servlet will disable the HTTP streaming and set the content-length header on the response | disableStreamCache | common | false | boolean | Determines whether or not the raw input stream from Servlet is cached or not (Camel will read the stream into a in memory/overflow to file Stream caching) cache. By default Camel will cache the Servlet input stream to support reading it multiple times to ensure it Camel can retrieve all data from the stream. However you can set this option to true when you for example need to access the raw stream such as streaming it directly to a file or other persistent store. DefaultHttpBinding will copy the request input stream into a stream cache and put it into message body if this option is false to support reading the stream multiple times. If you use Servlet to bridge/proxy an endpoint then consider enabling this option to improve performance in case you do not need to read the message payload multiple times. The http/http4 producer will by default cache the response body stream. If setting this option to true then the producers will not cache the response body stream but use the response stream as-is as the message body. | headerFilterStrategy | common | | HeaderFilterStrategy | To use a custom HeaderFilterStrategy to filter header to and from Camel message. | httpBinding | common | | HttpBinding | To use a custom HttpBinding to control the mapping between Camel message and HttpClient. | sendToAll | common | false | boolean | Whether to send to all (broadcast) or send to a single receiver. | transferException | common | false | boolean | If enabled and an Exchange failed processing on the consumer side and if the caused Exception was send back serialized in the response as a application/x-java-serialized-object content type. On the producer side the exception will be deserialized and thrown as is instead of the HttpOperationFailedException. The caused exception is required to be serialized. This is by default turned off. If you enable this then be aware that Java will deserialize the incoming data from the request to Java and that can be a potential security risk. | useStreaming | common | false | boolean | To enable streaming to send data as multiple text fragments. | async | consumer | false | boolean | Configure the consumer to work in async mode | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | eagerCheckContentAvailable | consumer | false | boolean | Whether to eager check whether the HTTP requests has content if the content-length header is 0 or not present. This can be turned on in case HTTP clients do not send streamed data. | httpMethodRestrict | consumer | | String | Used to only allow consuming if the HttpMethod matches such as GET/POST/PUT etc. Multiple methods can be specified separated by comma. | matchOnUriPrefix | consumer | false | boolean | Whether or not the consumer should try to find a target consumer by matching the URI prefix if no exact match is found. | optionsEnabled | consumer | false | boolean | Specifies whether to enable HTTP OPTIONS for this Servlet consumer. By default OPTIONS is turned off. | responseBufferSize | consumer | | Integer | To use a custom buffer size on the javax.servlet.ServletResponse. | servletName | consumer | CamelServlet | String | Name of the servlet to use | traceEnabled | consumer | false | boolean | Specifies whether to enable HTTP TRACE for this Servlet consumer. By default TRACE is turned off. | attachmentMultipartBinding | consumer (advanced) | false | boolean | Whether to automatic bind multipart/form-data as attachments on the Camel Exchange. This is turn off by default as this may require servlet specific configuration to enable this when using Servlet's. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | authMethodPriority | producer | | String | Authentication method for proxy either as Basic Digest or NTLM. | bridgeEndpoint | producer | false | boolean | If the option is true HttpProducer will ignore the Exchange.HTTP_URI header and use the endpoint's URI for request. You may also set the option throwExceptionOnFailure to be false to let the HttpProducer send all the fault response back. | connectionClose | producer | false | boolean | Specifies whether a Connection Close header must be added to HTTP Request. By default connectionClose is false. | copyHeaders | producer | true | boolean | If this option is true then IN exchange headers will be copied to OUT exchange headers according to copy strategy. Setting this to false allows to only include the headers from the HTTP response (not propagating IN headers). | ignoreResponseBody | producer | false | boolean | If this option is true The http producer won't read response body and cache the input stream | okStatusCodeRange | producer | 200-299 | String | The status codes which is considered a success response. The values are inclusive. The range must be defined as from-to with the dash included. | preserveHostHeader | producer | false | boolean | If the option is true HttpProducer will set the Host header to the value contained in the current exchange Host header useful in reverse proxy applications where you want the Host header received by the downstream server to reflect the URL called by the upstream client this allows applications which use the Host header to generate accurate URL's for a proxied service | proxyHost | producer | | String | The proxy host name | proxyPort | producer | | int | The proxy port number | throwExceptionOnFailure | producer | true | boolean | Option to disable throwing the HttpOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code. | urlRewrite | producer (advanced) | | UrlRewrite | Refers to a custom org.apache.camel.component.http.UrlRewrite which allows you to rewrite urls when you bridge/proxy endpoints. See more details at http://camel.apache.org/urlrewrite.html | mapHttpMessageBody | advanced | true | boolean | If this option is true then IN exchange Body of the exchange will be mapped to HTTP body. Setting this to false will avoid the HTTP mapping. | mapHttpMessageFormUrlEncodedBody | advanced | true | boolean | If this option is true then IN exchange Form Encoded body of the exchange will be mapped to HTTP. Setting this to false will avoid the HTTP Form Encoded body mapping. | mapHttpMessageHeaders | advanced | true | boolean | If this option is true then IN exchange Headers of the exchange will be mapped to HTTP headers. Setting this to false will avoid the HTTP Headers mapping. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END [[Atmosphere-Websocket-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ----------------------------------------------- atmosphere-websocket:///relative path[?options] ----------------------------------------------- [[Atmosphere-Websocket-ReadingandWritingDataoverWebsocket]] Reading and Writing Data over Websocket ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ An atmopshere-websocket endpoint can either write data to the socket or read from the socket, depending on whether the endpoint is configured as the producer or the consumer, respectively. [[Atmosphere-Websocket-ConfiguringURItoReadorWriteData]] Configuring URI to Read or Write Data ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ In the route below, Camel will read from the specified websocket connection. [source,java] ------------------------------------------- from("atmosphere-websocket:///servicepath") .to("direct:next"); ------------------------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ In the route below, Camel will read from the specified websocket connection. [source,java] --------------------------------------------------- from("direct:next") .to("atmosphere-websocket:///servicepath"); --------------------------------------------------- And the equivalent Spring sample: [source,xml] ------------------------------------------------------------ ------------------------------------------------------------ ?? [[Atmosphere-Websocket-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:servlet.html[SERVLET] * link:ahc-ws.html[AHC-WS] * https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=39621544[Websocket] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-atom version: 1.1.24 group: io.fabric8.funktion.connector name: atom data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: atom spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: atom spec: containers: - image: fabric8/connector-atom:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: atom syntax: atom:feedUri title: Atom description: The atom component is used for consuming Atom RSS feeds. label: rss deprecated: false async: false consumerOnly: true lenientProperties: true javaType: org.apache.camel.component.atom.AtomComponent groupId: org.apache.camel artifactId: camel-atom version: 2.18.1 componentProperties: {} properties: feedUri: kind: path group: consumer required: true type: string javaType: java.lang.String deprecated: false secret: false description: The URI to the feed to poll. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. feedHeader: kind: parameter group: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Sets whether to add the feed object as a header filter: kind: parameter group: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Sets whether to use filtering or not of the entries. lastUpdate: kind: parameter group: consumer type: string javaType: java.util.Date deprecated: false secret: false description: Sets the timestamp to be used for filtering entries from the atom feeds. This options is only in conjunction with the splitEntries. password: kind: parameter group: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Sets the password to be used for basic authentication when polling from a HTTP feed sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. sortEntries: kind: parameter group: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether to sort entries by published date. Only works when splitEntries = true. splitEntries: kind: parameter group: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Sets whether or not entries should be sent individually or whether the entire feed should be sent as a single message throttleEntries: kind: parameter group: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Sets whether all entries identified in a single feed poll should be delivered immediately. If true only one entry is processed per consumer.delay. Only applicable when splitEntries = true. username: kind: parameter group: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Sets the username to be used for basic authentication when polling from a HTTP feed exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[Atom-AtomComponent]] Atom Component ~~~~~~~~~~~~~~ The *atom:* component is used for polling Atom feeds. Camel will poll the feed every 60 seconds by default. + *Note:* The component currently only supports polling (consuming) feeds. Maven users will need to add the following dependency to their `pom.xml` for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-atom x.x.x ------------------------------------------------------------ [[Atom-URIformat]] URI format ^^^^^^^^^^ [source,java] ------------------------ atom://atomUri[?options] ------------------------ Where *atomUri* is the URI to the Atom feed to poll. [[Atom-Options]] Options ^^^^^^^ // component options: START The Atom component has no options. // component options: END // endpoint options: START The Atom component supports 28 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | feedUri | consumer | | String | *Required* The URI to the feed to poll. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | feedHeader | consumer | true | boolean | Sets whether to add the feed object as a header | filter | consumer | true | boolean | Sets whether to use filtering or not of the entries. | lastUpdate | consumer | | Date | Sets the timestamp to be used for filtering entries from the atom feeds. This options is only in conjunction with the splitEntries. | password | consumer | | String | Sets the password to be used for basic authentication when polling from a HTTP feed | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | sortEntries | consumer | false | boolean | Sets whether to sort entries by published date. Only works when splitEntries = true. | splitEntries | consumer | true | boolean | Sets whether or not entries should be sent individually or whether the entire feed should be sent as a single message | throttleEntries | consumer | true | boolean | Sets whether all entries identified in a single feed poll should be delivered immediately. If true only one entry is processed per consumer.delay. Only applicable when splitEntries = true. | username | consumer | | String | Sets the username to be used for basic authentication when polling from a HTTP feed | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END You can append query options to the URI in the following format, `?option=value&option=value&...` [[Atom-Exchangedataformat]] Exchange data format ^^^^^^^^^^^^^^^^^^^^ Camel will set the In body on the returned `Exchange` with the entries. Depending on the `splitEntries` flag Camel will either return one `Entry` or a `List`. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Option |Value |Behavior |`splitEntries` |`true` |Only a single entry from the currently being processed feed is set: `exchange.in.body(Entry)` |`splitEntries` |`false` |The entire list of entries from the feed is set: `exchange.in.body(List)` |======================================================================= Camel can set the `Feed` object on the In header (see `feedHeader` option to disable this): [[Atom-MessageHeaders]] Message Headers ^^^^^^^^^^^^^^^ Camel atom uses these headers. [width="100%",cols="10%,90%",options="header",] |======================================================================= |Header |Description |`CamelAtomFeed` |When consuming the `org.apache.abdera.model.Feed` object is set to this header. |======================================================================= [[Atom-Samples]] Samples ^^^^^^^ In this sample we poll James Strachan's blog. [source,java] --------------------------------------------------------------------------------- from("atom://http://macstrac.blogspot.com/feeds/posts/default").to("seda:feeds"); --------------------------------------------------------------------------------- In this sample we want to filter only good blogs we like to a SEDA queue. The sample also shows how to setup Camel standalone, not running in any Container or using Spring. [[Atom-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:rss.html[RSS] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-avro version: 1.1.24 group: io.fabric8.funktion.connector name: avro data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: avro spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: avro spec: containers: - image: fabric8/connector-avro:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: avro syntax: avro:transport:host:port/messageName title: Avro description: Working with Apache Avro for data serialization. label: messaging,transformation deprecated: false async: true javaType: org.apache.camel.component.avro.AvroComponent groupId: org.apache.camel artifactId: camel-avro version: 2.18.1 componentProperties: configuration: kind: property type: object javaType: org.apache.camel.component.avro.AvroConfiguration deprecated: false secret: false description: To use a shared AvroConfiguration to configure options once properties: transport: kind: path group: common required: true type: string javaType: org.apache.camel.component.avro.AvroTransport enum: - http - netty deprecated: false secret: false description: Transport to use port: kind: path group: common required: true type: integer javaType: int deprecated: false secret: false description: Port number to use host: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Hostname to use messageName: kind: path group: common type: string javaType: java.lang.String deprecated: false secret: false description: The name of the message to send. protocol: kind: parameter group: common type: object javaType: org.apache.avro.Protocol deprecated: false secret: false description: Avro protocol to use protocolClassName: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Avro protocol to use defined by the FQN class name protocolLocation: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Avro protocol location reflectionProtocol: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If protocol object provided is reflection protocol. Should be used only with protocol parameter because for protocolClassName protocol type will be auto detected singleParameter: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If true consumer parameter won't be wrapped into array. Will fail if protocol specifies more then 1 parameter for the message uriAuthority: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Authority to use (username and password) bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: | [[avro-AvroComponent]] Avro Component ~~~~~~~~~~~~~~ *Available as of Camel 2.10* This component provides a dataformat for avro, which allows serialization and deserialization of messages using Apache Avro's binary dataformat. Moreover, it provides support for Apache Avro's rpc, by providing producers and consumers endpoint for using avro over netty or http. Maven users will need to add the following dependency to their `pom.xml` for this component: [source,xml] ------------------------------------------------------------ org.apache.camel camel-avro x.x.x ------------------------------------------------------------ [[avro-ApacheAvroOverview]] Apache Avro Overview ^^^^^^^^^^^^^^^^^^^^ Avro allows you to define message types and a protocol using a json like format and then generate java code for the specified types and messages. An example of how a schema looks like is below. [source,xml] ------------------------------------------------------------------------------------------ {"namespace": "org.apache.camel.avro.generated", "protocol": "KeyValueProtocol", "types": [ {"name": "Key", "type": "record", "fields": [ {"name": "key", "type": "string"} ] }, {"name": "Value", "type": "record", "fields": [ {"name": "value", "type": "string"} ] } ], "messages": { "put": { "request": [{"name": "key", "type": "Key"}, {"name": "value", "type": "Value"} ], "response": "null" }, "get": { "request": [{"name": "key", "type": "Key"}], "response": "Value" } } } ------------------------------------------------------------------------------------------ You can easily generate classes from a schema, using maven, ant etc. More details can be found at the http://avro.apache.org/docs/current/[Apache Avro documentation]. However, it doesn't enforce a schema first approach and you can create schema for your existing classes. *Since 2.12* you can use existing protocol interfaces to make RCP calls. You should use interface for the protocol itself and POJO beans or primitive/String classes for parameter and result types. Here is an example of the class that corresponds to schema above: [source,java] -------------------------------------------------------------- package org.apache.camel.avro.reflection; public interface KeyValueProtocol { void put(String key, Value value); Value get(String key); } class Value { private String value; public String getValue() { return value; } public void setValue(String value) { this.value = value; } } -------------------------------------------------------------- _Note: Existing classes can be used only for RPC (see below), not in data format._ [[avro-UsingtheAvrodataformat]] Using the Avro data format ^^^^^^^^^^^^^^^^^^^^^^^^^^ Using the avro data format is as easy as specifying that the class that you want to marshal or unmarshal in your route. [source,xml] -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- An alternative can be to specify the dataformat inside the context and reference it from your route. [source,xml] -------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------- In the same manner you can umarshal using the avro data format. [[avro-UsingAvroRPCinCamel]] Using Avro RPC in Camel ^^^^^^^^^^^^^^^^^^^^^^^ As mentioned above Avro also provides RPC support over multiple transports such as http and netty. Camel provides consumers and producers for these two transports. [source,java] ---------------------------------------- avro:[transport]:[host]:[port][?options] ---------------------------------------- The supported transport values are currently http or netty. *Since 2.12* you can specify message name right in the URI: [source,java] ------------------------------------------------------ avro:[transport]:[host]:[port][/messageName][?options] ------------------------------------------------------ For consumers this allows you to have multiple routes attached to the same socket. Dispatching to correct route will be done by the avro component automatically. Route with no messageName specified (if any) will be used as default. When using camel producers for avro ipc, the "in" message body needs to contain the parameters of the operation specified in the avro protocol. The response will be added in the body of the "out" message. In a similar manner when using camel avro consumers for avro ipc, the requests parameters will be placed inside the "in" message body of the created exchange and once the exchange is processed the body of the "out" message will be send as a response. *Note:* By default consumer parameters are wrapped into array. If you've got only one parameter, *since 2.12* you can use `singleParameter` URI option to receive it direcly in the "in" message body without array wrapping. [[avro-AvroRPCURIOptions]] Avro RPC URI Options ^^^^^^^^^^^^^^^^^^^^ // component options: START The Avro component supports 1 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | configuration | AvroConfiguration | To use a shared AvroConfiguration to configure options once |======================================================================= {% endraw %} // component options: END // endpoint options: START The Avro component supports 14 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | transport | common | | AvroTransport | *Required* Transport to use | port | common | | int | *Required* Port number to use | host | common | | String | *Required* Hostname to use | messageName | common | | String | The name of the message to send. | protocol | common | | Protocol | Avro protocol to use | protocolClassName | common | | String | Avro protocol to use defined by the FQN class name | protocolLocation | common | | String | Avro protocol location | reflectionProtocol | common | false | boolean | If protocol object provided is reflection protocol. Should be used only with protocol parameter because for protocolClassName protocol type will be auto detected | singleParameter | common | false | boolean | If true consumer parameter won't be wrapped into array. Will fail if protocol specifies more then 1 parameter for the message | uriAuthority | common | | String | Authority to use (username and password) | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END [[avro-AvroRPCHeaders]] Avro RPC Headers ^^^^^^^^^^^^^^^^ [width="100%",cols="20%,80%",options="header",] |======================================================================= |Name |Description |`CamelAvroMessageName` |The name of the message to send. In consumer overrides message name from URI (if any) |======================================================================= [[avro-Examples]] Examples ^^^^^^^^ An example of using camel avro producers via http: [source,xml] --------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------- In the example above you need to fill `CamelAvroMessageName` header. *Since 2.12* you can use following syntax to call constant messages: [source,xml] ------------------------------------------------------------------------------------------------------------------------------- ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ------------------------------------------------------------------------------------------------------------------------------- An example of consuming messages using camel avro consumers via netty: [source,xml] ------------------------------------------------------------------------------------------------------------------------------ ${in.headers.CamelAvroMessageName == 'put'} ${in.headers.CamelAvroMessageName == 'get'} ------------------------------------------------------------------------------------------------------------------------------ *Since 2.12* you can set up two distinct routes to perform the same task: [source,xml] ------------------------------------------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------- In the example above, get takes only one parameter, so `singleParameter` is used and `getProcessor` will receive Value class directly in body, while `putProcessor` will receive an array of size 2 with String key and Value value filled as array contents. - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-cw version: 1.1.24 group: io.fabric8.funktion.connector name: aws-cw data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-cw spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-cw spec: containers: - image: fabric8/connector-aws-cw:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-cw syntax: aws-cw:namespace title: AWS CloudWatch description: The aws-cw component is used for sending metrics to an Amazon CloudWatch. label: cloud,monitoring deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.cw.CwComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: namespace: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: The metric namespace accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonCwClient: kind: parameter group: producer type: object javaType: com.amazonaws.services.cloudwatch.AmazonCloudWatch deprecated: false secret: false description: To use the AmazonCloudWatch as the client amazonCwEndpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-CW client wants to work with. name: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The metric name proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key timestamp: kind: parameter group: producer type: string javaType: java.util.Date deprecated: false secret: false description: The metric timestamp unit: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The metric unit value: kind: parameter group: producer type: number javaType: java.lang.Double deprecated: false secret: false description: The metric value synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[AWS-CW-CWComponent]] CW Component ~~~~~~~~~~~~ *Available as of Camel 2.11 The CW component allows messages to be sent to an http://aws.amazon.com/cloudwatch/[Amazon CloudWatch] metrics. The implementation of the Amazon API is provided by the??http://aws.amazon.com/sdkforjava/[AWS SDK]. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon CloudWatch. More information are available at http://aws.amazon.com/cloudwatch/[Amazon CloudWatch]. [[AWS-CW-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ---------------------------- aws-cw://namespace[?options] ---------------------------- The metrics will be created if they don't already exists. + You can append query options to the URI in the following format, `?options=value&option2=value&...` [[AWS-CW-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS CloudWatch component has no options. // component options: END // endpoint options: START The AWS CloudWatch component supports 12 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | namespace | producer | | String | *Required* The metric namespace | accessKey | producer | | String | Amazon AWS Access Key | amazonCwClient | producer | | AmazonCloudWatch | To use the AmazonCloudWatch as the client | amazonCwEndpoint | producer | | String | The region with which the AWS-CW client wants to work with. | name | producer | | String | The metric name | proxyHost | producer | | String | To define a proxy host when instantiating the SQS client | proxyPort | producer | | Integer | To define a proxy port when instantiating the SQS client | secretKey | producer | | String | Amazon AWS Secret Key | timestamp | producer | | Date | The metric timestamp | unit | producer | | String | The metric unit | value | producer | | Double | The metric value | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END Required CW component options You have to provide the amazonCwClient in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/cloudwatch/[Amazon's CloudWatch]. [[AWS-CW-Usage]] Usage ^^^^^ [[AWS-CW-MessageheadersevaluatedbytheCWproducer]] Message headers evaluated by the CW producer ++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsCwMetricName` |`String` |The Amazon CW metric name. |`CamelAwsCwMetricValue` |`Double` |The Amazon CW metric value. |`CamelAwsCwMetricUnit` |`String` |The Amazon CW metric unit. |`CamelAwsCwMetricNamespace` |`String` |The Amazon CW metric namespace. |`CamelAwsCwMetricTimestamp` |`Date` |The Amazon CW metric timestamp. |`CamelAwsCwMetricDimensionName` |`String` |*Camel 2.12:* The Amazon CW metric dimension name. |`CamelAwsCwMetricDimensionValue` |`String` |*Camel 2.12:* The Amazon CW metric dimension value. |`CamelAwsCwMetricDimensions` |`Map` |*Camel 2.12:* A map of dimension names and dimension values. |======================================================================= [[AWS-CW-AdvancedAmazonCloudWatchconfiguration]] Advanced AmazonCloudWatch configuration +++++++++++++++++++++++++++++++++++++++ If you need more control over the `AmazonCloudWatch` instance configuration you can create your own instance and refer to it from the URI: [source,java] ------------------------------------------------- from("direct:start") .to("aws-cw://namepsace?amazonCwClient=#client"); ------------------------------------------------- The `#client` refers to a `AmazonCloudWatch` in the link:registry.html[Registry]. For example if your Camel Application is running behind a firewall: [source,java] ------------------------------------------------------------------------------------------ AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonCloudWatch client = new AmazonCloudWatchClient(awsCredentials, clientConfiguration); registry.bind("client", client); ------------------------------------------------------------------------------------------ [[AWS-CW-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.10 or higher). [[AWS-CW-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-ddb version: 1.1.24 group: io.fabric8.funktion.connector name: aws-ddb data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ddb spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ddb spec: containers: - image: fabric8/connector-aws-ddb:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-ddb syntax: aws-ddb:tableName title: AWS DynamoDB description: The aws-ddb component is used for storing and retrieving data from Amazon's DynamoDB service. label: cloud,database,nosql deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.ddb.DdbComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: tableName: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: The name of the table currently worked with. accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonDDBClient: kind: parameter group: producer type: object javaType: com.amazonaws.services.dynamodbv2.AmazonDynamoDB deprecated: false secret: false description: To use the AmazonDynamoDB as the client amazonDdbEndpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-DDB client wants to work with. consistentRead: kind: parameter group: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Determines whether or not strong consistency should be enforced when data is read. keyAttributeName: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Attribute name when creating table keyAttributeType: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Attribute type when creating table operation: kind: parameter group: producer type: string javaType: org.apache.camel.component.aws.ddb.DdbOperations enum: - BatchGetItems - DeleteItem - DeleteTable - DescribeTable - GetItem - PutItem - Query - Scan - UpdateItem - UpdateTable deprecated: false secret: false defaultValue: PutItem description: What operation to perform proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client readCapacity: kind: parameter group: producer type: integer javaType: java.lang.Long deprecated: false secret: false description: The provisioned throughput to reserve for reading resources from your table secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key writeCapacity: kind: parameter group: producer type: integer javaType: java.lang.Long deprecated: false secret: false description: The provisioned throughput to reserved for writing resources to your table synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: "[[AWS-DDB-DDBComponent]]\nDDB Component\n~~~~~~~~~~~~~\n\n\ *Available as of Camel 2.10*\n\nThe DynamoDB component supports storing and\ \ retrieving data from/to\nhttp://aws.amazon.com/dynamodb[Amazon's DynamoDB]\ \ service.\n\nPrerequisites\n\nYou must have a valid Amazon Web Services developer\ \ account, and be\nsigned up to use Amazon DynamoDB. More information are available\ \ at\nhttp://aws.amazon.com/dynamodb[Amazon DynamoDB].\n\n[[AWS-DDB-URIFormat]]\n\ URI Format\n^^^^^^^^^^\n\n[source,java]\n------------------------------\naws-ddb://domainName[?options]\n\ ------------------------------\n\nYou can append query options to the URI in\ \ the following format,\n?options=value&option2=value&...\n\n[[AWS-DDB-URIOptions]]\n\ URI Options\n^^^^^^^^^^^\n\n\n// component options: START\nThe AWS DynamoDB\ \ component has no options.\n// component options: END\n\n\n\n\n// endpoint\ \ options: START\nThe AWS DynamoDB component supports 14 endpoint options which\ \ are listed below:\n\n{% raw %}\n[width=\"100%\",cols=\"2,1,1m,1m,5\",options=\"\ header\"]\n|=======================================================================\n\ | Name | Group | Default | Java Type | Description\n| tableName | producer |\ \ | String | *Required* The name of the table currently worked with.\n| accessKey\ \ | producer | | String | Amazon AWS Access Key\n| amazonDDBClient | producer\ \ | | AmazonDynamoDB | To use the AmazonDynamoDB as the client\n| amazonDdbEndpoint\ \ | producer | | String | The region with which the AWS-DDB client wants to\ \ work with.\n| consistentRead | producer | false | boolean | Determines whether\ \ or not strong consistency should be enforced when data is read.\n| keyAttributeName\ \ | producer | | String | Attribute name when creating table\n| keyAttributeType\ \ | producer | | String | Attribute type when creating table\n| operation |\ \ producer | PutItem | DdbOperations | What operation to perform\n| proxyHost\ \ | producer | | String | To define a proxy host when instantiating the SQS\ \ client\n| proxyPort | producer | | Integer | To define a proxy port when\ \ instantiating the SQS client\n| readCapacity | producer | | Long | The provisioned\ \ throughput to reserve for reading resources from your table\n| secretKey |\ \ producer | | String | Amazon AWS Secret Key\n| writeCapacity | producer |\ \ | Long | The provisioned throughput to reserved for writing resources to\ \ your table\n| synchronous | advanced | false | boolean | Sets whether synchronous\ \ processing should be strictly used or Camel is allowed to use asynchronous\ \ processing (if supported).\n|=======================================================================\n\ {% endraw %}\n// endpoint options: END\n\n\n\nRequired DDB component options\n\ \nYou have to provide the amazonDDBClient in the\nlink:registry.html[Registry]\ \ or your accessKey and secretKey to access\nthe http://aws.amazon.com/dynamodb[Amazon's\ \ DynamoDB].\n\n[[AWS-DDB-Usage]]\nUsage\n^^^^^\n\n[[AWS-DDB-MessageheadersevaluatedbytheDDBproducer]]\n\ Message headers evaluated by the DDB producer\n+++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbBatchItems` |`Map`\ \ |A map of the table name and corresponding items to get by primary key.\n\n\ |`CamelAwsDdbTableName` |`String` |Table Name for this operation.\n\n|`CamelAwsDdbKey`\ \ |`Key` |The primary key that uniquely identifies each item in a table. *From\ \ Camel 2.16.0 the type of this header is Map and not\ \ Key*\n\n|`CamelAwsDdbReturnValues` |`String` |Use this parameter if you want\ \ to get the attribute name-value pairs\nbefore or after they are modified(NONE,\ \ ALL_OLD, UPDATED_OLD, ALL_NEW,\nUPDATED_NEW).\n\n|`CamelAwsDdbUpdateCondition`\ \ |`Map` |Designates an attribute for a conditional\ \ modification.\n\n|`CamelAwsDdbAttributeNames` |`Collection` |If attribute\ \ names are not specified then all attributes will be\nreturned.\n\n|`CamelAwsDdbConsistentRead`\ \ |`Boolean` |If set to true, then a consistent read is issued, otherwise eventually\n\ consistent is used.\n\n|`CamelAwsDdbItem` |`Map` |A\ \ map of the attributes for the item, and must include the primary key\nvalues\ \ that define the item.\n\n|`CamelAwsDdbExactCount` |`Boolean` |If set to true,\ \ Amazon DynamoDB returns a total number of items that\nmatch the query parameters,\ \ instead of a list of the matching items and\ntheir attributes. *From Camel\ \ 2.16.0 this header doesn't exist anymore.*\n\n|`CamelAwsDdbKeyConditions`\ \ |`Map` |*From Camel 2.16.0*. This header specify the selection\ \ criteria for the\nquery, and merge together the two old headers *CamelAwsDdbHashKeyValue*\n\ and *CamelAwsDdbScanRangeKeyCondition*\n\n|`CamelAwsDdbStartKey` |`Key` |Primary\ \ key of the item from which to continue an earlier query.\n\n|`CamelAwsDdbHashKeyValue`\ \ |`AttributeValue` |Value of the hash component of the composite primary key.\n\ *From Camel 2.16.0 this header doesn't exist anymore.*\n\n|`CamelAwsDdbLimit`\ \ |`Integer` |The maximum number of items to return.\n\n|`CamelAwsDdbScanRangeKeyCondition`\ \ |`Condition` |A container for the attribute values and comparison operators\ \ to use for\nthe query.*From Camel 2.16.0 this header doesn't exist anymore.*\n\ \n|`CamelAwsDdbScanIndexForward` |`Boolean` |Specifies forward or backward traversal\ \ of the index.\n\n|`CamelAwsDdbScanFilter` |`Map` |Evaluates\ \ the scan results and returns only the desired values.\n\n|`CamelAwsDdbUpdateValues`\ \ |`Map` |Map of attribute name to the new value\ \ and action for the update.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringBatchGetItemsoperation]]\nMessage headers\ \ set during BatchGetItems operation\n++++++++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbBatchResponse` |`Map`\ \ |Table names and the respective item attributes from the tables.\n\n|`CamelAwsDdbUnprocessedKeys`\ \ |`Map` |Contains a map of tables and their respective\ \ keys that were not\nprocessed with the current response.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringDeleteItemoperation]]\nMessage headers set\ \ during DeleteItem operation\n+++++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbAttributes` |`Map`\ \ |The list of attributes returned by the operation.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringDeleteTableoperation]]\nMessage headers set\ \ during DeleteTable operation\n++++++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbProvisionedThroughput`| | \n\n|`ProvisionedThroughputDescription`\ \ | |The value of the ProvisionedThroughput property for this table\n\n|`CamelAwsDdbCreationDate`\ \ |`Date` |Creation DateTime of this table.\n\n|`CamelAwsDdbTableItemCount`\ \ |`Long` |Item count for this table.\n\n|`CamelAwsDdbKeySchema` |`KeySchema`\ \ |The KeySchema that identifies the primary key for this table. \n*From Camel\ \ 2.16.0 the type of this header is List and not KeySchema*\n\ \n|`CamelAwsDdbTableName` |`String` |The table name. \n\n|`CamelAwsDdbTableSize`\ \ |`Long` |The table size in bytes. \n\n|`CamelAwsDdbTableStatus` |`String`\ \ |The status of the table: CREATING, UPDATING, DELETING, ACTIVE\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringDescribeTableoperation]]\nMessage headers\ \ set during DescribeTable operation\n++++++++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbProvisionedThroughput` |{{ProvisionedThroughputDescription}}\ \ |The value of the ProvisionedThroughput property for this table\n\n|`CamelAwsDdbCreationDate`\ \ |`Date` |Creation DateTime of this table.\n\n|`CamelAwsDdbTableItemCount`\ \ |`Long` |Item count for this table.\n\n|`CamelAwsDdbKeySchema` |{{KeySchema}}\ \ |The KeySchema that identifies the primary key for this table.\n*From Camel\ \ 2.16.0 the type of this header is List and\nnot KeySchema*\n\ \n|`CamelAwsDdbTableName` |`String` |The table name.\n\n|`CamelAwsDdbTableSize`\ \ |`Long` |The table size in bytes.\n\n|`CamelAwsDdbTableStatus` |`String` |The\ \ status of the table: CREATING, UPDATING, DELETING, ACTIVE\n\n|`CamelAwsDdbReadCapacity`\ \ |`Long` |ReadCapacityUnits property of this table.\n\n|`CamelAwsDdbWriteCapacity`\ \ |`Long` |WriteCapacityUnits property of this table.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringGetItemoperation]]\nMessage headers set during\ \ GetItem operation\n++++++++++++++++++++++++++++++++++++++++++++\n\n[width=\"\ 100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbAttributes` |`Map`\ \ |The list of attributes returned by the operation.\n\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringPutItemoperation]]\nMessage headers set during\ \ PutItem operation\n++++++++++++++++++++++++++++++++++++++++++++\n\n[width=\"\ 100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbAttributes` |`Map`\ \ |The list of attributes returned by the operation.\n\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringQueryoperation]]\nMessage headers set during\ \ Query operation\n++++++++++++++++++++++++++++++++++++++++++\n\n[width=\"100%\"\ ,cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbItems` |`List>`\ \ |The list of attributes returned by the operation.\n\n|`CamelAwsDdbLastEvaluatedKey`\ \ |`Key` |Primary key of the item where the query operation stopped, inclusive\ \ of\nthe previous result set.\n\n|`CamelAwsDdbConsumedCapacity` |`Double` |The\ \ number of Capacity Units of the provisioned throughput of the table\nconsumed\ \ during the operation.\n\n|`CamelAwsDdbCount` |`Integer` |Number of items in\ \ the response.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringScanoperation]]\nMessage headers set during\ \ Scan operation\n+++++++++++++++++++++++++++++++++++++++++\n\n[width=\"100%\"\ ,cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbItems` |`List>`\ \ |The list of attributes returned by the operation.\n\n|`CamelAwsDdbLastEvaluatedKey`\ \ |`Key` |Primary key of the item where the query operation stopped, inclusive\ \ of\nthe previous result set.\n\n|`CamelAwsDdbConsumedCapacity` |`Double` |The\ \ number of Capacity Units of the provisioned throughput of the table\nconsumed\ \ during the operation.\n\n|`CamelAwsDdbCount` |`Integer` |Number of items in\ \ the response.\n\n|`CamelAwsDdbScannedCount` |`Integer` |Number of items in\ \ the complete scan before any filters are applied.\n|=======================================================================\n\ \n[[AWS-DDB-MessageheaderssetduringUpdateItemoperation]]\nMessage headers set\ \ during UpdateItem operation\n+++++++++++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsDdbAttributes` |`Map`\ \ |The list of attributes returned by the operation.\n\n|=======================================================================\n\ \n[[AWS-DDB-AdvancedAmazonDynamoDBconfiguration]]\nAdvanced AmazonDynamoDB configuration\n\ +++++++++++++++++++++++++++++++++++++\n\nIf you need more control over the `AmazonDynamoDB`\ \ instance\nconfiguration you can create your own instance and refer to it from\ \ the\nURI:\n\n[source,java]\n----------------------------------------------------\n\ from(\"direct:start\")\n.to(\"aws-ddb://domainName?amazonDDBClient=#client\"\ );\n----------------------------------------------------\n\nThe `#client` refers\ \ to a `AmazonDynamoDB` in the\nlink:registry.html[Registry].\n\nFor example\ \ if your Camel Application is running behind a firewall:\n\n[source,java]\n\ --------------------------------------------------------------------------------------\n\ AWSCredentials awsCredentials = new BasicAWSCredentials(\"myAccessKey\", \"\ mySecretKey\");\nClientConfiguration clientConfiguration = new ClientConfiguration();\n\ clientConfiguration.setProxyHost(\"http://myProxyHost\");\nclientConfiguration.setProxyPort(8080);\n\ \nAmazonDynamoDB client = new AmazonDynamoDBClient(awsCredentials, clientConfiguration);\n\ \nregistry.bind(\"client\", client);\n--------------------------------------------------------------------------------------\n\ \n[[AWS-DDB-Dependencies]]\nDependencies\n^^^^^^^^^^^^\n\nMaven users will need\ \ to add the following dependency to their pom.xml.\n\n*pom.xml*\n\n[source,xml]\n\ ---------------------------------------\n\n org.apache.camel\n\ \ camel-aws\n ${camel-version}\n\ \n---------------------------------------\n\nwhere `${camel-version`}\ \ must be replaced by the actual version of Camel\n(2.10 or higher).\n\n[[AWS-DDB-SeeAlso]]\n\ See Also\n^^^^^^^^\n\n* link:configuring-camel.html[Configuring Camel]\n* link:component.html[Component]\n\ * link:endpoint.html[Endpoint]\n* link:getting-started.html[Getting Started]\n\ \n* link:aws.html[AWS Component]\n\n" - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-ddbstream version: 1.1.24 group: io.fabric8.funktion.connector name: aws-ddbstream data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ddbstream spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ddbstream spec: containers: - image: fabric8/connector-aws-ddbstream:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-ddbstream syntax: aws-ddbstream:tableName title: AWS DynamoDB Streams description: The aws-ddbstream component is used for working with Amazon DynamoDB Streams. label: cloud,messaging,streams deprecated: false async: false consumerOnly: true javaType: org.apache.camel.component.aws.ddbstream.DdbStreamComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: tableName: kind: path group: consumer label: consumer required: true type: string javaType: java.lang.String deprecated: false secret: false description: Name of the dynamodb table amazonDynamoDbStreamsClient: kind: parameter group: consumer label: consumer required: true type: object javaType: com.amazonaws.services.dynamodbv2.AmazonDynamoDBStreams deprecated: false secret: false description: Amazon DynamoDB client to use for all requests for this endpoint bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. iteratorType: kind: parameter group: consumer label: consumer type: string javaType: com.amazonaws.services.dynamodbv2.model.ShardIteratorType enum: - TRIM_HORIZON - LATEST - AT_SEQUENCE_NUMBER - AFTER_SEQUENCE_NUMBER deprecated: false secret: false defaultValue: LATEST description: Defines where in the DynaboDB stream to start getting records. Note that using TRIM_HORIZON can cause a significant delay before the stream has caught up to real-time. if ATAFTER_SEQUENCE_NUMBER are used then a sequenceNumberProvider MUST be supplied. maxResultsPerRequest: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false description: Maximum number of records that will be fetched in each poll sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. sequenceNumberProvider: kind: parameter group: consumer label: consumer type: object javaType: org.apache.camel.component.aws.ddbstream.SequenceNumberProvider deprecated: false secret: false description: Provider for the sequence number when using one of the two ShardIteratorType.ATAFTER_SEQUENCE_NUMBER iterator types. Can be a registry reference or a literal sequence number. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[AWS-DDBSTREAM-DynamoDBStreamComponent]] DynamoDB Stream Component ~~~~~~~~~~~~~~~~~~~~~~~~~ *Available as of Camel 2.7* The DynamoDB Stream component supports receiving messages from Amazon??DynamoDB Stream service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon DynamoDB Streams. More information are available at??http://aws.amazon.com/dynamodb/[AWS DynamoDB] [[AWS-DDBSTREAM-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------------------ aws-ddbstream://table-name[?options] ------------------------------------ The stream needs to be created prior to it being used. + You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-DDBSTREAM-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS DynamoDB Streams component has no options. // component options: END // endpoint options: START The AWS DynamoDB Streams component supports 24 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | tableName | consumer | | String | *Required* Name of the dynamodb table | amazonDynamoDbStreamsClient | consumer | | AmazonDynamoDBStreams | *Required* Amazon DynamoDB client to use for all requests for this endpoint | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | iteratorType | consumer | LATEST | ShardIteratorType | Defines where in the DynaboDB stream to start getting records. Note that using TRIM_HORIZON can cause a significant delay before the stream has caught up to real-time. if ATAFTER_SEQUENCE_NUMBER are used then a sequenceNumberProvider MUST be supplied. | maxResultsPerRequest | consumer | | int | Maximum number of records that will be fetched in each poll | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | sequenceNumberProvider | consumer | | SequenceNumberProvider | Provider for the sequence number when using one of the two ShardIteratorType.ATAFTER_SEQUENCE_NUMBER iterator types. Can be a registry reference or a literal sequence number. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END Required DynampDBStream component options You have to provide the??amazonDynamoDbStreamsClient in the link:registry.html[Registry] with proxies and relevant credentials configured. [[AWS-DDBSTREAM-SequenceNumbers]] Sequence Numbers ^^^^^^^^^^^^^^^^ You can provide a literal string as the sequence number or provide a bean in the registry. An example of using the bean would be to save your current position in the change feed and restore it on Camel startup. It is an error to provide a sequence number that is greater than the largest sequence number in the describe-streams result, as this will lead to the AWS call returning an HTTP 400. [[AWS-DDBSTREAM-BatchConsumer]] Batch Consumer ^^^^^^^^^^^^^^ This component implements the link:batch-consumer.html[Batch Consumer]. This allows you for instance to know how many messages exists in this batch and for instance let the link:aggregator.html[Aggregator] aggregate this number of messages. [[AWS-DDBSTREAM-Usage]] Usage ^^^^^ [[AWS-DDBSTREAM-AmazonDynamoDBStreamsClientconfiguration]] AmazonDynamoDBStreamsClient??configuration +++++++++++++++++++++++++++++++++++++++++ You will need to create an instance of AmazonDynamoDBStreamsClient and bind it to the registry [source,java] -------------------------------------------------------------------------------------------------------------------- ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); Region region = Region.getRegion(Regions.fromName(region)); region.createClient(AmazonDynamoDBStreamsClient.class, null, clientConfiguration); // the 'null' here is the AWSCredentialsProvider which defaults to an instance of DefaultAWSCredentialsProviderChain registry.bind("kinesisClient", client); -------------------------------------------------------------------------------------------------------------------- [[AWS-DDBSTREAM-ProvidingAWSCredentials]] Providing AWS Credentials +++++++++++++++++++++++++ It is recommended that the credentials are obtained by using the http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/DefaultAWSCredentialsProviderChain.html[DefaultAWSCredentialsProviderChain] that is the default when creating a new ClientConfiguration instance, however, a different??http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/AWSCredentialsProvider.html[AWSCredentialsProvider] can be specified when calling createClient(...). [[AWS-DDBSTREAM-CopingwithDowntime]] Coping with Downtime ^^^^^^^^^^^^^^^^^^^^ [[AWS-DDBSTREAM-AWSDynamoDBStreamsoutageoflessthan24hours]] AWS DynamoDB Streams outage of less than 24 hours +++++++++++++++++++++++++++++++++++++++++++++++++ The consumer will resume from the last seen sequence number (as implemented for??https://issues.apache.org/jira/browse/CAMEL-9515[CAMEL-9515]), so you should receive a flood of events in quick succession, as long as the outage did not also include DynamoDB itself. [[AWS-DDBSTREAM-AWSDynamoDBStreamsoutageofmorethan24hours]] AWS DynamoDB Streams outage of more than 24 hours +++++++++++++++++++++++++++++++++++++++++++++++++ Given that AWS only retain 24 hours worth of changes, you will have missed change events no matter what mitigations are in place. [[AWS-DDBSTREAM-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.7 or higher). [[AWS-DDBSTREAM-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] + + - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-ec2 version: 1.1.24 group: io.fabric8.funktion.connector name: aws-ec2 data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ec2 spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ec2 spec: containers: - image: fabric8/connector-aws-ec2:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-ec2 syntax: aws-ec2:label title: AWS EC2 description: The aws-ec2 is used for managing Amazon EC2 instances. label: cloud,management deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.ec2.EC2Component groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: label: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: Logical name accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonEc2Client: kind: parameter group: producer type: object javaType: com.amazonaws.services.ec2.AmazonEC2Client deprecated: false secret: false description: To use a existing configured AmazonEC2Client as client amazonEc2Endpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-EC2 client wants to work with. operation: kind: parameter group: producer label: producer required: true type: string javaType: org.apache.camel.component.aws.ec2.EC2Operations enum: - createAndRunInstances - ' startInstances' - ' stopInstances' - ' terminateInstances' - ' describeInstances' - ' describeInstancesStatus' - ' rebootInstances' - ' monitorInstances' - ' unmonitorInstances' - ' createTags' - ' deleteTags' deprecated: false secret: false description: The operation to perform. It can be createAndRunInstances startInstances stopInstances terminateInstances describeInstances describeInstancesStatus rebootInstances monitorInstances unmonitorInstances createTags or deleteTags proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[AWS-EC2-EC2Component]] EC2 Component ~~~~~~~~~~~~~ *Available as of Camel 2.16* The EC2 component supports create, run, start, stop and terminate https://aws.amazon.com/it/ec2/[AWS EC2] instances. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon EC2. More information are available at https://aws.amazon.com/it/ec2/[Amazon EC2]. [[AWS-EC2-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------- aws-ec2://label[?options] ------------------------- You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-EC2-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS EC2 component has no options. // component options: END // endpoint options: START The AWS EC2 component supports 9 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | label | producer | | String | *Required* Logical name | accessKey | producer | | String | Amazon AWS Access Key | amazonEc2Client | producer | | AmazonEC2Client | To use a existing configured AmazonEC2Client as client | amazonEc2Endpoint | producer | | String | The region with which the AWS-EC2 client wants to work with. | operation | producer | | EC2Operations | *Required* The operation to perform. It can be createAndRunInstances startInstances stopInstances terminateInstances describeInstances describeInstancesStatus rebootInstances monitorInstances unmonitorInstances createTags or deleteTags | proxyHost | producer | | String | To define a proxy host when instantiating the SQS client | proxyPort | producer | | Integer | To define a proxy port when instantiating the SQS client | secretKey | producer | | String | Amazon AWS Secret Key | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END Required EC2 component options You have to provide the amazonEc2Client in the link:registry.html[Registry] or your accessKey and secretKey to access the https://aws.amazon.com/it/ec2/[Amazon EC2] service. [[AWS-EC2-Usage]] Usage ^^^^^ [[AWS-EC2-MessageheadersevaluatedbytheEC2producer]] Message headers evaluated by the EC2 producer +++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsEC2ImageId` |`String` |An image ID of the AWS marketplace |`CamelAwsEC2InstanceType` |com.amazonaws.services.ec2.model.InstanceType |The instance type we want to create and run |`CamelAwsEC2Operation` |`String` |The operation we want to perform |`CamelAwsEC2InstanceMinCount` |`Int` |The mininum number of instances we want to run. |`CamelAwsEC2InstanceMaxCount` |`Int` |The maximum number of instances we want to run. |`CamelAwsEC2InstanceMonitoring` |Boolean |Define if we want the running instances to be monitored |`CamelAwsEC2InstanceEbsOptimized` |`Boolean` |Define if the creating instance is optimized for EBS I/O. |`CamelAwsEC2InstanceSecurityGroups` |Collection |The security groups to associate to the instances |`CamelAwsEC2InstancesIds` |`Collection` |A collection of instances IDS to execute start, stop, describe and terminate operations on. |`CamelAwsEC2InstancesTags` |`Collection` |A collection of tags to add or remove from EC2 resources |======================================================================= Dependencies Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.16 or higher). [[AWS-EC2-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-kinesis version: 1.1.24 group: io.fabric8.funktion.connector name: aws-kinesis data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-kinesis spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-kinesis spec: containers: - image: fabric8/connector-aws-kinesis:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-kinesis syntax: aws-kinesis:streamName title: AWS Kinesis description: The aws-kinesis component is for consuming records from Amazon Kinesis Streams. label: cloud,messaging deprecated: false async: false javaType: org.apache.camel.component.aws.kinesis.KinesisComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: streamName: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Name of the stream amazonKinesisClient: kind: parameter group: common required: true type: object javaType: com.amazonaws.services.kinesis.AmazonKinesis deprecated: false secret: false description: Amazon Kinesis client to use for all requests for this endpoint bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. iteratorType: kind: parameter group: consumer label: consumer type: string javaType: com.amazonaws.services.kinesis.model.ShardIteratorType enum: - AT_SEQUENCE_NUMBER - AFTER_SEQUENCE_NUMBER - TRIM_HORIZON - LATEST - AT_TIMESTAMP deprecated: false secret: false description: Defines where in the Kinesis stream to start getting records maxResultsPerRequest: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Maximum number of records that will be fetched in each poll sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. sequenceNumber: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: The sequence number to start polling from shardId: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: Defines which shardId in the Kinesis stream to get records from exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[AWS-KINESIS-KinesisComponent]] Kinesis Component ~~~~~~~~~~~~~~~~~ *Available as of Camel 2.17* The Kinesis component supports receiving messages from Amazon Kinesis service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon Kinesis. More information are available at??http://aws.amazon.com/kinesis/[AWS Kinesis] [[AWS-KINESIS-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ----------------------------------- aws-kinesis://stream-name[?options] ----------------------------------- The stream needs to be created prior to it being used. + You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-KINESIS-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS Kinesis component has no options. // component options: END // endpoint options: START The AWS Kinesis component supports 25 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | streamName | common | | String | *Required* Name of the stream | amazonKinesisClient | common | | AmazonKinesis | *Required* Amazon Kinesis client to use for all requests for this endpoint | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | iteratorType | consumer | | ShardIteratorType | Defines where in the Kinesis stream to start getting records | maxResultsPerRequest | consumer | 1 | int | Maximum number of records that will be fetched in each poll | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | sequenceNumber | consumer | | String | The sequence number to start polling from | shardId | consumer | | String | Defines which shardId in the Kinesis stream to get records from | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END Required Kinesis component options You have to provide the??amazonKinesisClient in the link:registry.html[Registry] with proxies and relevant credentials configured. [[AWS-KINESIS-BatchConsumer]] Batch Consumer ^^^^^^^^^^^^^^ This component implements the link:batch-consumer.html[Batch Consumer]. This allows you for instance to know how many messages exists in this batch and for instance let the link:aggregator.html[Aggregator] aggregate this number of messages. [[AWS-KINESIS-Usage]] Usage ^^^^^ [[AWS-KINESIS-MessageheaderssetbytheKinesisconsumer]] Message headers set by the Kinesis consumer +++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsKinesisSequenceNumber` |`String` |The sequence number of the record. This is represented as a String as it size is not defined by the API. If it is to be used as a numerical type then use |`CamelAwsKinesisApproximateArrivalTimestamp` |`String` |The time AWS assigned as the arrival time of the record. |`CamelAwsKinesisPartitionKey` |`String` |Identifies which shard in the stream the data record is assigned to. |======================================================================= [[AWS-KINESIS-AmazonKinesisconfiguration]] AmazonKinesis configuration +++++++++++++++++++++++++++ You will need to create an instance of AmazonDynamoDBStreamsClient and bind it to the registry [source,java] -------------------------------------------------------------------------------------------------------------------- ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); Region region = Region.getRegion(Regions.fromName(region)); region.createClient(AmazonDynamoDBStreamsClient.class, null, clientConfiguration); // the 'null' here is the AWSCredentialsProvider which defaults to an instance of DefaultAWSCredentialsProviderChain registry.bind("kinesisClient", client); -------------------------------------------------------------------------------------------------------------------- [[AWS-KINESIS-ProvidingAWSCredentials]] Providing AWS Credentials +++++++++++++++++++++++++ It is recommended that the credentials are obtained by using the http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/DefaultAWSCredentialsProviderChain.html[DefaultAWSCredentialsProviderChain] that is the default when creating a new ClientConfiguration instance, however, a different??http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/AWSCredentialsProvider.html[AWSCredentialsProvider] can be specified when calling createClient(...). [[AWS-Kinesis-MessageheaderssetbytheKinesisproducer]] Message headers used by the Kinesis producer to write to Kinesis. The producer expects that the message body is a `ByteBuffer`. +++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsKinesisPartitionKey` |`String` |The PartitionKey to pass to Kinesis to store this record. |`CamelAwsKinesisSequenceNumber` |`String` |Optional paramter to indicate the sequence number of this record. |======================================================================= Message headers set by the Kinesis producer on successful storage of a Record +++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsKinesisSequenceNumber` |`String` |The sequence number of the record, as defined in http://docs.aws.amazon.com/kinesis/latest/APIReference/API_PutRecord.html#API_PutRecord_ResponseSyntax[Response Syntax] |`CamelAwsKinesisShardId` |`String` |The shard ID of where the Record was stored |======================================================================= [[AWS-KINESIS-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.17 or higher). [[AWS-KINESIS-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-s3 version: 1.1.24 group: io.fabric8.funktion.connector name: aws-s3 data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-s3 spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-s3 spec: containers: - image: fabric8/connector-aws-s3:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-s3 syntax: aws-s3:bucketNameOrArn title: AWS S3 Storage Service description: The aws-s3 component is used for storing and retrieving objecct from Amazon S3 Storage Service. label: cloud,file deprecated: false async: false javaType: org.apache.camel.component.aws.s3.S3Component groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: bucketNameOrArn: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Bucket name or ARN accessKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonS3Client: kind: parameter group: common type: object javaType: com.amazonaws.services.s3.AmazonS3 deprecated: false secret: false description: Reference to a com.amazonaws.services.sqs.AmazonS3 in the link:registry.htmlRegistry. amazonS3Endpoint: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-S3 client wants to work with. pathStyleAccess: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Whether or not the S3 client should use path style access policy: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: 'Camel 2.8.4: The policy for this queue to set in the com.amazonaws.services.s3.AmazonS3setBucketPolicy() method.' proxyHost: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: 'Camel 2.16: To define a proxy host when instantiating the SQS client' proxyPort: kind: parameter group: common type: integer javaType: java.lang.Integer deprecated: false secret: false description: 'Camel 2.16: Specify a proxy port to be used inside the client definition.' secretKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. deleteAfterRead: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Delete objects from S3 after they have been retrieved. The delete is only performed if the Exchange is committed. If a rollback occurs the object is not deleted. If this option is false then the same objects will be retrieve over and over again on the polls. Therefore you need to use the Idempotent Consumer EIP in the route to filter out duplicates. You can filter using the link S3ConstantsBUCKET_NAME and link S3ConstantsKEY headers or only the link S3ConstantsKEY header. fileName: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: To get the object from the bucket with the given file name includeBody: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: 'Camel 2.17: If it is true the exchange body will be set to a stream to the contents of the file. If false the headers will be set with the S3 object metadata but the body will be null.' maxMessagesPerPoll: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false defaultValue: "10" description: Gets the maximum number of messages as a limit to poll at each polling. Is default unlimited but use 0 or negative number to disable it as unlimited. prefix: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: 'Camel 2.10.1: The prefix which is used in the com.amazonaws.services.s3.model.ListObjectsRequest to only consume objects we are interested in.' sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. deleteAfterWrite: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: 'Camel 2.11.0: Delete file object after the S3 file has been uploaded' multiPartUpload: kind: parameter group: producer label: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: 'Camel 2.15.0: If it is true camel will upload the file with multi part format the part size is decided by the option of partSize' operation: kind: parameter group: producer label: producer type: string javaType: org.apache.camel.component.aws.s3.S3Operations enum: - copyObject - deleteBucket - listBuckets deprecated: false secret: false description: 'Camel 2.18: The operation to do in case the user don''t want to do only an upload' partSize: kind: parameter group: producer label: producer type: integer javaType: long deprecated: false secret: false defaultValue: "26214400" description: 'Camel 2.15.0: Setup the partSize which is used in multi part upload the default size is 25M.' region: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region where the bucket is located. This option is used in the com.amazonaws.services.s3.model.CreateBucketRequest. serverSideEncryption: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false description: 'Camel 2.16: Sets the server-side encryption algorithm when encrypting the object using AWS-managed keys. For example use AES256.' storageClass: kind: parameter group: producer label: producer type: string javaType: java.lang.String deprecated: false secret: false description: 'Camel 2.8.4: The storage class to set in the com.amazonaws.services.s3.model.PutObjectRequest request.' synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[AWS-S3-S3Component]] S3 Component ~~~~~~~~~~~~ *Available as of Camel 2.8* The S3 component supports storing and retrieving objetcs from/to http://aws.amazon.com/s3[Amazon's S3] service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon S3. More information are available at http://aws.amazon.com/s3[Amazon S3]. [[AWS-S3-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------------ aws-s3://bucketNameOrArn[?options] ------------------------------ The bucket will be created if it don't already exists. + You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-S3-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS S3 Storage Service component has no options. // component options: END // endpoint options: START The AWS S3 Storage Service component supports 40 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | bucketNameOrArn | common | | String | *Required* Bucket name or ARN | accessKey | common | | String | Amazon AWS Access Key | amazonS3Client | common | | AmazonS3 | Reference to a com.amazonaws.services.sqs.AmazonS3 in the link:registry.htmlRegistry. | amazonS3Endpoint | common | | String | The region with which the AWS-S3 client wants to work with. | pathStyleAccess | common | false | boolean | Whether or not the S3 client should use path style access | policy | common | | String | Camel 2.8.4: The policy for this queue to set in the com.amazonaws.services.s3.AmazonS3setBucketPolicy() method. | proxyHost | common | | String | Camel 2.16: To define a proxy host when instantiating the SQS client | proxyPort | common | | Integer | Camel 2.16: Specify a proxy port to be used inside the client definition. | secretKey | common | | String | Amazon AWS Secret Key | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | deleteAfterRead | consumer | true | boolean | Delete objects from S3 after they have been retrieved. The delete is only performed if the Exchange is committed. If a rollback occurs the object is not deleted. If this option is false then the same objects will be retrieve over and over again on the polls. Therefore you need to use the Idempotent Consumer EIP in the route to filter out duplicates. You can filter using the link S3ConstantsBUCKET_NAME and link S3ConstantsKEY headers or only the link S3ConstantsKEY header. | fileName | consumer | | String | To get the object from the bucket with the given file name | includeBody | consumer | true | boolean | Camel 2.17: If it is true the exchange body will be set to a stream to the contents of the file. If false the headers will be set with the S3 object metadata but the body will be null. | maxMessagesPerPoll | consumer | 10 | int | Gets the maximum number of messages as a limit to poll at each polling. Is default unlimited but use 0 or negative number to disable it as unlimited. | prefix | consumer | | String | Camel 2.10.1: The prefix which is used in the com.amazonaws.services.s3.model.ListObjectsRequest to only consume objects we are interested in. | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | deleteAfterWrite | producer | false | boolean | Camel 2.11.0: Delete file object after the S3 file has been uploaded | multiPartUpload | producer | false | boolean | Camel 2.15.0: If it is true camel will upload the file with multi part format the part size is decided by the option of partSize | operation | producer | | S3Operations | Camel 2.18: The operation to do in case the user don't want to do only an upload | partSize | producer | 26214400 | long | Camel 2.15.0: Setup the partSize which is used in multi part upload the default size is 25M. | region | producer | | String | The region where the bucket is located. This option is used in the com.amazonaws.services.s3.model.CreateBucketRequest. | serverSideEncryption | producer | | String | Camel 2.16: Sets the server-side encryption algorithm when encrypting the object using AWS-managed keys. For example use AES256. | storageClass | producer | | String | Camel 2.8.4: The storage class to set in the com.amazonaws.services.s3.model.PutObjectRequest request. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END Required S3 component options You have to provide the amazonS3Client in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/s3[Amazon's S3]. [[AWS-S3-BatchConsumer]] Batch Consumer ^^^^^^^^^^^^^^ This component implements the link:batch-consumer.html[Batch Consumer]. This allows you for instance to know how many messages exists in this batch and for instance let the link:aggregator.html[Aggregator] aggregate this number of messages. [[AWS-S3-Usage]] Usage ^^^^^ [[AWS-S3-MessageheadersevaluatedbytheS3producer]] Message headers evaluated by the S3 producer ++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsS3BucketName` |`String` |The bucket Name which this object will be stored or which will be used for the current operation |`CamelAwsS3BucketDestinationName` |`String` |*Camel 2.18*: The bucket Destination Name which will be used for the current operation |`CamelAwsS3ContentLength` |`Long` |The content length of this object. |`CamelAwsS3ContentType` |`String` |The content type of this object. |`CamelAwsS3ContentControl` |`String` |*Camel 2.8.2:* The content control of this object. |`CamelAwsS3ContentDisposition` |`String` |*Camel 2.8.2:* The content disposition of this object. |`CamelAwsS3ContentEncoding` |`String` |*Camel 2.8.2:* The content encoding of this object. |`CamelAwsS3ContentMD5` |`String` |*Camel 2.8.2:* The md5 checksum of this object. |`CamelAwsS3DestinationKey` |`String` |*Camel 2.18*:The Destination key which will be used for the current operation |`CamelAwsS3Key` |`String` |The key under which this object will be stored or which will be used for the current operation |`CamelAwsS3LastModified` |`java.util.Date` |*Camel 2.8.2:* The last modified timestamp of this object. |`CamelAwsS3Operation` |`String` |*Camel 2.18*: The operation to perform |`CamelAwsS3StorageClass` |`String` |*Camel 2.8.4:* The storage class of this object. |`CamelAwsS3CannedAcl` |`String` |*Camel 2.11.0:* The canned acl that will be applied to the object. see `com.amazonaws.services.s3.model.CannedAccessControlList` for allowed values. |`CamelAwsS3Acl` |`com.amazonaws.services.s3.model.AccessControlList` |*Camel 2.11.0:* a well constructed Amazon S3 Access Control List object. see `com.amazonaws.services.s3.model.AccessControlList` for more details |`CamelAwsS3Headers` |`Map` |*Camel 2.15.0*: support to get or set custom objectMetadata headers. |`CamelAwsS3ServerSideEncryption` |String |*Camel 2.16:* Sets the server-side encryption algorithm when encrypting the object using AWS-managed keys. For example use AES256. |`CamelAwsS3VersionId` |`String` |The version Id of the object to be stored or returned from the current operation |======================================================================= [[AWS-S3-MessageheaderssetbytheS3producer]] Message headers set by the S3 producer ++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsS3ETag` |`String` |The ETag value for the newly uploaded object. |`CamelAwsS3VersionId` |`String` |The *optional* version ID of the newly uploaded object. |======================================================================= [[AWS-S3-MessageheaderssetbytheS3consumer]] Message headers set by the S3 consumer ++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsS3Key` |`String` |The key under which this object is stored. |`CamelAwsS3BucketName` |`String` |The name of the bucket in which this object is contained. |`CamelAwsS3ETag` |`String` |The hex encoded 128-bit MD5 digest of the associated object according to RFC 1864. This data is used as an integrity check to verify that the data received by the caller is the same data that was sent by Amazon S3. |`CamelAwsS3LastModified` |`Date` |The value of the Last-Modified header, indicating the date and time at which Amazon S3 last recorded a modification to the associated object. |`CamelAwsS3VersionId` |`String` |The version ID of the associated Amazon S3 object if available. Version IDs are only assigned to objects when an object is uploaded to an Amazon S3 bucket that has object versioning enabled. |`CamelAwsS3ContentType` |`String` |The Content-Type HTTP header, which indicates the type of content stored in the associated object. The value of this header is a standard MIME type. |`CamelAwsS3ContentMD5` |`String` |The base64 encoded 128-bit MD5 digest of the associated object (content - not including headers) according to RFC 1864. This data is used as a message integrity check to verify that the data received by Amazon S3 is the same data that the caller sent. |`CamelAwsS3ContentLength` |`Long` |The Content-Length HTTP header indicating the size of the associated object in bytes. |`CamelAwsS3ContentEncoding` |`String` |The *optional* Content-Encoding HTTP header specifying what content encodings have been applied to the object and what decoding mechanisms must be applied in order to obtain the media-type referenced by the Content-Type field. |`CamelAwsS3ContentDisposition` |`String` |The *optional* Content-Disposition HTTP header, which specifies presentational information such as the recommended filename for the object to be saved as. |`CamelAwsS3ContentControl` |`String` |The *optional* Cache-Control HTTP header which allows the user to specify caching behavior along the HTTP request/reply chain. |`CamelAwsS3ServerSideEncryption` |String |*Camel 2.16:* The server-side encryption algorithm when encrypting the object using AWS-managed keys. |======================================================================= [[AWS-S3-AdvancedAmazonS3configuration]] Advanced AmazonS3 configuration +++++++++++++++++++++++++++++++ If your Camel Application is running behind a firewall or if you need to have more control over the `AmazonS3` instance configuration, you can create your own instance: [source,java] -------------------------------------------------------------------------------------- AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonS3 client = new AmazonS3Client(awsCredentials, clientConfiguration); registry.bind("client", client); -------------------------------------------------------------------------------------- and refer to it in your Camel aws-s3 component configuration: [source,java] -------------------------------------------------------------------------------- from("aws-s3://MyBucket?amazonS3Client=#client&delay=5000&maxMessagesPerPoll=5") .to("mock:result"); -------------------------------------------------------------------------------- [[AWS-S3-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.8 or higher). [[AWS-S3-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-sdb version: 1.1.24 group: io.fabric8.funktion.connector name: aws-sdb data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sdb spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sdb spec: containers: - image: fabric8/connector-aws-sdb:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-sdb syntax: aws-sdb:domainName title: AWS SimpleDB description: The aws-sdb component is for storing and retrieving data from/to Amazon's SDB service. label: cloud,database,nosql deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.sdb.SdbComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: domainName: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: The name of the domain currently worked with. accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonSDBClient: kind: parameter group: producer type: object javaType: com.amazonaws.services.simpledb.AmazonSimpleDB deprecated: false secret: false description: To use the AmazonSimpleDB as the client amazonSdbEndpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-SDB client wants to work with. consistentRead: kind: parameter group: producer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Determines whether or not strong consistency should be enforced when data is read. maxNumberOfDomains: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: The maximum number of domain names you want returned. The range is 1 to 100. operation: kind: parameter group: producer type: string javaType: org.apache.camel.component.aws.sdb.SdbOperations enum: - BatchDeleteAttributes - BatchPutAttributes - DeleteAttributes - DeleteDomain - DomainMetadata - GetAttributes - ListDomains - PutAttributes - Select deprecated: false secret: false defaultValue: PutAttributes description: Operation to perform proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[AWS-SDB-SDBComponent]] SDB Component ~~~~~~~~~~~~~ *Available as of Camel 2.8.4* The sdb component supports storing and retrieving data from/to http://aws.amazon.com/sdb[Amazon's SDB] service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon SDB. More information are available at http://aws.amazon.com/sdb[Amazon SDB]. [[AWS-SDB-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------------ aws-sdb://domainName[?options] ------------------------------ You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-SDB-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS SimpleDB component has no options. // component options: END // endpoint options: START The AWS SimpleDB component supports 11 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | domainName | producer | | String | *Required* The name of the domain currently worked with. | accessKey | producer | | String | Amazon AWS Access Key | amazonSDBClient | producer | | AmazonSimpleDB | To use the AmazonSimpleDB as the client | amazonSdbEndpoint | producer | | String | The region with which the AWS-SDB client wants to work with. | consistentRead | producer | false | boolean | Determines whether or not strong consistency should be enforced when data is read. | maxNumberOfDomains | producer | | Integer | The maximum number of domain names you want returned. The range is 1 to 100. | operation | producer | PutAttributes | SdbOperations | Operation to perform | proxyHost | producer | | String | To define a proxy host when instantiating the SQS client | proxyPort | producer | | Integer | To define a proxy port when instantiating the SQS client | secretKey | producer | | String | Amazon AWS Secret Key | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END Required SDB component options You have to provide the amazonSDBClient in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/sdb[Amazon's SDB]. [[AWS-SDB-Usage]] Usage ^^^^^ [[AWS-SDB-MessageheadersevaluatedbytheSDBproducer]] Message headers evaluated by the SDB producer +++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSdbAttributes` |`Collection` |List of attributes to be acted upon. |`CamelAwsSdbAttributeNames` |`Collection` |The names of the attributes to be retrieved. |`CamelAwsSdbConsistentRead` |`Boolean` |Determines whether or not strong consistency should be enforced when data is read. |`CamelAwsSdbDeletableItems` |`Collection` |A list of items on which to perform the delete operation in a batch. |`CamelAwsSdbDomainName` |`String` |The name of the domain currently worked with. |`CamelAwsSdbItemName` |`String` |The unique key for this item |`CamelAwsSdbMaxNumberOfDomains` |`Integer` |The maximum number of domain names you want returned. The range is 1 * to 100. |`CamelAwsSdbNextToken` |`String` |A string specifying where to start the next list of domain/item names. |`CamelAwsSdbOperation` |`String` |To override the operation from the URI options. |`CamelAwsSdbReplaceableAttributes` |`Collection` |List of attributes to put in an Item. |`CamelAwsSdbReplaceableItems` |`Collection` |A list of items to put in a Domain. |`CamelAwsSdbSelectExpression` |`String` |The expression used to query the domain. |`CamelAwsSdbUpdateCondition` |`UpdateCondition` |The update condition which, if specified, determines whether the specified attributes will be updated/deleted or not. |======================================================================= [[AWS-SDB-MessageheaderssetduringDomainMetadataoperation]] Message headers set during DomainMetadata operation +++++++++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSdbTimestamp` |`Integer` |The data and time when metadata was calculated, in Epoch (UNIX) seconds. |`CamelAwsSdbItemCount` |`Integer` |The number of all items in the domain. |`CamelAwsSdbAttributeNameCount` |`Integer` |The number of unique attribute names in the domain. |`CamelAwsSdbAttributeValueCount` |`Integer` |The number of all attribute name/value pairs in the domain. |`CamelAwsSdbAttributeNameSize` |`Long` |The total size of all unique attribute names in the domain, in bytes. |`CamelAwsSdbAttributeValueSize` |`Long` |The total size of all attribute values in the domain, in bytes. |`CamelAwsSdbItemNameSize` |`Long` |The total size of all item names in the domain, in bytes. |======================================================================= [[AWS-SDB-MessageheaderssetduringGetAttributesoperation]] Message headers set during GetAttributes operation ++++++++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSdbAttributes` |`List` |The list of attributes returned by the operation. |======================================================================= [[AWS-SDB-MessageheaderssetduringListDomainsoperation]] Message headers set during ListDomains operation ++++++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSdbDomainNames` |`List` |A list of domain names that match the expression. |`CamelAwsSdbNextToken` |`String` |An opaque token indicating that there are more domains than the specified MaxNumberOfDomains still available. |======================================================================= [[AWS-SDB-MessageheaderssetduringSelectoperation]] Message headers set during Select operation +++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSdbItems` |`List` |A list of items that match the select expression. |`CamelAwsSdbNextToken` |`String` |An opaque token indicating that more items than MaxNumberOfItems were matched, the response size exceeded 1 megabyte, or the execution time exceeded 5 seconds. |======================================================================= [[AWS-SDB-AdvancedAmazonSimpleDBconfiguration]] Advanced AmazonSimpleDB configuration +++++++++++++++++++++++++++++++++++++ If you need more control over the `AmazonSimpleDB` instance configuration you can create your own instance and refer to it from the URI: [source,java] ---------------------------------------------------- from("direct:start") .to("aws-sdb://domainName?amazonSDBClient=#client"); ---------------------------------------------------- The `#client` refers to a `AmazonSimpleDB` in the link:registry.html[Registry]. For example if your Camel Application is running behind a firewall: [source,java] -------------------------------------------------------------------------------------- AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonSimpleDB client = new AmazonSimpleDBClient(awsCredentials, clientConfiguration); registry.bind("client", client); -------------------------------------------------------------------------------------- [[AWS-SDB-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.8.4 or higher). [[AWS-SDB-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-ses version: 1.1.24 group: io.fabric8.funktion.connector name: aws-ses data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ses spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-ses spec: containers: - image: fabric8/connector-aws-ses:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-ses syntax: aws-ses:from title: AWS Simple Email Service description: The aws-ses component is used for sending emails with Amazon's SES service. label: cloud,mail deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.ses.SesComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: from: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: The sender's email address. accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonSESClient: kind: parameter group: producer type: object javaType: com.amazonaws.services.simpleemail.AmazonSimpleEmailService deprecated: false secret: false description: To use the AmazonSimpleEmailService as the client amazonSESEndpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-SES client wants to work with. proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client replyToAddresses: kind: parameter group: producer type: array javaType: java.util.List deprecated: false secret: false description: List of reply-to email address(es) for the message override it using 'CamelAwsSesReplyToAddresses' header. returnPath: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The email address to which bounce notifications are to be forwarded override it using 'CamelAwsSesReturnPath' header. secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key subject: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The subject which is used if the message header 'CamelAwsSesSubject' is not present. to: kind: parameter group: producer type: array javaType: java.util.List deprecated: false secret: false description: List of destination email address. Can be overriden with 'CamelAwsSesTo' header. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[AWS-SES-SESComponent]] SES Component ~~~~~~~~~~~~~ *Available as of Camel 2.8.4* The ses component supports sending emails with http://aws.amazon.com/ses[Amazon's SES] service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon SES. More information are available at http://aws.amazon.com/ses[Amazon SES]. [[AWS-SES-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ------------------------ aws-ses://from[?options] ------------------------ You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-SES-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS Simple Email Service component has no options. // component options: END // endpoint options: START The AWS Simple Email Service component supports 12 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | from | producer | | String | *Required* The sender's email address. | accessKey | producer | | String | Amazon AWS Access Key | amazonSESClient | producer | | AmazonSimpleEmailService | To use the AmazonSimpleEmailService as the client | amazonSESEndpoint | producer | | String | The region with which the AWS-SES client wants to work with. | proxyHost | producer | | String | To define a proxy host when instantiating the SQS client | proxyPort | producer | | Integer | To define a proxy port when instantiating the SQS client | replyToAddresses | producer | | List | List of reply-to email address(es) for the message override it using 'CamelAwsSesReplyToAddresses' header. | returnPath | producer | | String | The email address to which bounce notifications are to be forwarded override it using 'CamelAwsSesReturnPath' header. | secretKey | producer | | String | Amazon AWS Secret Key | subject | producer | | String | The subject which is used if the message header 'CamelAwsSesSubject' is not present. | to | producer | | List | List of destination email address. Can be overriden with 'CamelAwsSesTo' header. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END Required SES component options You have to provide the amazonSESClient in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/ses[Amazon's SES]. [[AWS-SES-Usage]] Usage ^^^^^ [[AWS-SES-MessageheadersevaluatedbytheSESproducer]] Message headers evaluated by the SES producer +++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSesFrom` |`String` |The sender's email address. |`CamelAwsSesTo` |`List` |The destination(s) for this email. |`CamelAwsSesSubject` |`String` |The subject of the message. |`CamelAwsSesReplyToAddresses` |`List` |The reply-to email address(es) for the message. |`CamelAwsSesReturnPath` |`String` |The email address to which bounce notifications are to be forwarded. |`CamelAwsSesHtmlEmail` |`Boolean` |*Since Camel 2.12.3* The flag to show if email content is HTML. |======================================================================= [[AWS-SES-MessageheaderssetbytheSESproducer]] Message headers set by the SES producer +++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSesMessageId` |`String` |The Amazon SES message ID. |======================================================================= [[AWS-SES-AdvancedAmazonSimpleEmailServiceconfiguration]] Advanced AmazonSimpleEmailService configuration +++++++++++++++++++++++++++++++++++++++++++++++ If you need more control over the `AmazonSimpleEmailService` instance configuration you can create your own instance and refer to it from the URI: [source,java] ------------------------------------------------------------- from("direct:start") .to("aws-ses://example@example.com?amazonSESClient=#client"); ------------------------------------------------------------- The `#client` refers to a `AmazonSimpleEmailService` in the link:registry.html[Registry]. For example if your Camel Application is running behind a firewall: [source,java] ---------------------------------------------------------------------------------------------------------- AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonSimpleEmailService client = new AmazonSimpleEmailServiceClient(awsCredentials, clientConfiguration); registry.bind("client", client); ---------------------------------------------------------------------------------------------------------- [[AWS-SES-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.8.4 or higher). [[AWS-SES-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-sns version: 1.1.24 group: io.fabric8.funktion.connector name: aws-sns data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sns spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sns spec: containers: - image: fabric8/connector-aws-sns:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-sns syntax: aws-sns:topicNameOrArn title: AWS Simple Notification System description: The aws-sns component is used for sending messages to an Amazon Simple Notification Topic. label: cloud,mobile,messaging deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.aws.sns.SnsComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: topicNameOrArn: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: Topic name or ARN accessKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonSNSClient: kind: parameter group: producer type: object javaType: com.amazonaws.services.sns.AmazonSNS deprecated: false secret: false description: To use the AmazonSNS as the client amazonSNSEndpoint: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-SNS client wants to work with. messageStructure: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The message structure to use such as json policy: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The policy for this queue proxyHost: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client secretKey: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key subject: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: The subject which is used if the message header 'CamelAwsSnsSubject' is not present. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[AWS-SNS-SNSComponent]] SNS Component ~~~~~~~~~~~~~ *Available as of Camel 2.8* The SNS component allows messages to be sent to an http://aws.amazon.com/sns[Amazon Simple Notification] Topic. The implementation of the Amazon API is provided by the??http://aws.amazon.com/sdkforjava/[AWS SDK]. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon SNS. More information are available at http://aws.amazon.com/sns[Amazon SNS]. [[AWS-SNS-URIFormat]] URI Format ^^^^^^^^^^ [source,java] ----------------------------- aws-sns://topicNameOrArn[?options] ----------------------------- The topic will be created if they don't already exists. + You can append query options to the URI in the following format, `?options=value&option2=value&...` [[AWS-SNS-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS Simple Notification System component has no options. // component options: END // endpoint options: START The AWS Simple Notification System component supports 11 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | topicNameOrArn | producer | | String | *Required* Topic name or ARN | accessKey | producer | | String | Amazon AWS Access Key | amazonSNSClient | producer | | AmazonSNS | To use the AmazonSNS as the client | amazonSNSEndpoint | producer | | String | The region with which the AWS-SNS client wants to work with. | messageStructure | producer | | String | The message structure to use such as json | policy | producer | | String | The policy for this queue | proxyHost | producer | | String | To define a proxy host when instantiating the SQS client | proxyPort | producer | | Integer | To define a proxy port when instantiating the SQS client | secretKey | producer | | String | Amazon AWS Secret Key | subject | producer | | String | The subject which is used if the message header 'CamelAwsSnsSubject' is not present. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END Required SNS component options You have to provide the amazonSNSClient in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/sns[Amazon's SNS]. [[AWS-SNS-Usage]] Usage ^^^^^ [[AWS-SNS-MessageheadersevaluatedbytheSNSproducer]] Message headers evaluated by the SNS producer +++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSnsSubject` |`String` |The Amazon SNS message subject. If not set, the subject from the `SnsConfiguration` is used. |======================================================================= [[AWS-SNS-MessageheaderssetbytheSNSproducer]] Message headers set by the SNS producer +++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelAwsSnsMessageId` |`String` |The Amazon SNS message ID. |======================================================================= [[AWS-SNS-AdvancedAmazonSNSconfiguration]] Advanced AmazonSNS configuration ++++++++++++++++++++++++++++++++ If you need more control over the `AmazonSNS` instance configuration you can create your own instance and refer to it from the URI: [source,java] ------------------------------------------------- from("direct:start") .to("aws-sns://MyTopic?amazonSNSClient=#client"); ------------------------------------------------- The `#client` refers to a `AmazonSNS` in the link:registry.html[Registry]. For example if your Camel Application is running behind a firewall: [source,java] -------------------------------------------------------------------------------------- AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonSNS client = new AmazonSNSClient(awsCredentials, clientConfiguration); registry.bind("client", client); -------------------------------------------------------------------------------------- [[AWS-SNS-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.8 or higher). [[AWS-SNS-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-sqs version: 1.1.24 group: io.fabric8.funktion.connector name: aws-sqs data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sqs spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-sqs spec: containers: - image: fabric8/connector-aws-sqs:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-sqs syntax: aws-sqs:queueNameOrArn title: AWS Simple Queue Service description: The aws-sqs component is used for sending and receiving messages to Amazon's SQS service. label: cloud,messaging deprecated: false async: false javaType: org.apache.camel.component.aws.sqs.SqsComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: queueNameOrArn: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Queue name or ARN accessKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key amazonSQSClient: kind: parameter group: common type: object javaType: com.amazonaws.services.sqs.AmazonSQS deprecated: false secret: false description: To use the AmazonSQS as client amazonSQSEndpoint: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The region with which the AWS-SQS client wants to work with. Only works if Camel creates the AWS-SQS client i.e. if you explicitly set amazonSQSClient then this setting will have no effect. You would have to set it on the client you create directly headerFilterStrategy: kind: parameter group: common type: object javaType: org.apache.camel.spi.HeaderFilterStrategy deprecated: false secret: false description: To use a custom HeaderFilterStrategy to map headers to/from Camel. queueOwnerAWSAccountId: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Specify the queue owner aws account id when you need to connect the queue with different account owner. region: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Specify the queue region which could be used with queueOwnerAWSAccountId to build the service URL. secretKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key attributeNames: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: A list of attribute names to receive when consuming. Multiple names can be separated by comma. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. concurrentConsumers: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false defaultValue: "1" description: Allows you to use multiple threads to poll the sqs queue to increase throughput defaultVisibilityTimeout: kind: parameter group: consumer label: consumer type: integer javaType: java.lang.Integer deprecated: false secret: false description: The default visibility timeout (in seconds) deleteAfterRead: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Delete message from SQS after it has been read deleteIfFiltered: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Whether or not to send the DeleteMessage to the SQS queue if an exchange fails to get through a filter. If 'false' and exchange does not make it through a Camel filter upstream in the route then don't send DeleteMessage. extendMessageVisibility: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled then a scheduled background task will keep extending the message visibility on SQS. This is needed if it takes a long time to process the message. If set to true defaultVisibilityTimeout must be set. See details at Amazon docs. maxMessagesPerPoll: kind: parameter group: consumer label: consumer type: integer javaType: int deprecated: false secret: false description: Gets the maximum number of messages as a limit to poll at each polling. Is default unlimited but use 0 or negative number to disable it as unlimited. messageAttributeNames: kind: parameter group: consumer label: consumer type: string javaType: java.lang.String deprecated: false secret: false description: A list of message attribute names to receive when consuming. Multiple names can be separated by comma. sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. visibilityTimeout: kind: parameter group: consumer label: consumer type: integer javaType: java.lang.Integer deprecated: false secret: false description: The duration (in seconds) that the received messages are hidden from subsequent retrieve requests after being retrieved by a ReceiveMessage request to set in the com.amazonaws.services.sqs.model.SetQueueAttributesRequest. This only make sense if its different from defaultVisibilityTimeout. It changes the queue visibility timeout attribute permanently. waitTimeSeconds: kind: parameter group: consumer label: consumer type: integer javaType: java.lang.Integer deprecated: false secret: false description: Duration in seconds (0 to 20) that the ReceiveMessage action call will wait until a message is in the queue to include in the response. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. delaySeconds: kind: parameter group: producer label: producer type: integer javaType: java.lang.Integer deprecated: false secret: false description: Delay sending messages for a number of seconds. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. proxyHost: kind: parameter group: proxy label: proxy type: string javaType: java.lang.String deprecated: false secret: false description: To define a proxy host when instantiating the SQS client proxyPort: kind: parameter group: proxy label: proxy type: integer javaType: java.lang.Integer deprecated: false secret: false description: To define a proxy port when instantiating the SQS client maximumMessageSize: kind: parameter group: queue label: queue type: integer javaType: java.lang.Integer deprecated: false secret: false description: The maximumMessageSize (in bytes) an SQS message can contain for this queue. messageRetentionPeriod: kind: parameter group: queue label: queue type: integer javaType: java.lang.Integer deprecated: false secret: false description: The messageRetentionPeriod (in seconds) a message will be retained by SQS for this queue. policy: kind: parameter group: queue label: queue type: string javaType: java.lang.String deprecated: false secret: false description: The policy for this queue receiveMessageWaitTimeSeconds: kind: parameter group: queue label: queue type: integer javaType: java.lang.Integer deprecated: false secret: false description: If you do not specify WaitTimeSeconds in the request the queue attribute ReceiveMessageWaitTimeSeconds is used to determine how long to wait. redrivePolicy: kind: parameter group: queue label: queue type: string javaType: java.lang.String deprecated: false secret: false description: Specify the policy that send message to DeadLetter queue. See detail at Amazon docs. documentation.adoc: "[[AWS-SQS-SQSComponent]]\nSQS Component\n~~~~~~~~~~~~~\n\n\ *Available as of Camel 2.6*\n\nThe sqs component supports sending and receiving\ \ messages to\nhttp://aws.amazon.com/sqs[Amazon's SQS] service.\n\nPrerequisites\n\ \nYou must have a valid Amazon Web Services developer account, and be\nsigned\ \ up to use Amazon SQS. More information are available at\nhttp://aws.amazon.com/sqs[Amazon\ \ SQS].\n\n[[AWS-SQS-URIFormat]]\nURI Format\n^^^^^^^^^^\n\n[source,java]\n\ ------------------------------\naws-sqs://queueNameOrArn[?options]\n------------------------------\n\ \nThe queue will be created if they don't already exists. +\n You can append\ \ query options to the URI in the following format,\n?options=value&option2=value&...\n\ \n[[AWS-SQS-URIOptions]]\nURI Options\n^^^^^^^^^^^\n\n\n// component options:\ \ START\nThe AWS Simple Queue Service component has no options.\n// component\ \ options: END\n\n\n\n\n\n\n\n\n// endpoint options: START\nThe AWS Simple Queue\ \ Service component supports 45 endpoint options which are listed below:\n\n\ {% raw %}\n[width=\"100%\",cols=\"2,1,1m,1m,5\",options=\"header\"]\n|=======================================================================\n\ | Name | Group | Default | Java Type | Description\n| queueNameOrArn | common\ \ | | String | *Required* Queue name or ARN\n| accessKey | common | | String\ \ | Amazon AWS Access Key\n| amazonSQSClient | common | | AmazonSQS | To use\ \ the AmazonSQS as client\n| amazonSQSEndpoint | common | | String | The region\ \ with which the AWS-SQS client wants to work with. Only works if Camel creates\ \ the AWS-SQS client i.e. if you explicitly set amazonSQSClient then this setting\ \ will have no effect. You would have to set it on the client you create directly\n\ | headerFilterStrategy | common | | HeaderFilterStrategy | To use a custom\ \ HeaderFilterStrategy to map headers to/from Camel.\n| queueOwnerAWSAccountId\ \ | common | | String | Specify the queue owner aws account id when you need\ \ to connect the queue with different account owner.\n| region | common | |\ \ String | Specify the queue region which could be used with queueOwnerAWSAccountId\ \ to build the service URL.\n| secretKey | common | | String | Amazon AWS Secret\ \ Key\n| attributeNames | consumer | | String | A list of attribute names to\ \ receive when consuming. Multiple names can be separated by comma.\n| bridgeErrorHandler\ \ | consumer | false | boolean | Allows for bridging the consumer to the Camel\ \ routing Error Handler which mean any exceptions occurred while the consumer\ \ is trying to pickup incoming messages or the likes will now be processed as\ \ a message and handled by the routing Error Handler. By default the consumer\ \ will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions\ \ that will be logged at WARN/ERROR level and ignored.\n| concurrentConsumers\ \ | consumer | 1 | int | Allows you to use multiple threads to poll the sqs\ \ queue to increase throughput\n| defaultVisibilityTimeout | consumer | | Integer\ \ | The default visibility timeout (in seconds)\n| deleteAfterRead | consumer\ \ | true | boolean | Delete message from SQS after it has been read\n| deleteIfFiltered\ \ | consumer | true | boolean | Whether or not to send the DeleteMessage to\ \ the SQS queue if an exchange fails to get through a filter. If 'false' and\ \ exchange does not make it through a Camel filter upstream in the route then\ \ don't send DeleteMessage.\n| extendMessageVisibility | consumer | false |\ \ boolean | If enabled then a scheduled background task will keep extending\ \ the message visibility on SQS. This is needed if it takes a long time to process\ \ the message. If set to true defaultVisibilityTimeout must be set. See details\ \ at Amazon docs.\n| maxMessagesPerPoll | consumer | | int | Gets the maximum\ \ number of messages as a limit to poll at each polling. Is default unlimited\ \ but use 0 or negative number to disable it as unlimited.\n| messageAttributeNames\ \ | consumer | | String | A list of message attribute names to receive when\ \ consuming. Multiple names can be separated by comma.\n| sendEmptyMessageWhenIdle\ \ | consumer | false | boolean | If the polling consumer did not poll any files\ \ you can enable this option to send an empty message (no body) instead.\n|\ \ visibilityTimeout | consumer | | Integer | The duration (in seconds) that\ \ the received messages are hidden from subsequent retrieve requests after being\ \ retrieved by a ReceiveMessage request to set in the com.amazonaws.services.sqs.model.SetQueueAttributesRequest.\ \ This only make sense if its different from defaultVisibilityTimeout. It changes\ \ the queue visibility timeout attribute permanently.\n| waitTimeSeconds | consumer\ \ | | Integer | Duration in seconds (0 to 20) that the ReceiveMessage action\ \ call will wait until a message is in the queue to include in the response.\n\ | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the\ \ consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler\ \ is enabled then this options is not in use. By default the consumer will deal\ \ with exceptions that will be logged at WARN/ERROR level and ignored.\n| exchangePattern\ \ | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when\ \ the consumer creates an exchange.\n| pollStrategy | consumer (advanced) |\ \ | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy\ \ allowing you to provide your custom implementation to control error handling\ \ usually occurred during the poll operation before an Exchange have been created\ \ and being routed in Camel.\n| delaySeconds | producer | | Integer | Delay\ \ sending messages for a number of seconds.\n| synchronous | advanced | false\ \ | boolean | Sets whether synchronous processing should be strictly used or\ \ Camel is allowed to use asynchronous processing (if supported).\n| backoffErrorThreshold\ \ | scheduler | | int | The number of subsequent error polls (failed due some\ \ error) that should happen before the backoffMultipler should kick-in.\n| backoffIdleThreshold\ \ | scheduler | | int | The number of subsequent idle polls that should happen\ \ before the backoffMultipler should kick-in.\n| backoffMultiplier | scheduler\ \ | | int | To let the scheduled polling consumer backoff if there has been\ \ a number of subsequent idles/errors in a row. The multiplier is then the number\ \ of polls that will be skipped before the next actual attempt is happening\ \ again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold\ \ must also be configured.\n| delay | scheduler | 500 | long | Milliseconds\ \ before the next poll. You can also specify time values using units such as\ \ 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour).\n| greedy\ \ | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer\ \ will run immediately again if the previous run polled 1 or more messages.\n\ | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll\ \ starts. You can also specify time values using units such as 60s (60 seconds)\ \ 5m30s (5 minutes and 30 seconds) and 1h (1 hour).\n| runLoggingLevel | scheduler\ \ | TRACE | LoggingLevel | The consumer logs a start/complete log line when\ \ it polls. This option allows you to configure the logging level for that.\n\ | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows\ \ for configuring a custom/shared thread pool to use for the consumer. By default\ \ each consumer has its own single threaded thread pool.\n| scheduler | scheduler\ \ | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either\ \ camel-spring or camel-quartz2 component\n| schedulerProperties | scheduler\ \ | | Map | To configure additional properties when using a custom scheduler\ \ or any of the Quartz2 Spring based scheduler.\n| startScheduler | scheduler\ \ | true | boolean | Whether the scheduler should be auto started.\n| timeUnit\ \ | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay\ \ options.\n| useFixedDelay | scheduler | true | boolean | Controls if fixed\ \ delay or fixed rate is used. See ScheduledExecutorService in JDK for details.\n\ | proxyHost | proxy | | String | To define a proxy host when instantiating\ \ the SQS client\n| proxyPort | proxy | | Integer | To define a proxy port\ \ when instantiating the SQS client\n| maximumMessageSize | queue | | Integer\ \ | The maximumMessageSize (in bytes) an SQS message can contain for this queue.\n\ | messageRetentionPeriod | queue | | Integer | The messageRetentionPeriod (in\ \ seconds) a message will be retained by SQS for this queue.\n| policy | queue\ \ | | String | The policy for this queue\n| receiveMessageWaitTimeSeconds |\ \ queue | | Integer | If you do not specify WaitTimeSeconds in the request\ \ the queue attribute ReceiveMessageWaitTimeSeconds is used to determine how\ \ long to wait.\n| redrivePolicy | queue | | String | Specify the policy that\ \ send message to DeadLetter queue. See detail at Amazon docs.\n|=======================================================================\n\ {% endraw %}\n// endpoint options: END\n\n\n\n\n\n\n\nRequired SQS component\ \ options\n\nYou have to provide the amazonSQSClient in the\nlink:registry.html[Registry]\ \ or your accessKey and secretKey to access\nthe http://aws.amazon.com/sqs[Amazon's\ \ SQS].\n\n[[AWS-SQS-BatchConsumer]]\nBatch Consumer\n^^^^^^^^^^^^^^\n\nThis\ \ component implements the link:batch-consumer.html[Batch Consumer].\n\nThis\ \ allows you for instance to know how many messages exists in this\nbatch and\ \ for instance let the link:aggregator.html[Aggregator]\naggregate this number\ \ of messages.\n\n[[AWS-SQS-Usage]]\nUsage\n^^^^^\n\n[[AWS-SQS-MessageheaderssetbytheSQSproducer]]\n\ Message headers set by the SQS producer\n+++++++++++++++++++++++++++++++++++++++\n\ \n[width=\"100%\",cols=\"10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsSqsMD5OfBody` |`String` |The MD5 checksum\ \ of the Amazon SQS message.\n\n|`CamelAwsSqsMessageId` |`String` |The Amazon\ \ SQS message ID.\n\n|`CamelAwsSqsDelaySeconds` |`Integer` |Since *Camel 2.11*,\ \ the delay seconds that the Amazon SQS message can be\nsee by others.\n|=======================================================================\n\ \n[[AWS-SQS-MessageheaderssetbytheSQSconsumer]]\nMessage headers set by the\ \ SQS consumer\n+++++++++++++++++++++++++++++++++++++++\n\n[width=\"100%\",cols=\"\ 10%,10%,80%\",options=\"header\",]\n|=======================================================================\n\ |Header |Type |Description\n\n|`CamelAwsSqsMD5OfBody` |`String` |The MD5 checksum\ \ of the Amazon SQS message.\n\n|`CamelAwsSqsMessageId` |`String` |The Amazon\ \ SQS message ID. \n\n|`CamelAwsSqsReceiptHandle` |`String` |The Amazon SQS\ \ message receipt handle.\n\n|`CamelAwsSqsAttributes` |`Map`\ \ |The Amazon SQS message attributes.\n|=======================================================================\n\ \n[[AWS-SQS-AdvancedAmazonSQSconfiguration]]\nAdvanced AmazonSQS configuration\n\ ++++++++++++++++++++++++++++++++\n\nIf your Camel Application is running behind\ \ a firewall or if you need to\nhave more control over the AmazonSQS instance\ \ configuration, you can\ncreate your own instance:\n\n[source,java]\n--------------------------------------------------------------------------------------\n\ AWSCredentials awsCredentials = new BasicAWSCredentials(\"myAccessKey\", \"\ mySecretKey\");\n\nClientConfiguration clientConfiguration = new ClientConfiguration();\n\ clientConfiguration.setProxyHost(\"http://myProxyHost\");\nclientConfiguration.setProxyPort(8080);\n\ \nAmazonSQS client = new AmazonSQSClient(awsCredentials, clientConfiguration);\n\ \nregistry.bind(\"client\", client);\n--------------------------------------------------------------------------------------\n\ \nand refer to it in your Camel aws-sqs component configuration:\n\n[source,java]\n\ ---------------------------------------------------------------------------------\n\ from(\"aws-sqs://MyQueue?amazonSQSClient=#client&delay=5000&maxMessagesPerPoll=5\"\ )\n.to(\"mock:result\");\n---------------------------------------------------------------------------------\n\ \n[[AWS-SQS-Dependencies]]\nDependencies\n^^^^^^^^^^^^\n\nMaven users will need\ \ to add the following dependency to their pom.xml.\n\n*pom.xml*\n\n[source,xml]\n\ ---------------------------------------\n\n org.apache.camel\n\ \ camel-aws\n ${camel-version}\n\ \n---------------------------------------\n\nwhere `${camel-version`}\ \ must be replaced by the actual version of Camel\n(2.6 or higher).\n\n[[AWS-SQS-JMS-styleSelectors]]\n\ JMS-style Selectors\n^^^^^^^^^^^^^^^^^^^\n\nSQS does not allow selectors, but\ \ you can effectively achieve this by\nusing the link:message-filter.html[Camel\ \ Filter EIP] and setting an\nappropriate `visibilityTimeout`. When SQS dispatches\ \ a message, it will\nwait up to the visibility timeout before it will try to\ \ dispatch the\nmessage to a different consumer unless a DeleteMessage is received.\ \ By\ndefault, Camel will always send the DeleteMessage at the end of the\n\ route, unless the route ended in failure. To achieve appropriate\nfiltering\ \ and not send the DeleteMessage even on successful completion\nof the route,\ \ use a Filter:\n\n[source,java]\n------------------------------------------------------------------------------------------------------\n\ from(\"aws-sqs://MyQueue?amazonSQSClient=#client&defaultVisibilityTimeout=5000&deleteIfFiltered=false\"\ )\n.filter(\"${header.login} == true\")\n.to(\"mock:result\");\n------------------------------------------------------------------------------------------------------\n\ \nIn the above code, if an exchange doesn't have an appropriate header, it\n\ will not make it through the filter AND also not be deleted from the SQS\nqueue.\ \ After 5000 miliseconds, the message will become visible to other\nconsumers.\n\ \n[[AWS-SQS-SeeAlso]]\nSee Also\n^^^^^^^^\n\n* link:configuring-camel.html[Configuring\ \ Camel]\n* link:component.html[Component]\n* link:endpoint.html[Endpoint]\n\ * link:getting-started.html[Getting Started]\n\n* link:aws.html[AWS Component]\n\ \n" - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-aws-swf version: 1.1.24 group: io.fabric8.funktion.connector name: aws-swf data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-swf spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: aws-swf spec: containers: - image: fabric8/connector-aws-swf:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: aws-swf syntax: aws-swf:type title: AWS Simple Workflow description: The aws-swf component is used for managing workflows from Amazon Simple Workflow. label: cloud,workflow deprecated: false async: false javaType: org.apache.camel.component.aws.swf.SWFComponent groupId: org.apache.camel artifactId: camel-aws version: 2.18.1 componentProperties: {} properties: type: kind: path group: common required: true type: string javaType: java.lang.String enum: - activity - workflow deprecated: false secret: false description: Activity or workflow accessKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Access Key. amazonSWClient: kind: parameter group: common type: object javaType: com.amazonaws.services.simpleworkflow.AmazonSimpleWorkflowClient deprecated: false secret: false description: To use the given AmazonSimpleWorkflowClient as client dataConverter: kind: parameter group: common type: object javaType: com.amazonaws.services.simpleworkflow.flow.DataConverter deprecated: false secret: false description: An instance of com.amazonaws.services.simpleworkflow.flow.DataConverter to use for serializing/deserializing the data. domainName: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The workflow domain to use. eventName: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The workflow or activity event name to use. secretKey: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Amazon AWS Secret Key. version: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: The workflow or activity event version to use. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. clientConfigurationParameters: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: clientConfiguration. multiValue: true deprecated: false secret: false description: To configure the ClientConfiguration using the key/values from the Map. startWorkflowOptionsParameters: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: startWorkflowOptions. multiValue: true deprecated: false secret: false description: To configure the StartWorkflowOptions using the key/values from the Map. sWClientParameters: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: sWClient. multiValue: true deprecated: false secret: false description: To configure the AmazonSimpleWorkflowClient using the key/values from the Map. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). activityList: kind: parameter group: activity label: consumer,activity type: string javaType: java.lang.String deprecated: false secret: false description: The list name to consume activities from. activitySchedulingOptions: kind: parameter group: activity label: producer,activity type: object javaType: com.amazonaws.services.simpleworkflow.flow.ActivitySchedulingOptions deprecated: false secret: false description: Activity scheduling options activityThreadPoolSize: kind: parameter group: activity label: consumer,activity type: integer javaType: int deprecated: false secret: false defaultValue: "100" description: Maximum number of threads in work pool for activity. activityTypeExecutionOptions: kind: parameter group: activity label: consumer,activity type: object javaType: com.amazonaws.services.simpleworkflow.flow.worker.ActivityTypeExecutionOptions deprecated: false secret: false description: Activity execution options activityTypeRegistrationOptions: kind: parameter group: activity label: consumer,activity type: object javaType: com.amazonaws.services.simpleworkflow.flow.worker.ActivityTypeRegistrationOptions deprecated: false secret: false description: Activity registration options childPolicy: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: The policy to use on child workflows when terminating a workflow. executionStartToCloseTimeout: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false defaultValue: "3600" description: Set the execution start to close timeout. operation: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String enum: - SIGNAL - CANCEL - TERMINATE - GET_STATE - START - DESCRIBE - GET_HISTORY deprecated: false secret: false defaultValue: START description: Workflow operation signalName: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: The name of the signal to send to the workflow. stateResultType: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: The type of the result when a workflow state is queried. taskStartToCloseTimeout: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false defaultValue: "600" description: Set the task start to close timeout. terminationDetails: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: Details for terminating a workflow. terminationReason: kind: parameter group: workflow label: producer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: The reason for terminating a workflow. workflowList: kind: parameter group: workflow label: consumer,workflow type: string javaType: java.lang.String deprecated: false secret: false description: The list name to consume workflows from. workflowTypeRegistrationOptions: kind: parameter group: workflow label: consumer,workflow type: object javaType: com.amazonaws.services.simpleworkflow.flow.WorkflowTypeRegistrationOptions deprecated: false secret: false description: Workflow registration options documentation.adoc: | [[AWS-SWF-SWFComponent]] SWF Component ~~~~~~~~~~~~~ *Available as of Camel 2.13* The Simple Workflow component supports managing workflows from http://aws.amazon.com/swf/[Amazon's Simple Workflow] service. Prerequisites You must have a valid Amazon Web Services developer account, and be signed up to use Amazon Simple Workflow. More information are available at http://aws.amazon.com/swf/[Amazon Simple Workflow]. [[AWS-SWF-URIFormat]] URI Format ^^^^^^^^^^ [source,java] --------------------------------------- aws-swf://[?options] --------------------------------------- You can append query options to the URI in the following format, ?options=value&option2=value&... [[AWS-SWF-URIOptions]] URI Options ^^^^^^^^^^^ // component options: START The AWS Simple Workflow component has no options. // component options: END // endpoint options: START The AWS Simple Workflow component supports 30 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | type | common | | String | *Required* Activity or workflow | accessKey | common | | String | Amazon AWS Access Key. | amazonSWClient | common | | AmazonSimpleWorkflowClient | To use the given AmazonSimpleWorkflowClient as client | dataConverter | common | | DataConverter | An instance of com.amazonaws.services.simpleworkflow.flow.DataConverter to use for serializing/deserializing the data. | domainName | common | | String | The workflow domain to use. | eventName | common | | String | The workflow or activity event name to use. | secretKey | common | | String | Amazon AWS Secret Key. | version | common | | String | The workflow or activity event version to use. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | clientConfigurationParameters | advanced | | Map | To configure the ClientConfiguration using the key/values from the Map. | startWorkflowOptionsParameters | advanced | | Map | To configure the StartWorkflowOptions using the key/values from the Map. | sWClientParameters | advanced | | Map | To configure the AmazonSimpleWorkflowClient using the key/values from the Map. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | activityList | activity | | String | The list name to consume activities from. | activitySchedulingOptions | activity | | ActivitySchedulingOptions | Activity scheduling options | activityThreadPoolSize | activity | 100 | int | Maximum number of threads in work pool for activity. | activityTypeExecutionOptions | activity | | ActivityTypeExecutionOptions | Activity execution options | activityTypeRegistrationOptions | activity | | ActivityTypeRegistrationOptions | Activity registration options | childPolicy | workflow | | String | The policy to use on child workflows when terminating a workflow. | executionStartToCloseTimeout | workflow | 3600 | String | Set the execution start to close timeout. | operation | workflow | START | String | Workflow operation | signalName | workflow | | String | The name of the signal to send to the workflow. | stateResultType | workflow | | String | The type of the result when a workflow state is queried. | taskStartToCloseTimeout | workflow | 600 | String | Set the task start to close timeout. | terminationDetails | workflow | | String | Details for terminating a workflow. | terminationReason | workflow | | String | The reason for terminating a workflow. | workflowList | workflow | | String | The list name to consume workflows from. | workflowTypeRegistrationOptions | workflow | | WorkflowTypeRegistrationOptions | Workflow registration options |======================================================================= {% endraw %} // endpoint options: END Required SWF component options You have to provide the??amazonSWClient in the link:registry.html[Registry] or your accessKey and secretKey to access the http://aws.amazon.com/swf[Amazon's Simple Workflow Service]. [[AWS-SWF-Usage]] Usage ^^^^^ [[AWS-SWF-MessageheadersevaluatedbytheSWFWorkflowProducer]] Message headers evaluated by the SWF Workflow Producer ++++++++++++++++++++++++++++++++++++++++++++++++++++++ A workflow producer allows interacting with a workflow. It can start a new workflow execution, query its state, send signals to a running workflow, or terminate and cancel it. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelSWFOperation` |`String` |The operation to perform on the workflow. Supported operations are: + SIGNAL, CANCEL, TERMINATE, GET_STATE, START, DESCRIBE, GET_HISTORY. |`CamelSWFWorkflowId` |`String` |A workflow ID to use. |`CamelAwsDdbKeyCamelSWFRunId` |`String` |A worfklow run ID to use. |`CamelSWFStateResultType` |`String` |The type of the result when a workflow state is queried. |`CamelSWFEventName` |`String` |The workflow or activity event name to use. |`CamelSWFVersion` |`String` |The workflow or activity event version to use. |`CamelSWFReason` |`String` |The reason for terminating a workflow. |`CamelSWFDetails` |`String` |Details for terminating a workflow. |`CamelSWFChildPolicy` |`String` |The policy to use on child workflows when terminating a workflow. |======================================================================= [[AWS-SWF-MessageheaderssetbytheSWFWorkflowProducer]] Message headers set by the SWF Workflow Producer ++++++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelSWFWorkflowId` |`String` |The worfklow ID used or newly generated. |`CamelAwsDdbKeyCamelSWFRunId` |`String` |The worfklow run ID used or generated. |======================================================================= [[AWS-SWF-MessageheaderssetbytheSWFWorkflowConsumer]] Message headers set by the SWF Workflow Consumer ++++++++++++++++++++++++++++++++++++++++++++++++ A workflow consumer represents the workflow logic. When it is started, it will start polling workflow decision tasks and process them. In addition to processing decision tasks, a workflow consumer route, will also receive signals (send from a workflow producer) or state queries. The primary purpose of a workflow consumer is to schedule activity tasks for execution using activity producers. Actually activity tasks can be scheduled only from a thread started by a workflow consumer. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelSWFAction` |`String` |Indicates what type is the current event: CamelSWFActionExecute, CamelSWFSignalReceivedAction or CamelSWFGetStateAction. |`CamelSWFWorkflowReplaying` |`boolean` |Indicates whether the current decision task is a replay or not. |`CamelSWFWorkflowStartTime` |`long` |The time of the start event for this decision task. |======================================================================= [[AWS-SWF-MessageheaderssetbytheSWFActivityProducer]] Message headers set by the SWF Activity Producer ++++++++++++++++++++++++++++++++++++++++++++++++ An activity producer allows scheduling activity tasks. An activity producer can be used only from a thread started by a workflow consumer ie, it can process synchronous exchanges started by a workflow consumer. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelSWFEventName` |`String` |The activity name to schedule. |`CamelSWFVersion` |`String` |The activity version to schedule. |======================================================================= [[AWS-SWF-MessageheaderssetbytheSWFActivityConsumer]] Message headers set by the SWF Activity Consumer ++++++++++++++++++++++++++++++++++++++++++++++++ [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Header |Type |Description |`CamelSWFTaskToken` |`String` |The task token that is required to report task completion for manually completed tasks. |======================================================================= [[AWS-SWF-AdvancedamazonSWClientconfiguration]] Advanced amazonSWClient configuration +++++++++++++++++++++++++++++++++++++ If you need more control over the??AmazonSimpleWorkflowClient instance configuration you can create your own instance and refer to it from the URI: The `#client` refers to a??AmazonSimpleWorkflowClient in the link:registry.html[Registry]. For example if your Camel Application is running behind a firewall: [source,java] -------------------------------------------------------------------------------------------------------- AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey"); ClientConfiguration clientConfiguration = new ClientConfiguration(); clientConfiguration.setProxyHost("http://myProxyHost"); clientConfiguration.setProxyPort(8080); AmazonSimpleWorkflowClient client = new AmazonSimpleWorkflowClient(awsCredentials, clientConfiguration); registry.bind("client", client); -------------------------------------------------------------------------------------------------------- [[AWS-SWF-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users will need to add the following dependency to their pom.xml. *pom.xml* [source,xml] --------------------------------------- org.apache.camel camel-aws ${camel-version} --------------------------------------- where `${camel-version`} must be replaced by the actual version of Camel (2.13 or higher). [[AWS-SWF-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] link:aws.html[AWS Component] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-bean version: 1.1.24 group: io.fabric8.funktion.connector name: bean data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: bean spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: bean spec: containers: - image: fabric8/connector-bean:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: bean syntax: bean:beanName title: Bean description: The bean component is for invoking Java beans from Camel. label: core,java deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.bean.BeanComponent groupId: org.apache.camel artifactId: camel-core version: 2.18.1 componentProperties: {} properties: beanName: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: Sets the name of the bean to invoke method: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false description: Sets the name of the method to invoke on the bean cache: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: If enabled Camel will cache the result of the first Registry look-up. Cache can be enabled if the bean in the Registry is defined as a singleton scope. multiParameterArray: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: true secret: false defaultValue: false description: 'How to treat the parameters which are passed from the message body; if it is true the message body should be an array of parameters. Note: This option is used internally by Camel and is not intended for end users to use.' parameters: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map prefix: bean. multiValue: true deprecated: false secret: false description: Used for configuring additional properties on the bean synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: |+ [[Bean-BeanComponent]] Bean Component ~~~~~~~~~~~~~~ The *bean:* component binds beans to Camel message exchanges. [[Bean-URIformat]] URI format ^^^^^^^^^^ [source,java] --------------------- bean:beanID[?options] --------------------- Where *beanID* can be any string which is used to look up the bean in the link:registry.html[Registry] [[Bean-Options]] Options ^^^^^^^ // component options: START The Bean component has no options. // component options: END // endpoint options: START The Bean component supports 6 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | beanName | producer | | String | *Required* Sets the name of the bean to invoke | method | producer | | String | Sets the name of the method to invoke on the bean | cache | advanced | false | boolean | If enabled Camel will cache the result of the first Registry look-up. Cache can be enabled if the bean in the Registry is defined as a singleton scope. | multiParameterArray | advanced | false | boolean | How to treat the parameters which are passed from the message body; if it is true the message body should be an array of parameters. Note: This option is used internally by Camel and is not intended for end users to use. | parameters | advanced | | Map | Used for configuring additional properties on the bean | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END You can append query options to the URI in the following format, `?option=value&option=value&...` [[Bean-Using]] Using ^^^^^ The object instance that is used to consume messages must be explicitly registered with the link:registry.html[Registry]. For example, if you are using Spring you must define the bean in the Spring configuration, `spring.xml`; or if you don't use Spring, by registering the bean in JNDI. Error formatting macro: snippet: java.lang.IndexOutOfBoundsException: Index: 20, Size: 20 Once an endpoint has been registered, you can build Camel routes that use it to process exchanges. A *bean:* endpoint cannot be defined as the input to the route; i.e. you cannot consume from it, you can only route from some inbound message link:endpoint.html[Endpoint] to the bean endpoint as output. So consider using a *direct:* or *queue:* endpoint as the input. You can use the `createProxy()` methods on http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/component/bean/ProxyHelper.html[ProxyHelper] to create a proxy that will generate BeanExchanges and send them to any endpoint: And the same route using Spring DSL: [source,xml] ---------------------------- ---------------------------- [[Bean-Beanasendpoint]] Bean as endpoint ^^^^^^^^^^^^^^^^ Camel also supports invoking link:bean.html[Bean] as an Endpoint. In the route below: What happens is that when the exchange is routed to the `myBean` Camel will use the link:bean-binding.html[Bean Binding] to invoke the bean. + The source for the bean is just a plain POJO: Camel will use link:bean-binding.html[Bean Binding] to invoke the `sayHello` method, by converting the Exchange's In body to the `String` type and storing the output of the method on the Exchange Out body. [[Bean-JavaDSLbeansyntax]] Java DSL bean syntax ^^^^^^^^^^^^^^^^^^^^ Java DSL comes with syntactic sugar for the link:bean.html[Bean] component. Instead of specifying the bean explicitly as the endpoint (i.e. `to("bean:beanName")`) you can use the following syntax: [source,java] ------------------------------------------------------- // Send message to the bean endpoint // and invoke method resolved using Bean Binding. from("direct:start").beanRef("beanName"); // Send message to the bean endpoint // and invoke given method. from("direct:start").beanRef("beanName", "methodName"); ------------------------------------------------------- Instead of passing name of the reference to the bean (so that Camel will lookup for it in the registry), you can specify the bean itself: [source,java] --------------------------------------------------------------- // Send message to the given bean instance. from("direct:start").bean(new ExampleBean()); // Explicit selection of bean method to be invoked. from("direct:start").bean(new ExampleBean(), "methodName"); // Camel will create the instance of bean and cache it for you. from("direct:start").bean(ExampleBean.class); --------------------------------------------------------------- [[Bean-BeanBinding]] Bean Binding ^^^^^^^^^^^^ How bean methods to be invoked are chosen (if they are not specified explicitly through the *method* parameter) and how parameter values are constructed from the link:message.html[Message] are all defined by the link:bean-binding.html[Bean Binding] mechanism which is used throughout all of the various link:bean-integration.html[Bean Integration] mechanisms in Camel. [[Bean-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] * link:class.html[Class] component * link:bean-binding.html[Bean Binding] * link:bean-integration.html[Bean Integration] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-bean-validator version: 1.1.24 group: io.fabric8.funktion.connector name: bean-validator data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: bean-validator spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: bean-validator spec: containers: - image: fabric8/connector-bean-validator:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: bean-validator syntax: bean-validator:label title: Bean Validator description: The Validator component performs bean validation of the message body using the Java Bean Validation API. label: validation deprecated: false async: false producerOnly: true javaType: org.apache.camel.component.bean.validator.BeanValidatorComponent groupId: org.apache.camel artifactId: camel-bean-validator version: 2.18.1 componentProperties: {} properties: label: kind: path group: producer required: true type: string javaType: java.lang.String deprecated: false secret: false description: Where label is an arbitrary text value describing the endpoint constraintValidatorFactory: kind: parameter group: producer type: object javaType: javax.validation.ConstraintValidatorFactory deprecated: false secret: false description: To use a custom ConstraintValidatorFactory group: kind: parameter group: producer type: string javaType: java.lang.String deprecated: false secret: false defaultValue: javax.validation.groups.Default description: To use a custom validation group messageInterpolator: kind: parameter group: producer type: object javaType: javax.validation.MessageInterpolator deprecated: false secret: false description: To use a custom MessageInterpolator traversableResolver: kind: parameter group: producer type: object javaType: javax.validation.TraversableResolver deprecated: false secret: false description: To use a custom TraversableResolver validationProviderResolver: kind: parameter group: producer type: object javaType: javax.validation.ValidationProviderResolver deprecated: false secret: false description: To use a a custom ValidationProviderResolver synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: "[[BeanValidator-BeanValidatorComponent]]\nBean Validator\ \ Component\n~~~~~~~~~~~~~~~~~~~~~~~~\n\n*Available as of Camel 2.3*\n\nThe\ \ Validator component performs bean validation of the message body\nusing the\ \ Java Bean Validation API\n(http://jcp.org/en/jsr/detail?id=303[JSR 303]).\ \ Camel uses the reference\nimplementation, which is\nhttp://docs.jboss.org/hibernate/validator/4.3/reference/en-US/html_single/[Hibernate\n\ Validator].\n\nMaven users will need to add the following dependency to their\ \ `pom.xml`\nfor this component:\n\n[source,xml]\n------------------------------------------------------------\n\ \n org.apache.camel\n camel-bean-validator\n\ \ x.y.z\n \n\n------------------------------------------------------------\n\ \n[[BeanValidator-URIformat]]\nURI format\n^^^^^^^^^^\n\n[source,java]\n------------------------------\n\ bean-validator:label[?options]\n------------------------------\n\nor\n\n[source,java]\n\ --------------------------------\nbean-validator://label[?options]\n--------------------------------\n\ \nWhere *label* is an arbitrary text value describing the endpoint. +\n You\ \ can append query options to the URI in the following format,\n?option=value&option=value&...\n\ \n[[BeanValidator-URIOptions]]\nURI Options\n^^^^^^^^^^^\n\n\n// component options:\ \ START\nThe Bean Validator component has no options.\n// component options:\ \ END\n\n\n\n// endpoint options: START\nThe Bean Validator component supports\ \ 7 endpoint options which are listed below:\n\n{% raw %}\n[width=\"100%\",cols=\"\ 2,1,1m,1m,5\",options=\"header\"]\n|=======================================================================\n\ | Name | Group | Default | Java Type | Description\n| label | producer | |\ \ String | *Required* Where label is an arbitrary text value describing the\ \ endpoint\n| constraintValidatorFactory | producer | | ConstraintValidatorFactory\ \ | To use a custom ConstraintValidatorFactory\n| group | producer | javax.validation.groups.Default\ \ | String | To use a custom validation group\n| messageInterpolator | producer\ \ | | MessageInterpolator | To use a custom MessageInterpolator\n| traversableResolver\ \ | producer | | TraversableResolver | To use a custom TraversableResolver\n\ | validationProviderResolver | producer | | ValidationProviderResolver | To\ \ use a a custom ValidationProviderResolver\n| synchronous | advanced | false\ \ | boolean | Sets whether synchronous processing should be strictly used or\ \ Camel is allowed to use asynchronous processing (if supported).\n|=======================================================================\n\ {% endraw %}\n// endpoint options: END\n\n\n[[BeanValidator-OSGideployment]]\n\ OSGi deployment\n^^^^^^^^^^^^^^^\n\nTo use Hibernate Validator in the OSGi environment\ \ use dedicated\n`ValidationProviderResolver` implementation, just as\n`org.apache.camel.component.bean.validator.HibernateValidationProviderResolver`.\n\ The snippet below demonstrates this approach. Keep in mind that you can\nuse\ \ `HibernateValidationProviderResolver` starting from the Camel\n2.13.0.\n\n\ *Using HibernateValidationProviderResolver*\n\n[source,java]\n--------------------------------------------------------------------------------------------------------------------------------\n\ from(\"direct:test\").\n to(\"bean-validator://ValidationProviderResolverTest?validationProviderResolver=#myValidationProviderResolver\"\ );\n\n...\n\n \n--------------------------------------------------------------------------------------------------------------------------------\n\ \nIf no custom??`ValidationProviderResolver` is defined and the validator\n\ component has been deployed into the OSGi environment,\nthe??`HibernateValidationProviderResolver`\ \ will be automatically used.\n\n[[BeanValidator-Example]]\nExample\n^^^^^^^\n\ \nAssumed we have a java bean with the following annotations\n\n*Car.java*\n\ \n[source,java]\n-----------------------------------------------------------\n\ public class Car {\n\n @NotNull\n private String manufacturer;\n\n \ \ @NotNull\n @Size(min = 5, max = 14, groups = OptionalChecks.class)\n \ \ private String licensePlate;\n \n // getter and setter\n}\n-----------------------------------------------------------\n\ \nand an interface definition for our custom validation group\n\n*OptionalChecks.java*\n\ \n[source,java]\n---------------------------------\npublic interface OptionalChecks\ \ {\n}\n---------------------------------\n\nwith the following Camel route,\ \ only the *@NotNull* constraints on the\nattributes manufacturer and licensePlate\ \ will be validated (Camel uses\nthe default group `javax.validation.groups.Default`).\n\ \n[source,java]\n-------------------------\nfrom(\"direct:start\")\n.to(\"bean-validator://x\"\ )\n.to(\"mock:end\")\n-------------------------\n\nIf you want to check the\ \ constraints from the group `OptionalChecks`,\nyou have to define the route\ \ like this\n\n[source,java]\n----------------------------------------------\n\ from(\"direct:start\")\n.to(\"bean-validator://x?group=OptionalChecks\")\n.to(\"\ mock:end\")\n----------------------------------------------\n\nIf you want to\ \ check the constraints from both groups, you have to\ndefine a new interface\ \ first\n\n*AllChecks.java*\n\n[source,java]\n-----------------------------------------------------\n\ @GroupSequence({Default.class, OptionalChecks.class})\npublic interface AllChecks\ \ {\n}\n-----------------------------------------------------\n\nand then your\ \ route definition should looks like this\n\n[source,java]\n-----------------------------------------\n\ from(\"direct:start\")\n.to(\"bean-validator://x?group=AllChecks\")\n.to(\"\ mock:end\")\n-----------------------------------------\n\nAnd if you have to\ \ provide your own message interpolator, traversable\nresolver and constraint\ \ validator factory, you have to write a route\nlike this\n\n[source,java]\n\ ------------------------------------------------------------------------------------------------------\n\ \n\ \n\n\nfrom(\"direct:start\")\n.to(\"bean-validator://x?group=AllChecks&messageInterpolator=#myMessageInterpolator\n\ &traversableResolver=#myTraversableResolver&constraintValidatorFactory=#myConstraintValidatorFactory\"\ )\n.to(\"mock:end\")\n------------------------------------------------------------------------------------------------------\n\ \nIt's also possible to describe your constraints as XML and not as Java\nannotations.\ \ In this case, you have to provide the file\n`META-INF/validation.xml` which\ \ could looks like this\n\n*validation.xml*\n\n[source,java]\n------------------------------------------------------------------------------------------------------------------------------\n\ \n\n org.hibernate.validator.HibernateValidator\n\ \ org.hibernate.validator.engine.ResourceBundleMessageInterpolator\n\ \ org.hibernate.validator.engine.resolver.DefaultTraversableResolver\n\ \ org.hibernate.validator.engine.ConstraintValidatorFactoryImpl\n\ \ \n /constraints-car.xml\n\n\ ------------------------------------------------------------------------------------------------------------------------------\n\ \nand the `constraints-car.xml` file\n\n*constraints-car.xml*\n\n[source,java]\n\ ----------------------------------------------------------------------------------------------------\n\ \n\n org.apache.camel.component.bean.validator\n\ \ \n \n \n \n \n \n \ \ \n \n \n \n \n org.apache.camel.component.bean.validator.OptionalChecks\n\ \ \n 5\n\ \ 14\n \n\ \ \n \n\n----------------------------------------------------------------------------------------------------\n\ \n[[BeanValidator-SeeAlso]]\nSee Also\n^^^^^^^^\n\n* link:configuring-camel.html[Configuring\ \ Camel]\n* link:component.html[Component]\n* link:endpoint.html[Endpoint]\n\ * link:getting-started.html[Getting Started]\n\n" - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-beanstalk version: 1.1.24 group: io.fabric8.funktion.connector name: beanstalk data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: beanstalk spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: beanstalk spec: containers: - image: fabric8/connector-beanstalk:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: beanstalk syntax: beanstalk:connectionSettings title: Beanstalk description: The beanstalk component is used for job retrieval and post-processing of Beanstalk jobs. label: messaging deprecated: false async: true javaType: org.apache.camel.component.beanstalk.BeanstalkComponent groupId: org.apache.camel artifactId: camel-beanstalk version: 2.18.1 componentProperties: connectionSettingsFactory: kind: property type: object javaType: org.apache.camel.component.beanstalk.ConnectionSettingsFactory deprecated: false secret: false description: Custom ConnectionSettingsFactory. Specify which ConnectionSettingsFactory to use to make connections to Beanstalkd. Especially useful for unit testing without beanstalkd daemon (you can mock ConnectionSettings) properties: connectionSettings: kind: path group: common type: string javaType: java.lang.String deprecated: false secret: false description: Connection settings host:port/tube command: kind: parameter group: common type: string javaType: org.apache.camel.component.beanstalk.BeanstalkCommand enum: - bury - release - put - touch - delete - kick deprecated: false secret: false description: put means to put the job into Beanstalk. Job body is specified in the Camel message body. Job ID will be returned in beanstalk.jobId message header. delete release touch or bury expect Job ID in the message header beanstalk.jobId. Result of the operation is returned in beanstalk.result message header kick expects the number of jobs to kick in the message body and returns the number of jobs actually kicked out in the message header beanstalk.result. jobDelay: kind: parameter group: common type: integer javaType: int deprecated: false secret: false defaultValue: "0" description: Job delay in seconds. jobPriority: kind: parameter group: common type: integer javaType: long deprecated: false secret: false defaultValue: "1000" description: Job priority. (0 is the highest see Beanstalk protocol) jobTimeToRun: kind: parameter group: common type: integer javaType: int deprecated: false secret: false defaultValue: "60" description: Job time to run in seconds. (when 0 the beanstalkd daemon raises it to 1 automatically see Beanstalk protocol) awaitJob: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Whether to wait for job to complete before ack the job from beanstalk bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. onFailure: kind: parameter group: consumer label: consumer type: string javaType: org.apache.camel.component.beanstalk.BeanstalkCommand enum: - bury - release - put - touch - delete - kick deprecated: false secret: false description: Command to use when processing failed. sendEmptyMessageWhenIdle: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. useBlockIO: kind: parameter group: consumer label: consumer type: boolean javaType: boolean deprecated: false secret: false defaultValue: true description: Whether to use blockIO. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. pollStrategy: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.PollingConsumerPollStrategy optionalPrefix: consumer. deprecated: false secret: false description: A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). backoffErrorThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. backoffIdleThreshold: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. backoffMultiplier: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: int optionalPrefix: consumer. deprecated: false secret: false description: To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. delay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "500" description: Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). greedy: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. initialDelay: kind: parameter group: scheduler label: consumer,scheduler type: integer javaType: long optionalPrefix: consumer. deprecated: false secret: false defaultValue: "1000" description: Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). runLoggingLevel: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.LoggingLevel enum: - TRACE - DEBUG - INFO - WARN - ERROR - OFF optionalPrefix: consumer. deprecated: false secret: false defaultValue: TRACE description: The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. scheduledExecutorService: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.concurrent.ScheduledExecutorService optionalPrefix: consumer. deprecated: false secret: false description: Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. scheduler: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: org.apache.camel.spi.ScheduledPollConsumerScheduler enum: - none - spring - quartz2 optionalPrefix: consumer. deprecated: false secret: false defaultValue: none description: To use a cron scheduler from either camel-spring or camel-quartz2 component schedulerProperties: kind: parameter group: scheduler label: consumer,scheduler type: object javaType: java.util.Map prefix: scheduler. multiValue: true deprecated: false secret: false description: To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. startScheduler: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Whether the scheduler should be auto started. timeUnit: kind: parameter group: scheduler label: consumer,scheduler type: string javaType: java.util.concurrent.TimeUnit enum: - NANOSECONDS - MICROSECONDS - MILLISECONDS - SECONDS - MINUTES - HOURS - DAYS optionalPrefix: consumer. deprecated: false secret: false defaultValue: MILLISECONDS description: Time unit for initialDelay and delay options. useFixedDelay: kind: parameter group: scheduler label: consumer,scheduler type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: true description: Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. documentation.adoc: |+ [[Beanstalk-Beanstalkcomponent]] Beanstalk component ~~~~~~~~~~~~~~~~~~~ *Available in Camel 2.15* camel-beanstalk project provides a Camel component for job retrieval and post-processing of Beanstalk jobs. You can find the detailed explanation of Beanstalk job lifecycle at??http://github.com/kr/beanstalkd/blob/v1.3/doc/protocol.txt[Beanstalk protocol]. [[Beanstalk-Dependencies]] Dependencies ^^^^^^^^^^^^ Maven users need to add the following dependency to their `pom.xml` [source,xml] ------------------------------------------ org.apache.camel camel-beanstalk ${camel-version} ------------------------------------------ where `${camel-version`} must be replaced by the actual version of Camel (2.15.0 or higher). [[Beanstalk-URIformat]] URI format ^^^^^^^^^^ [source,xml] ------------------------------------------ beanstalk://[host[:port]][/tube][?options] ------------------------------------------ You may omit either??`port`??or both??`host`??and??`port`: for the Beanstalk defaults to be used (???localhost??? and 11300). If you omit??`tube`, Beanstalk component will use the tube with name ???default???. When listening, you may probably want to watch for jobs from several tubes. Just separate them with plus sign, e.g. [source,java] --------------------------------------- beanstalk://localhost:11300/tube1+tube2 --------------------------------------- Tube name will be URL decoded, so if your tube names include special characters like + or ?, you need to URL-encode them appropriately, or use the RAW syntax, see link:how-do-i-configure-endpoints.html[more details here]. By the way, you cannot specify several tubes when you are writing jobs into Beanstalk. [[Beanstalk-options]] Beanstalk options ^^^^^^^^^^^^^^^^^ // component options: START The Beanstalk component supports 1 options which are listed below. {% raw %} [width="100%",cols="2,1m,7",options="header"] |======================================================================= | Name | Java Type | Description | connectionSettingsFactory | ConnectionSettingsFactory | Custom ConnectionSettingsFactory. Specify which ConnectionSettingsFactory to use to make connections to Beanstalkd. Especially useful for unit testing without beanstalkd daemon (you can mock ConnectionSettings) |======================================================================= {% endraw %} // component options: END // endpoint options: START The Beanstalk component supports 27 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | connectionSettings | common | | String | Connection settings host:port/tube | command | common | | BeanstalkCommand | put means to put the job into Beanstalk. Job body is specified in the Camel message body. Job ID will be returned in beanstalk.jobId message header. delete release touch or bury expect Job ID in the message header beanstalk.jobId. Result of the operation is returned in beanstalk.result message header kick expects the number of jobs to kick in the message body and returns the number of jobs actually kicked out in the message header beanstalk.result. | jobDelay | common | 0 | int | Job delay in seconds. | jobPriority | common | 1000 | long | Job priority. (0 is the highest see Beanstalk protocol) | jobTimeToRun | common | 60 | int | Job time to run in seconds. (when 0 the beanstalkd daemon raises it to 1 automatically see Beanstalk protocol) | awaitJob | consumer | true | boolean | Whether to wait for job to complete before ack the job from beanstalk | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | onFailure | consumer | | BeanstalkCommand | Command to use when processing failed. | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead. | useBlockIO | consumer | true | boolean | Whether to use blockIO. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange. | pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). | backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in. | backoffIdleThreshold | scheduler | | int | The number of subsequent idle polls that should happen before the backoffMultipler should kick-in. | backoffMultiplier | scheduler | | int | To let the scheduled polling consumer backoff if there has been a number of subsequent idles/errors in a row. The multiplier is then the number of polls that will be skipped before the next actual attempt is happening again. When this option is in use then backoffIdleThreshold and/or backoffErrorThreshold must also be configured. | delay | scheduler | 500 | long | Milliseconds before the next poll. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | greedy | scheduler | false | boolean | If greedy is enabled then the ScheduledPollConsumer will run immediately again if the previous run polled 1 or more messages. | initialDelay | scheduler | 1000 | long | Milliseconds before the first poll starts. You can also specify time values using units such as 60s (60 seconds) 5m30s (5 minutes and 30 seconds) and 1h (1 hour). | runLoggingLevel | scheduler | TRACE | LoggingLevel | The consumer logs a start/complete log line when it polls. This option allows you to configure the logging level for that. | scheduledExecutorService | scheduler | | ScheduledExecutorService | Allows for configuring a custom/shared thread pool to use for the consumer. By default each consumer has its own single threaded thread pool. | scheduler | scheduler | none | ScheduledPollConsumerScheduler | To use a cron scheduler from either camel-spring or camel-quartz2 component | schedulerProperties | scheduler | | Map | To configure additional properties when using a custom scheduler or any of the Quartz2 Spring based scheduler. | startScheduler | scheduler | true | boolean | Whether the scheduler should be auto started. | timeUnit | scheduler | MILLISECONDS | TimeUnit | Time unit for initialDelay and delay options. | useFixedDelay | scheduler | true | boolean | Controls if fixed delay or fixed rate is used. See ScheduledExecutorService in JDK for details. |======================================================================= {% endraw %} // endpoint options: END Producer??behavior??is affected by the??`command`??parameter which tells what to do with the job, it can be The consumer may delete the job immediately after reserving it or wait until Camel routes process it. While the first scenario is more like a ???message queue???, the second is similar to ???job queue???. This behavior is controlled by??`consumer.awaitJob`??parameter, which equals??`true`??by default (following Beanstalkd nature). When synchronous, the consumer calls??`delete`??on successful job completion and calls??`bury`??on failure. You can choose which command to execute in the case of failure by specifying??`consumer.onFailure`??parameter in the URI. It can take values of??`bury`,??`delete`??or??`release`. There is a boolean parameter??`consumer.useBlockIO`??which corresponds to the same parameter in JavaBeanstalkClient library. By default it is??`true`. Be careful when specifying??`release`, as the failed job will immediately become available in the same tube and your consumer will try to acquire it again. You can??`release`??and specify??_jobDelay_??though. The beanstalk consumer is a??Scheduled??link:polling-consumer.html[Polling Consumer] which means there is more options you can configure, such as how frequent the consumer should poll. For more details see??link:polling-consumer.html[Polling Consumer]. [[Beanstalk-ConsumerHeaders]] Consumer Headers ^^^^^^^^^^^^^^^^ The consumer stores a number of job headers in the Exchange message: [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= |Property |Type |Description |_beanstalk.jobId_ |long | Job ID |_beanstalk.tube_ |string |the name of the tube that contains this job |_beanstalk.state_ |string |???ready??? or ???delayed??? or ???reserved??? or ???buried??? (must be ???reserved???) |_beanstalk.priority_ |long |the priority value set |_beanstalk.age_ |int |the time in seconds since the put command that created this job |_beanstalk.time-left_ |int |the number of seconds left until the server puts this job into the ready queue |_beanstalk.timeouts_ |int |the number of times this job has timed out during a reservation |_beanstalk.releases_ |int |the number of times a client has released this job from a reservation |_beanstalk.buries_ |int |the number of times this job has been buried |_beanstalk.kicks_ |int |the number of times this job has been kicked |======================================================================= [[Beanstalk-Examples]] Examples ^^^^^^^^ This Camel component lets you both request the jobs for processing and supply them to Beanstalkd daemon. Our simple demo routes may look like [source,java] ---------------------------------------------------------------------------------------------- from("beanstalk:testTube"). log("Processing job #${property.beanstalk.jobId} with body ${in.body}"). process(new Processor() { @Override public void process(Exchange exchange) { // try to make integer value out of body exchange.getIn().setBody( Integer.valueOf(exchange.getIn().getBody(classOf[String])) ); } }). log("Parsed job #${property.beanstalk.jobId} to body ${in.body}"); ---------------------------------------------------------------------------------------------- [source,java] --------------------------------------------------------------------- from("timer:dig?period=30seconds"). setBody(constant(10)).log("Kick ${in.body} buried/delayed tasks"). to("beanstalk:testTube?command=kick"); --------------------------------------------------------------------- In the first route we are listening for new jobs in tube ???testTube???. When they are arriving, we are trying to parse integer value from the message body. If done successful, we log it and this successful exchange completion makes Camel component to??_delete_??this job from Beanstalk automatically. Contrary, when we cannot parse the job data, the exchange failed and the Camel component??_buries_??it by default, so that it can be processed later or probably we are going to inspect failed jobs manually. So the second route periodically requests Beanstalk to??_kick_??10 jobs out of buried and/or delayed state to the normal queue. ?? [[Beanstalk-SeeAlso]] See Also ^^^^^^^^ * link:configuring-camel.html[Configuring Camel] * link:component.html[Component] * link:endpoint.html[Endpoint] * link:getting-started.html[Getting Started] - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-binding version: 1.1.24 group: io.fabric8.funktion.connector name: binding data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: binding spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: binding spec: containers: - image: fabric8/connector-binding:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: binding syntax: binding:bindingName:delegateUri title: Binding description: The binding component is used for as a of wrapping an Endpoint in a contract with a data format. label: core,transformation deprecated: false async: false javaType: org.apache.camel.component.binding.BindingNameComponent groupId: org.apache.camel artifactId: camel-core version: 2.18.1 componentProperties: {} properties: bindingName: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Name of the binding to lookup in the Camel registry. delegateUri: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: Uri of the delegate endpoint. bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the default exchange pattern when creating an exchange. synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). documentation.adoc: | [[Binding-Binding]] Binding ------- In Camel terms a _binding_ is a way of wrapping an link:endpoint.html[Endpoint] in a contract; such as a link:data-format.html[Data Format], a link:content-enricher.html[Content Enricher] or validation step. Bindings are completely optional and you can choose to use them on any link:components.html[camel endpoint]. Bindings are inspired by the work of http://www.jboss.org/switchyard[SwitchYard project] adding service contracts to various technologies like Camel and many others. But rather than the SwitchYard approach of wrapping Camel in SCA, _Camel Bindings_ provide a way of wrapping Camel endpoints with contracts inside the Camel framework itself; so you can use them easily inside any Camel route. [[Binding-Options]] Options ^^^^^^^ // component options: START The Binding component has no options. // component options: END // endpoint options: START The Binding component supports 6 endpoint options which are listed below: {% raw %} [width="100%",cols="2,1,1m,1m,5",options="header"] |======================================================================= | Name | Group | Default | Java Type | Description | bindingName | common | | String | *Required* Name of the binding to lookup in the Camel registry. | delegateUri | common | | String | *Required* Uri of the delegate endpoint. | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. | exceptionHandler | consumer (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. | exchangePattern | consumer (advanced) | | ExchangePattern | Sets the default exchange pattern when creating an exchange. | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). |======================================================================= {% endraw %} // endpoint options: END [[Binding-UsingBindings]] Using Bindings ~~~~~~~~~~~~~~ A Binding is currently a bean which defines the contract (though we'll hopefully add bindings to the Camel DSL). There are a few approaches to defining a bound endpoint (i.e. an endpoint bound with a Binding). [[Binding-UsingthebindingURI]] Using the binding URI ^^^^^^^^^^^^^^^^^^^^^ You can prefix any endpoint URI with *binding:nameOfBinding:* where _nameOfBinding_ is the name of the Binding bean in your registry. [source,java] ------------------------------------------------------------------------------ from("binding:jaxb:activemq:myQueue").to("binding:jaxb:activemq:anotherQueue") ------------------------------------------------------------------------------ Here we are using the "jaxb" binding which may, for example, use the JAXB link:data-format.html[Data Format] to marshal and unmarshal messages. [[Binding-UsingaBindingComponent]] Using a BindingComponent ^^^^^^^^^^^^^^^^^^^^^^^^ There is a link:component.html[Component] called BindingComponent which can be configured in your link:registry.html[Registry] by dependency injection which allows the creation of endpoints which are already bound to some binding. For example if you registered a new component called "jsonmq" in your registry using code like this [source,java] ----------------------------------------------------------------------------------------------------- JacksonDataFormat format = new JacksonDataFormat(MyBean.class); context.bind("jsonmq", new BindingComponent(new DataFormatBinding(format), "activemq:foo.")); ----------------------------------------------------------------------------------------------------- Then you could use the endpoint as if it were any other endpoint. [source,java] ------------------------------------------------ from("jsonmq:myQueue").to("jsonmq:anotherQueue") ------------------------------------------------ which would be using the queueus "foo.myQueue" and "foo.anotherQueue" and would use the given Jackson link:data-format.html[Data Format] to marshal on and off the queue. [[Binding-WhentouseBindings]] When to use Bindings ~~~~~~~~~~~~~~~~~~~~ If you only use an endpoint once in a single route; a binding may actually be more complex and more work than just using the 'raw' endpoint directly and using explicit marshalling and validation in the camel route as normal. However bindings can help when you are composing many routes together; or using a single route as a 'template' that is configured input and output endpoints; bindings then provide a nice way to wrap up a contract and endpoint together. Another good use case for bindings is when you are using many endpoints which use the same binding; rather than always having to mention a specific data format or validation rule, you can just use the BindingComponent to wrap the endpoints in the binding of your choice. So bindings are a composition tool really; only use them when they make sense - the extra complexity may not be worth it unless you have lots of routes or endpoints. - apiVersion: v1 kind: ConfigMap metadata: labels: funktion.fabric8.io/kind: Connector provider: fabric8 project: connector-box version: 1.1.24 group: io.fabric8.funktion.connector name: box data: deployment.yml: | --- apiVersion: extensions/v1beta1 kind: Deployment metadata: labels: funktion.fabric8.io/kind: Subscription connector: box spec: replicas: 1 template: metadata: labels: funktion.fabric8.io/kind: Subscription connector: box spec: containers: - image: fabric8/connector-box:1.1.24 name: connector schema.yml: | --- component: kind: component scheme: box syntax: box:apiName/methodName title: Box description: For uploading downloading and managing files folders groups collaborations etc on box DOT com. label: api,file,cloud deprecated: false async: false lenientProperties: true javaType: org.apache.camel.component.box.BoxComponent groupId: org.apache.camel artifactId: camel-box version: 2.18.1 componentProperties: configuration: kind: property type: object javaType: org.apache.camel.component.box.BoxConfiguration deprecated: false secret: false description: To use the shared configuration properties: apiName: kind: path group: common required: true type: string javaType: org.apache.camel.component.box.internal.BoxApiName enum: - COLLABORATIONS - COMMENTS - EVENTS - FILES - FOLDERS - GROUPS - POLL_EVENTS - SEARCH - SHARED_COMMENTS - SHARED_FILES - SHARED_FOLDERS - SHARED_ITEMS - USERS deprecated: false secret: false description: What kind of operation to perform methodName: kind: path group: common required: true type: string javaType: java.lang.String deprecated: false secret: false description: What sub operation to use for the selected operation clientId: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Box application client ID inBody: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Sets the name of a parameter to be passed in the exchange In Body loginTimeout: kind: parameter group: common type: integer javaType: int deprecated: false secret: false defaultValue: "30" description: Amount of time the component will wait for a response from Box.com default is 30 seconds revokeOnShutdown: kind: parameter group: common type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Flag to revoke OAuth refresh token on route shutdown default false. Will require a fresh refresh token on restart using either a custom IAuthSecureStorage or automatic component login by providing a user password sharedLink: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Box shared link for shared endpoints can be a link for a shared comment file or folder sharedPassword: kind: parameter group: common type: string javaType: java.lang.String deprecated: false secret: false description: Password associated with the shared link MUST be provided with sharedLink bridgeErrorHandler: kind: parameter group: consumer label: consumer type: boolean javaType: boolean optionalPrefix: consumer. deprecated: false secret: false defaultValue: false description: Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN/ERROR level and ignored. exceptionHandler: kind: parameter group: consumer (advanced) label: consumer,advanced type: object javaType: org.apache.camel.spi.ExceptionHandler optionalPrefix: consumer. deprecated: false secret: false description: To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN/ERROR level and ignored. exchangePattern: kind: parameter group: consumer (advanced) label: consumer,advanced type: string javaType: org.apache.camel.ExchangePattern enum: - InOnly - RobustInOnly - InOut - InOptionalOut - OutOnly - RobustOutOnly - OutIn - OutOptionalIn deprecated: false secret: false description: Sets the exchange pattern when the consumer creates an exchange. boxConfig: kind: parameter group: advanced label: advanced type: object javaType: com.box.boxjavalibv2.IBoxConfig deprecated: false secret: false description: Custom Box SDK configuration not required normally connectionManagerBuilder: kind: parameter group: advanced label: advanced type: object javaType: com.box.boxjavalibv2.BoxConnectionManagerBuilder deprecated: false secret: false description: Custom Box connection manager builder used to override default settings like max connections for underlying HttpClient. httpParams: kind: parameter group: advanced label: advanced type: object javaType: java.util.Map deprecated: false secret: false description: Custom HTTP params for settings like proxy host refreshListener: kind: parameter group: advanced label: advanced type: object javaType: com.box.boxjavalibv2.authorization.OAuthRefreshListener deprecated: false secret: false description: OAuth listener for token updates if the Camel application needs to use the access token outside the route synchronous: kind: parameter group: advanced label: advanced type: boolean javaType: boolean deprecated: false secret: false defaultValue: false description: Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported). authSecureStorage: kind: parameter group: security label: advanced,security type: object javaType: com.box.boxjavalibv2.authorization.IAuthSecureStorage deprecated: false secret: false description: OAuth Secure Storage callback can be used to provide and or save OAuth tokens. The callback may return null on first call to allow the component to login and authorize application and obtain an OAuth token which can then be saved in the secure storage. For the component to be able to create a token automatically a user password must be provided. clientSecret: kind: parameter group: security label: security type: string javaType: java.lang.String deprecated: false secret: true description: Box application client secret sslContextParameters: kind: parameter group: security label: security type: object javaType: org.apache.camel.util.jsse.SSLContextParameters deprecated: false secret: false description: To configure security using SSLContextParameters. userName: kind: parameter group: security label: security type: string javaType: java.lang.String deprecated: false secret: true description: Box user name MUST be provided userPassword: kind: parameter group: security label: security type: string javaType: java.lang.String deprecated: false secret: true description: Box user password MUST be provided if authSecureStorage is not set or returns null on first call documentation.adoc: "[[Box-BoxComponent]]\nBox Component\n~~~~~~~~~~~~~\n\n*Available\ \ as of Camel 2.14*\n\nThe Box component provides access to all of the Box.com\ \ APIs accessible\nusing https://github.com/box/box-java-sdk-v2/[box-java-sdk-v2].\ \ It\nallows producing messages to upload and download files, create, edit,\n\ and manage folders, etc. It also supports APIs that allow polling for\nupdates\ \ to user accounts and even changes to enterprise accounts, etc.\n\nBox.com\ \ requires the use of OAuth2.0 for all client application\nauthentication. In\ \ order to use camel-box with your account, you'll need\nto create a new application\ \ within Box.com at\nhttps://app.box.com/developers/services/edit/[https://app.box.com/developers/services/edit/].\n\ The Box application's client id and secret will allow access to Box APIs\nwhich\ \ require a current user. A user access token is generated and\nmanaged by the\ \ API for an end user. Alternatively the Camel application\ncan register an\ \ implementation\nof??com.box.boxjavalibv2.authorization.IAuthSecureStorage\ \ to provide\nan??com.box.boxjavalibv2.dao.IAuthData OAuth token.\n\nMaven users\ \ will need to add the following dependency to their pom.xml\nfor this component:\n\ \n[source,java]\n-------------------------------------------\n \n\ \ org.apache.camel\n camel-box\n\ \ ${camel-version}\n \n-------------------------------------------\n\ \n[[Box-Options]]\nBox Options\n^^^^^^^^^^^\n\n\n\n\n\n// component options:\ \ START\nThe Box component supports 1 options which are listed below.\n\n\n\n\ {% raw %}\n[width=\"100%\",cols=\"2,1m,7\",options=\"header\"]\n|=======================================================================\n\ | Name | Java Type | Description\n| configuration | BoxConfiguration | To use\ \ the shared configuration\n|=======================================================================\n\ {% endraw %}\n// component options: END\n\n\n\n\n\n\n\n// endpoint options:\ \ START\nThe Box component supports 21 endpoint options which are listed below:\n\ \n{% raw %}\n[width=\"100%\",cols=\"2,1,1m,1m,5\",options=\"header\"]\n|=======================================================================\n\ | Name | Group | Default | Java Type | Description\n| apiName | common | |\ \ BoxApiName | *Required* What kind of operation to perform\n| methodName |\ \ common | | String | *Required* What sub operation to use for the selected\ \ operation\n| clientId | common | | String | Box application client ID\n|\ \ inBody | common | | String | Sets the name of a parameter to be passed in\ \ the exchange In Body\n| loginTimeout | common | 30 | int | Amount of time\ \ the component will wait for a response from Box.com default is 30 seconds\n\ | revokeOnShutdown | common | false | boolean | Flag to revoke OAuth refresh\ \ token on route shutdown default false. Will require a fresh refresh token\ \ on restart using either a custom IAuthSecureStorage or automatic component\ \ login by providing a user password\n| sharedLink | common | | String | Box\ \ shared link for shared endpoints can be a link for a shared comment file or\ \ folder\n| sharedPassword | common | | String | Password associated with the\ \ shared link MUST be provided with sharedLink\n| bridgeErrorHandler | consumer\ \ | false | boolean | Allows for bridging the consumer to the Camel routing\ \ Error Handler which mean any exceptions occurred while the consumer is trying\ \ to pickup incoming messages or the likes will now be processed as a message\ \ and handled by the routing Error Handler. By default the consumer will use\ \ the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will\ \ be logged at WARN/ERROR level and ignored.\n| exceptionHandler | consumer\ \ (advanced) | | ExceptionHandler | To let the consumer use a custom ExceptionHandler.\ \ Notice if the option bridgeErrorHandler is enabled then this options is not\ \ in use. By default the consumer will deal with exceptions that will be logged\ \ at WARN/ERROR level and ignored.\n| exchangePattern | consumer (advanced)\ \ | | ExchangePattern | Sets the exchange pattern when the consumer creates\ \ an exchange.\n| boxConfig | advanced | | IBoxConfig | Custom Box SDK configuration\ \ not required normally\n| connectionManagerBuilder | advanced | | BoxConnectionManagerBuilder\ \ | Custom Box connection manager builder used to override default settings\ \ like max connections for underlying HttpClient.\n| httpParams | advanced |\ \ | Map | Custom HTTP params for settings like proxy host\n| refreshListener\ \ | advanced | | OAuthRefreshListener | OAuth listener for token updates if\ \ the Camel application needs to use the access token outside the route\n| synchronous\ \ | advanced | false | boolean | Sets whether synchronous processing should\ \ be strictly used or Camel is allowed to use asynchronous processing (if supported).\n\ | authSecureStorage | security | | IAuthSecureStorage | OAuth Secure Storage\ \ callback can be used to provide and or save OAuth tokens. The callback may\ \ return null on first call to allow the component to login and authorize application\ \ and obtain an OAuth token which can then be saved in the secure storage. For\ \ the component to be able to create a token automatically a user password must\ \ be provided.\n| clientSecret | security | | String | Box application client\ \ secret\n| sslContextParameters | security | | SSLContextParameters | To configure\ \ security using SSLContextParameters.\n| userName | security | | String |\ \ Box user name MUST be provided\n| userPassword | security | | String | Box\ \ user password MUST be provided if authSecureStorage is not set or returns\ \ null on first call\n|=======================================================================\n\ {% endraw %}\n// endpoint options: END\n\n\n\n[[Box-URIformat]]\nURI format\n\ ^^^^^^^^^^\n\n[source,java]\n--------------------------------------------\n\ \ box://endpoint-prefix/endpoint?[options]\n--------------------------------------------\n\ \nEndpoint prefix can be one of:\n\n* collaborations\n* comments\n* events\n\ * files\n* folders\n* groups\n* poll-events\n* search\n* shared-comments\n*\ \ shared-files\n* shared-folders\n* shared-items\n* users\n\n[[Box-BoxComponent.1]]\n\ BoxComponent\n^^^^^^^^^^^^\n\nThe Box Component can be configured with the options\ \ below. These\noptions can be provided using the component's bean\nproperty??*`configuration`*??of\n\ type??*`org.apache.camel.component.box.BoxConfiguration`*. These options\ncan\ \ also be specified in the endpoint URI.??\n\n[width=\"100%\",cols=\"10%,10%,80%\"\ ,options=\"header\",]\n|=======================================================================\n\ |Option |Type |Description\n\n|authSecureStorage |com.box.boxjavalibv2.authorization.IAuthSecureStorage\ \ |OAuth Secure Storage callback, can be used to provide and or save OAuth\n\ tokens. The callback may return null on first call to allow the\ncomponent to\ \ login and authorize application and obtain an OAuth token,\nwhich can then\ \ be saved in the secure storage. For the component to be\nable to create a\ \ token automatically a user password must be provided.\n\n|boxConfig |com.box.boxjavalibv2.IBoxConfig\ \ |Custom Box SDK configuration, not required normally\n\n|clientId |String\ \ |Box application client ID\n\n|clientSecret |String |Box application client\ \ secret\n\n|connectionManagerBuilder |com.box.boxjavalibv2.BoxConnectionManagerBuilder\ \ |Custom Box connection manager builder, used to override default settings\n\ like max connections for underlying HttpClient.\n\n|httpParams |java.util.Map\ \ |Custom HTTP params for settings like proxy host\n\n|loginTimeout |int |amount\ \ of time the component will wait for a response from Box.com,\ndefault is 30\ \ seconds\n\n|refreshListener |com.box.boxjavalibv2.authorization.OAuthRefreshListener\ \ |OAuth listener for token updates, if the Camel application needs to use\n\ the access token outside the route\n\n|revokeOnShutdown |boolean |Flag to revoke\ \ OAuth refresh token on route shutdown, default false.\nWill require a fresh\ \ refresh token on restart using either a custom\nIAuthSecureStorage or automatic\ \ component login by providing a user\npassword\n\n|sharedLink |String |Box\ \ shared link for shared-* endpoints, can be a link for a shared\ncomment, file\ \ or folder\n\n|sharedPassword |String |Password associated with the shared\ \ link, MUST be provided with\nsharedLink\n\n|userName |String |Box user name,\ \ MUST be provided\n\n|userPassword |String |Box user password, MUST be provided\ \ if authSecureStorage is not set, or\nreturns null on first call\n|=======================================================================\n\ \n[[Box-ProducerEndpoints:]]\nProducer Endpoints:\n^^^^^^^^^^^^^^^^^^^\n\nProducer\ \ endpoints can use endpoint prefixes followed by endpoint names\nand associated\ \ options described next. A shorthand alias can be used for\nsome endpoints.\ \ The endpoint URI MUST contain a prefix.\n\nEndpoint options that are not mandatory\ \ are denoted by *[]*. When there\nare no mandatory options for an endpoint,\ \ one of the set of *[]* options\nMUST be provided. Producer endpoints can also\ \ use a special\noption??*`inBody`*??that in turn should contain the name of\ \ the endpoint\noption whose value will be contained in the Camel Exchange In\ \ message.\n\nAny of the endpoint options can be provided in either the endpoint\ \ URI,\nor dynamically in a message header. The message header name must be\ \ of\nthe format??*`CamelBox.