You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2016/08/16 08:04:07 UTC

[43/51] [partial] camel git commit: CAMEL-9541: Use -component as suffix for component docs.

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/validator-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/validator-component.adoc b/camel-core/src/main/docs/validator-component.adoc
new file mode 100644
index 0000000..d653861
--- /dev/null
+++ b/camel-core/src/main/docs/validator-component.adoc
@@ -0,0 +1,129 @@
+[[Validation-ValidationComponent]]
+Validation Component
+~~~~~~~~~~~~~~~~~~~~
+
+The Validation component performs XML validation of the message body
+using the JAXP Validation API and based on any of the supported XML
+schema languages, which defaults to http://www.w3.org/XML/Schema[XML
+Schema]
+
+Note that the link:jing.html[Jing] component also supports the following
+useful schema languages:
+
+* http://relaxng.org/compact-tutorial-20030326.html[RelaxNG Compact
+Syntax]
+* http://relaxng.org/[RelaxNG XML Syntax]
+
+The link:msv.html[MSV] component also supports
+http://relaxng.org/[RelaxNG XML Syntax].
+
+[[Validation-URIformat]]
+URI format
+^^^^^^^^^^
+
+[source,java]
+-----------------------------------
+validator:someLocalOrRemoteResource
+-----------------------------------
+
+Where *someLocalOrRemoteResource* is some URL to a local resource on the
+classpath or a full URL to a remote resource or resource on the file
+system which contains the XSD to validate against. For example:
+
+* `msv:org/foo/bar.xsd`
+* `msv:file:../foo/bar.xsd`
+* `msv:http://acme.com/cheese.xsd`
+* `validator:com/mypackage/myschema.xsd`
+
+Maven users will need to add the following dependency to their `pom.xml`
+for this component when using *Camel 2.8* or older:
+
+[source,xml]
+------------------------------------------------------------
+<dependency>
+    <groupId>org.apache.camel</groupId>
+    <artifactId>camel-spring</artifactId>
+    <version>x.x.x</version>
+    <!-- use the same version as your Camel core version -->
+</dependency>
+------------------------------------------------------------
+
+From Camel 2.9 onwards the link:validation.html[Validation] component is
+provided directly in the camel-core.
+
+[[Validation-Options]]
+Options
+^^^^^^^
+
+
+// component options: START
+The Validator component supports 1 options which are listed below.
+
+
+
+{% raw %}
+[width="100%",cols="2s,1m,8",options="header"]
+|=======================================================================
+| Name | Java Type | Description
+| resourceResolverFactory | ValidatorResourceResolverFactory | To use a custom LSResourceResolver which depends on a dynamic endpoint resource URI
+|=======================================================================
+{% endraw %}
+// component options: END
+
+
+
+// endpoint options: START
+The Validator component supports 13 endpoint options which are listed below:
+
+{% raw %}
+[width="100%",cols="2s,1,1m,1m,5",options="header"]
+|=======================================================================
+| Name | Group | Default | Java Type | Description
+| resourceUri | producer |  | String | *Required* URL to a local resource on the classpathor a reference to lookup a bean in the Registry or a full URL to a remote resource or resource on the file system which contains the XSD to validate against.
+| failOnNullBody | producer | true | boolean | Whether to fail if no body exists.
+| failOnNullHeader | producer | true | boolean | Whether to fail if no header exists when validating against a header.
+| headerName | producer |  | String | To validate against a header instead of the message body.
+| errorHandler | advanced |  | ValidatorErrorHandler | To use a custom org.apache.camel.processor.validation.ValidatorErrorHandler. The default error handler captures the errors and throws an exception.
+| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
+| resourceResolver | advanced |  | LSResourceResolver | To use a custom LSResourceResolver. See also link setResourceResolverFactory(ValidatorResourceResolverFactory)
+| resourceResolverFactory | advanced |  | ValidatorResourceResolverFactory | For creating a resource resolver which depends on the endpoint resource URI. Must not be used in combination with method link setResourceResolver(LSResourceResolver). If not set then DefaultValidatorResourceResolverFactory is used
+| schemaFactory | advanced |  | SchemaFactory | To use a custom javax.xml.validation.SchemaFactory
+| schemaLanguage | advanced | http://www.w3.org/2001/XMLSchema | String | Configures the W3C XML Schema Namespace URI.
+| synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
+| useDom | advanced | false | boolean | Whether DOMSource/DOMResult or SaxSource/SaxResult should be used by the validator.
+| useSharedSchema | advanced | true | boolean | Whether the Schema instance should be shared or not. This option is introduced to work around a JDK 1.6.x bug. Xerces should not have this issue.
+|=======================================================================
+{% endraw %}
+// endpoint options: END
+
+
+[[Validation-Example]]
+Example
+^^^^^^^
+
+The following
+http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/component/validator/camelContext.xml[example]
+shows how to configure a route from endpoint *direct:start* which then
+goes to one of two endpoints, either *mock:valid* or *mock:invalid*
+based on whether or not the XML matches the given schema (which is
+supplied on the classpath).
+
+[[Validation-Advanced:JMXmethodclearCachedSchema]]
+Advanced: JMX method clearCachedSchema
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Since *Camel 2.17*, you can force that the cached schema in the
+validator endpoint is cleared and reread with the next process call with
+the JMX operation�`clearCachedSchema. `You can also use this method to
+programmatically clear the cache. This method is available on the
+`ValidatorEndpoint `class`.`
+
+[[Validation-SeeAlso]]
+See Also
+^^^^^^^^
+
+* link:configuring-camel.html[Configuring Camel]
+* link:component.html[Component]
+* link:endpoint.html[Endpoint]
+* link:getting-started.html[Getting Started]
+

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/validator.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/validator.adoc b/camel-core/src/main/docs/validator.adoc
deleted file mode 100644
index d653861..0000000
--- a/camel-core/src/main/docs/validator.adoc
+++ /dev/null
@@ -1,129 +0,0 @@
-[[Validation-ValidationComponent]]
-Validation Component
-~~~~~~~~~~~~~~~~~~~~
-
-The Validation component performs XML validation of the message body
-using the JAXP Validation API and based on any of the supported XML
-schema languages, which defaults to http://www.w3.org/XML/Schema[XML
-Schema]
-
-Note that the link:jing.html[Jing] component also supports the following
-useful schema languages:
-
-* http://relaxng.org/compact-tutorial-20030326.html[RelaxNG Compact
-Syntax]
-* http://relaxng.org/[RelaxNG XML Syntax]
-
-The link:msv.html[MSV] component also supports
-http://relaxng.org/[RelaxNG XML Syntax].
-
-[[Validation-URIformat]]
-URI format
-^^^^^^^^^^
-
-[source,java]
------------------------------------
-validator:someLocalOrRemoteResource
------------------------------------
-
-Where *someLocalOrRemoteResource* is some URL to a local resource on the
-classpath or a full URL to a remote resource or resource on the file
-system which contains the XSD to validate against. For example:
-
-* `msv:org/foo/bar.xsd`
-* `msv:file:../foo/bar.xsd`
-* `msv:http://acme.com/cheese.xsd`
-* `validator:com/mypackage/myschema.xsd`
-
-Maven users will need to add the following dependency to their `pom.xml`
-for this component when using *Camel 2.8* or older:
-
-[source,xml]
-------------------------------------------------------------
-<dependency>
-    <groupId>org.apache.camel</groupId>
-    <artifactId>camel-spring</artifactId>
-    <version>x.x.x</version>
-    <!-- use the same version as your Camel core version -->
-</dependency>
-------------------------------------------------------------
-
-From Camel 2.9 onwards the link:validation.html[Validation] component is
-provided directly in the camel-core.
-
-[[Validation-Options]]
-Options
-^^^^^^^
-
-
-// component options: START
-The Validator component supports 1 options which are listed below.
-
-
-
-{% raw %}
-[width="100%",cols="2s,1m,8",options="header"]
-|=======================================================================
-| Name | Java Type | Description
-| resourceResolverFactory | ValidatorResourceResolverFactory | To use a custom LSResourceResolver which depends on a dynamic endpoint resource URI
-|=======================================================================
-{% endraw %}
-// component options: END
-
-
-
-// endpoint options: START
-The Validator component supports 13 endpoint options which are listed below:
-
-{% raw %}
-[width="100%",cols="2s,1,1m,1m,5",options="header"]
-|=======================================================================
-| Name | Group | Default | Java Type | Description
-| resourceUri | producer |  | String | *Required* URL to a local resource on the classpathor a reference to lookup a bean in the Registry or a full URL to a remote resource or resource on the file system which contains the XSD to validate against.
-| failOnNullBody | producer | true | boolean | Whether to fail if no body exists.
-| failOnNullHeader | producer | true | boolean | Whether to fail if no header exists when validating against a header.
-| headerName | producer |  | String | To validate against a header instead of the message body.
-| errorHandler | advanced |  | ValidatorErrorHandler | To use a custom org.apache.camel.processor.validation.ValidatorErrorHandler. The default error handler captures the errors and throws an exception.
-| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
-| resourceResolver | advanced |  | LSResourceResolver | To use a custom LSResourceResolver. See also link setResourceResolverFactory(ValidatorResourceResolverFactory)
-| resourceResolverFactory | advanced |  | ValidatorResourceResolverFactory | For creating a resource resolver which depends on the endpoint resource URI. Must not be used in combination with method link setResourceResolver(LSResourceResolver). If not set then DefaultValidatorResourceResolverFactory is used
-| schemaFactory | advanced |  | SchemaFactory | To use a custom javax.xml.validation.SchemaFactory
-| schemaLanguage | advanced | http://www.w3.org/2001/XMLSchema | String | Configures the W3C XML Schema Namespace URI.
-| synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
-| useDom | advanced | false | boolean | Whether DOMSource/DOMResult or SaxSource/SaxResult should be used by the validator.
-| useSharedSchema | advanced | true | boolean | Whether the Schema instance should be shared or not. This option is introduced to work around a JDK 1.6.x bug. Xerces should not have this issue.
-|=======================================================================
-{% endraw %}
-// endpoint options: END
-
-
-[[Validation-Example]]
-Example
-^^^^^^^
-
-The following
-http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/component/validator/camelContext.xml[example]
-shows how to configure a route from endpoint *direct:start* which then
-goes to one of two endpoints, either *mock:valid* or *mock:invalid*
-based on whether or not the XML matches the given schema (which is
-supplied on the classpath).
-
-[[Validation-Advanced:JMXmethodclearCachedSchema]]
-Advanced: JMX method clearCachedSchema
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-Since *Camel 2.17*, you can force that the cached schema in the
-validator endpoint is cleared and reread with the next process call with
-the JMX operation�`clearCachedSchema. `You can also use this method to
-programmatically clear the cache. This method is available on the
-`ValidatorEndpoint `class`.`
-
-[[Validation-SeeAlso]]
-See Also
-^^^^^^^^
-
-* link:configuring-camel.html[Configuring Camel]
-* link:component.html[Component]
-* link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
-

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/vm-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/vm-component.adoc b/camel-core/src/main/docs/vm-component.adoc
new file mode 100644
index 0000000..c53a717
--- /dev/null
+++ b/camel-core/src/main/docs/vm-component.adoc
@@ -0,0 +1,147 @@
+[[VM-VMComponent]]
+VM Component
+~~~~~~~~~~~~
+
+The *vm:* component provides asynchronous
+http://www.eecs.harvard.edu/~mdw/proj/seda/[SEDA] behavior, exchanging
+messages on a
+http://java.sun.com/j2se/1.5.0/docs/api/java/util/concurrent/BlockingQueue.html[BlockingQueue]
+and invoking consumers in a separate thread pool.
+
+This component differs from the link:seda.html[Seda] component in that
+VM supports communication across CamelContext instances - so you can use
+this mechanism to communicate across web applications (provided that
+`camel-core.jar` is on the `system/boot` classpath).
+
+VM is an extension to the link:seda.html[Seda] component.
+
+[[VM-URIformat]]
+URI format
+^^^^^^^^^^
+
+[source,java]
+----------------------
+vm:queueName[?options]
+----------------------
+
+Where *`queueName`* can be any string to uniquely identify the endpoint
+within the JVM (or at least within the classloader that loaded
+camel-core.jar)
+
+You can append query options to the URI in the following format:
+`?option=value&option=value&...`
+
+*Before Camel 2.3 - Same URI must be used for both producer and
+consumer*
+
+An exactly identical link:vm.html[VM] endpoint URI *must* be used for
+both the producer and the consumer endpoint. Otherwise, Camel will
+create a second link:vm.html[VM] endpoint despite that the `queueName`
+portion of the URI is identical. For example:
+
+[source,java]
+---------------------------------------------------------
+from("direct:foo").to("vm:bar?concurrentConsumers=5");
+
+from("vm:bar?concurrentConsumers=5").to("file://output");
+---------------------------------------------------------
+
+Notice that we have to use the full URI, including options in both the
+producer and consumer.
+
+In Camel 2.4 this has been fixed so that only the queue name must match.
+Using the queue name `bar`, we could rewrite the previous exmple as
+follows:
+
+[source,java]
+---------------------------------------------------------
+from("direct:foo").to("vm:bar");
+
+from("vm:bar?concurrentConsumers=5").to("file://output");
+---------------------------------------------------------
+
+[[VM-Options]]
+Options
+^^^^^^^
+
+
+// component options: START
+The VM component supports 3 options which are listed below.
+
+
+
+{% raw %}
+[width="100%",cols="2s,1m,8",options="header"]
+|=======================================================================
+| Name | Java Type | Description
+| queueSize | int | Sets the default maximum capacity of the SEDA queue (i.e. the number of messages it can hold).
+| concurrentConsumers | int | Sets the default number of concurrent threads processing exchanges.
+| defaultQueueFactory | Exchange> | Sets the default queue factory.
+|=======================================================================
+{% endraw %}
+// component options: END
+
+
+
+// endpoint options: START
+The VM component supports 17 endpoint options which are listed below:
+
+{% raw %}
+[width="100%",cols="2s,1,1m,1m,5",options="header"]
+|=======================================================================
+| Name | Group | Default | Java Type | Description
+| name | common |  | String | *Required* Name of queue
+| size | common | 2147483647 | int | The maximum capacity of the SEDA queue (i.e. the number of messages it can hold).
+| 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.
+| concurrentConsumers | consumer | 1 | int | Number of concurrent threads processing exchanges.
+| 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.
+| limitConcurrentConsumers | consumer (advanced) | true | boolean | Whether to limit the number of concurrentConsumers to the maximum of 500. By default an exception will be thrown if an endpoint is configured with a greater number. You can disable that check by turning this option off.
+| multipleConsumers | consumer (advanced) | false | boolean | Specifies whether multiple consumers are allowed. If enabled you can use SEDA for Publish-Subscribe messaging. That is you can send a message to the SEDA queue and have each consumer receive a copy of the message. When enabled this option should be specified on every consumer endpoint.
+| pollTimeout | consumer (advanced) | 1000 | int | The timeout used when polling. When a timeout occurs the consumer can check whether it is allowed to continue running. Setting a lower value allows the consumer to react more quickly upon shutdown.
+| purgeWhenStopping | consumer (advanced) | false | boolean | Whether to purge the task queue when stopping the consumer/route. This allows to stop faster as any pending messages on the queue is discarded.
+| blockWhenFull | producer | false | boolean | Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted. By default an exception will be thrown stating that the queue is full. By enabling this option the calling thread will instead block and wait until the message can be accepted.
+| discardIfNoConsumers | producer | false | boolean | Whether the producer should discard the message (do not add the message to the queue) when sending to a queue with no active consumers. Only one of the options discardIfNoConsumers and failIfNoConsumers can be enabled at the same time.
+| failIfNoConsumers | producer | false | boolean | Whether the producer should fail by throwing an exception when sending to a queue with no active consumers. Only one of the options discardIfNoConsumers and failIfNoConsumers can be enabled at the same time.
+| timeout | producer | 30000 | long | Timeout (in milliseconds) before a SEDA producer will stop waiting for an asynchronous task to complete. You can disable timeout by using 0 or a negative value.
+| waitForTaskToComplete | producer | IfReplyExpected | WaitForTaskToComplete | Option to specify whether the caller should wait for the async task to complete or not before continuing. The following three options are supported: Always Never or IfReplyExpected. The first two values are self-explanatory. The last value IfReplyExpected will only wait if the message is Request Reply based. The default option is IfReplyExpected.
+| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
+| queue | advanced |  | BlockingQueue | Define the queue instance which will be used by the endpoint. This option is only for rare use-cases where you want to use a custom queue instance.
+| 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
+
+
+See the link:seda.html[Seda] component for options and other important
+usage details as the same rules apply to the link:vm.html[Vm] component.
+
+[[VM-Samples]]
+Samples
+^^^^^^^
+
+In the route below we send exchanges across CamelContext instances to a
+VM queue named `order.email`:
+
+[source,java]
+---------------------------------------------------------------
+from("direct:in").bean(MyOrderBean.class).to("vm:order.email");
+---------------------------------------------------------------
+
+And then we receive exchanges in some other Camel context (such as
+deployed in another `.war` application):
+
+[source,java]
+------------------------------------------------------
+from("vm:order.email").bean(MyOrderEmailSender.class);
+------------------------------------------------------
+
+[[VM-SeeAlso]]
+See Also
+^^^^^^^^
+
+* link:configuring-camel.html[Configuring Camel]
+* link:component.html[Component]
+* link:endpoint.html[Endpoint]
+* link:getting-started.html[Getting Started]
+* link:seda.html[Seda]
+

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/vm.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/vm.adoc b/camel-core/src/main/docs/vm.adoc
deleted file mode 100644
index c53a717..0000000
--- a/camel-core/src/main/docs/vm.adoc
+++ /dev/null
@@ -1,147 +0,0 @@
-[[VM-VMComponent]]
-VM Component
-~~~~~~~~~~~~
-
-The *vm:* component provides asynchronous
-http://www.eecs.harvard.edu/~mdw/proj/seda/[SEDA] behavior, exchanging
-messages on a
-http://java.sun.com/j2se/1.5.0/docs/api/java/util/concurrent/BlockingQueue.html[BlockingQueue]
-and invoking consumers in a separate thread pool.
-
-This component differs from the link:seda.html[Seda] component in that
-VM supports communication across CamelContext instances - so you can use
-this mechanism to communicate across web applications (provided that
-`camel-core.jar` is on the `system/boot` classpath).
-
-VM is an extension to the link:seda.html[Seda] component.
-
-[[VM-URIformat]]
-URI format
-^^^^^^^^^^
-
-[source,java]
-----------------------
-vm:queueName[?options]
-----------------------
-
-Where *`queueName`* can be any string to uniquely identify the endpoint
-within the JVM (or at least within the classloader that loaded
-camel-core.jar)
-
-You can append query options to the URI in the following format:
-`?option=value&option=value&...`
-
-*Before Camel 2.3 - Same URI must be used for both producer and
-consumer*
-
-An exactly identical link:vm.html[VM] endpoint URI *must* be used for
-both the producer and the consumer endpoint. Otherwise, Camel will
-create a second link:vm.html[VM] endpoint despite that the `queueName`
-portion of the URI is identical. For example:
-
-[source,java]
----------------------------------------------------------
-from("direct:foo").to("vm:bar?concurrentConsumers=5");
-
-from("vm:bar?concurrentConsumers=5").to("file://output");
----------------------------------------------------------
-
-Notice that we have to use the full URI, including options in both the
-producer and consumer.
-
-In Camel 2.4 this has been fixed so that only the queue name must match.
-Using the queue name `bar`, we could rewrite the previous exmple as
-follows:
-
-[source,java]
----------------------------------------------------------
-from("direct:foo").to("vm:bar");
-
-from("vm:bar?concurrentConsumers=5").to("file://output");
----------------------------------------------------------
-
-[[VM-Options]]
-Options
-^^^^^^^
-
-
-// component options: START
-The VM component supports 3 options which are listed below.
-
-
-
-{% raw %}
-[width="100%",cols="2s,1m,8",options="header"]
-|=======================================================================
-| Name | Java Type | Description
-| queueSize | int | Sets the default maximum capacity of the SEDA queue (i.e. the number of messages it can hold).
-| concurrentConsumers | int | Sets the default number of concurrent threads processing exchanges.
-| defaultQueueFactory | Exchange> | Sets the default queue factory.
-|=======================================================================
-{% endraw %}
-// component options: END
-
-
-
-// endpoint options: START
-The VM component supports 17 endpoint options which are listed below:
-
-{% raw %}
-[width="100%",cols="2s,1,1m,1m,5",options="header"]
-|=======================================================================
-| Name | Group | Default | Java Type | Description
-| name | common |  | String | *Required* Name of queue
-| size | common | 2147483647 | int | The maximum capacity of the SEDA queue (i.e. the number of messages it can hold).
-| 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.
-| concurrentConsumers | consumer | 1 | int | Number of concurrent threads processing exchanges.
-| 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.
-| limitConcurrentConsumers | consumer (advanced) | true | boolean | Whether to limit the number of concurrentConsumers to the maximum of 500. By default an exception will be thrown if an endpoint is configured with a greater number. You can disable that check by turning this option off.
-| multipleConsumers | consumer (advanced) | false | boolean | Specifies whether multiple consumers are allowed. If enabled you can use SEDA for Publish-Subscribe messaging. That is you can send a message to the SEDA queue and have each consumer receive a copy of the message. When enabled this option should be specified on every consumer endpoint.
-| pollTimeout | consumer (advanced) | 1000 | int | The timeout used when polling. When a timeout occurs the consumer can check whether it is allowed to continue running. Setting a lower value allows the consumer to react more quickly upon shutdown.
-| purgeWhenStopping | consumer (advanced) | false | boolean | Whether to purge the task queue when stopping the consumer/route. This allows to stop faster as any pending messages on the queue is discarded.
-| blockWhenFull | producer | false | boolean | Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer exhausted. By default an exception will be thrown stating that the queue is full. By enabling this option the calling thread will instead block and wait until the message can be accepted.
-| discardIfNoConsumers | producer | false | boolean | Whether the producer should discard the message (do not add the message to the queue) when sending to a queue with no active consumers. Only one of the options discardIfNoConsumers and failIfNoConsumers can be enabled at the same time.
-| failIfNoConsumers | producer | false | boolean | Whether the producer should fail by throwing an exception when sending to a queue with no active consumers. Only one of the options discardIfNoConsumers and failIfNoConsumers can be enabled at the same time.
-| timeout | producer | 30000 | long | Timeout (in milliseconds) before a SEDA producer will stop waiting for an asynchronous task to complete. You can disable timeout by using 0 or a negative value.
-| waitForTaskToComplete | producer | IfReplyExpected | WaitForTaskToComplete | Option to specify whether the caller should wait for the async task to complete or not before continuing. The following three options are supported: Always Never or IfReplyExpected. The first two values are self-explanatory. The last value IfReplyExpected will only wait if the message is Request Reply based. The default option is IfReplyExpected.
-| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
-| queue | advanced |  | BlockingQueue | Define the queue instance which will be used by the endpoint. This option is only for rare use-cases where you want to use a custom queue instance.
-| 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
-
-
-See the link:seda.html[Seda] component for options and other important
-usage details as the same rules apply to the link:vm.html[Vm] component.
-
-[[VM-Samples]]
-Samples
-^^^^^^^
-
-In the route below we send exchanges across CamelContext instances to a
-VM queue named `order.email`:
-
-[source,java]
----------------------------------------------------------------
-from("direct:in").bean(MyOrderBean.class).to("vm:order.email");
----------------------------------------------------------------
-
-And then we receive exchanges in some other Camel context (such as
-deployed in another `.war` application):
-
-[source,java]
-------------------------------------------------------
-from("vm:order.email").bean(MyOrderEmailSender.class);
-------------------------------------------------------
-
-[[VM-SeeAlso]]
-See Also
-^^^^^^^^
-
-* link:configuring-camel.html[Configuring Camel]
-* link:component.html[Component]
-* link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
-* link:seda.html[Seda]
-

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/xslt-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/xslt-component.adoc b/camel-core/src/main/docs/xslt-component.adoc
new file mode 100644
index 0000000..3373031
--- /dev/null
+++ b/camel-core/src/main/docs/xslt-component.adoc
@@ -0,0 +1,455 @@
+[[XSLT-XSLT]]
+XSLT
+~~~~
+
+The *xslt:* component allows you to process a message using an
+http://www.w3.org/TR/xslt[XSLT] template. This can be ideal when using
+link:templating.html[Templating] to generate respopnses for requests.
+
+[[XSLT-URIformat]]
+URI format
+^^^^^^^^^^
+
+[source,java]
+---------------------------
+xslt:templateName[?options]
+---------------------------
+
+Where *templateName* is the classpath-local URI of the template to
+invoke; or the complete URL of the remote template. Refer to the
+http://static.springframework.org/spring/docs/2.5.x/api/org/springframework/core/io/DefaultResourceLoader.html[Spring
+Documentation for more detail of the URI syntax]
+
+You can append query options to the URI in the following format,
+`?option=value&option=value&...`
+
+Here are some example URIs
+
+URI
+
+Description
+
+[source,java]
+-----------------------------
+xslt:com/acme/mytransform.xsl
+-----------------------------
+
+refers to the file com/acme/mytransform.xsl on the classpath
+
+[source,java]
+------------------------
+xslt:file:///foo/bar.xsl
+------------------------
+
+refers to the file /foo/bar.xsl
+
+[source,java]
+-----------------------------------
+xslt:http://acme.com/cheese/foo.xsl
+-----------------------------------
+
+refers to the remote http resource
+
+Maven users will need to add the following dependency to their `pom.xml`
+for this component when using *Camel 2.8* or older:
+
+[source,xml]
+------------------------------------------------------------
+<dependency>
+    <groupId>org.apache.camel</groupId>
+    <artifactId>camel-spring</artifactId>
+    <version>x.x.x</version>
+    <!-- use the same version as your Camel core version -->
+</dependency>
+------------------------------------------------------------
+
+From Camel 2.9 onwards the link:xslt.html[XSLT] component is provided
+directly in the camel-core.
+
+[[XSLT-Options]]
+Options
+^^^^^^^
+
+
+// component options: START
+The XSLT component supports 5 options which are listed below.
+
+
+
+{% raw %}
+[width="100%",cols="2s,1m,8",options="header"]
+|=======================================================================
+| Name | Java Type | Description
+| xmlConverter | XmlConverter | To use a custom implementation of org.apache.camel.converter.jaxp.XmlConverter
+| uriResolverFactory | XsltUriResolverFactory | To use a custom javax.xml.transform.URIResolver which depends on a dynamic endpoint resource URI or which is a subclass of XsltUriResolver. Do not use in combination with uriResolver. See also link setUriResolver(URIResolver).
+| uriResolver | URIResolver | To use a custom javax.xml.transform.URIResolver. Do not use in combination with uriResolverFactory. See also link setUriResolverFactory(XsltUriResolverFactory).
+| contentCache | boolean | Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.
+| saxon | boolean | Whether to use Saxon as the transformerFactoryClass. If enabled then the class net.sf.saxon.TransformerFactoryImpl. You would need to add Saxon to the classpath.
+|=======================================================================
+{% endraw %}
+// component options: END
+
+
+
+// endpoint options: START
+The XSLT component supports 18 endpoint options which are listed below:
+
+{% raw %}
+[width="100%",cols="2s,1,1m,1m,5",options="header"]
+|=======================================================================
+| Name | Group | Default | Java Type | Description
+| resourceUri | producer |  | String | *Required* The name of the template to load from classpath or file system
+| allowStAX | producer | true | boolean | Whether to allow using StAX as the javax.xml.transform.Source.
+| contentCache | producer | true | boolean | Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.
+| deleteOutputFile | producer | false | boolean | If you have output=file then this option dictates whether or not the output file should be deleted when the Exchange is done processing. For example suppose the output file is a temporary file then it can be a good idea to delete it after use.
+| failOnNullBody | producer | true | boolean | Whether or not to throw an exception if the input body is null.
+| output | producer | string | XsltOutput | Option to specify which output type to use. Possible values are: string bytes DOM file. The first three options are all in memory based where as file is streamed directly to a java.io.File. For file you must specify the filename in the IN header with the key Exchange.XSLT_FILE_NAME which is also CamelXsltFileName. Also any paths leading to the filename must be created beforehand otherwise an exception is thrown at runtime.
+| saxon | producer | false | boolean | Whether to use Saxon as the transformerFactoryClass. If enabled then the class net.sf.saxon.TransformerFactoryImpl. You would need to add Saxon to the classpath.
+| transformerCacheSize | producer | 0 | int | The number of javax.xml.transform.Transformer object that are cached for reuse to avoid calls to Template.newTransformer().
+| converter | advanced |  | XmlConverter | To use a custom implementation of org.apache.camel.converter.jaxp.XmlConverter
+| entityResolver | advanced |  | EntityResolver | To use a custom org.xml.sax.EntityResolver with javax.xml.transform.sax.SAXSource.
+| errorListener | advanced |  | ErrorListener | Allows to configure to use a custom javax.xml.transform.ErrorListener. Beware when doing this then the default error listener which captures any errors or fatal errors and store information on the Exchange as properties is not in use. So only use this option for special use-cases.
+| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
+| resultHandlerFactory | advanced |  | ResultHandlerFactory | Allows you to use a custom org.apache.camel.builder.xml.ResultHandlerFactory which is capable of using custom org.apache.camel.builder.xml.ResultHandler types.
+| saxonExtensionFunctions | advanced |  | String | Allows you to use a custom net.sf.saxon.lib.ExtensionFunctionDefinition. You would need to add camel-saxon to the classpath. The function is looked up in the registry where you can comma to separate multiple values to lookup.
+| synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
+| transformerFactory | advanced |  | TransformerFactory | To use a custom XSLT transformer factory
+| transformerFactoryClass | advanced |  | String | To use a custom XSLT transformer factory specified as a FQN class name
+| uriResolver | advanced |  | URIResolver | To use a custom javax.xml.transform.URIResolver
+|=======================================================================
+{% endraw %}
+// endpoint options: END
+
+
+[[XSLT-UsingXSLTendpoints]]
+Using XSLT endpoints
+^^^^^^^^^^^^^^^^^^^^
+
+For example you could use something like
+
+[source,java]
+--------------------------------------
+from("activemq:My.Queue").
+  to("xslt:com/acme/mytransform.xsl");
+--------------------------------------
+
+To use an XSLT template to formulate a response for a message for InOut
+message exchanges (where there is a `JMSReplyTo` header).
+
+If you want to use InOnly and consume the message and send it to another
+destination you could use the following route:
+
+[source,java]
+--------------------------------------
+from("activemq:My.Queue").
+  to("xslt:com/acme/mytransform.xsl").
+  to("activemq:Another.Queue");
+--------------------------------------
+
+[[XSLT-GettingParametersintotheXSLTtoworkwith]]
+Getting Parameters into the XSLT to work with
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+By default, all headers are added as parameters which are available in
+the XSLT. +
+ To do this you will need to declare the parameter so it is then
+_useable_.
+
+[source,xml]
+-------------------------------------------------------------------
+<setHeader headerName="myParam"><constant>42</constant></setHeader>
+<to uri="xslt:MyTransform.xsl"/>
+-------------------------------------------------------------------
+
+And the XSLT just needs to declare it at the top level for it to be
+available:
+
+[source,xml]
+------------------------------
+<xsl: ...... >
+
+   <xsl:param name="myParam"/>
+  
+    <xsl:template ...>
+------------------------------
+
+[[XSLT-SpringXMLversions]]
+Spring XML versions
+^^^^^^^^^^^^^^^^^^^
+
+To use the above examples in Spring XML you would use something like
+
+[source,xml]
+-----------------------------------------------------------------------
+  <camelContext xmlns="http://activemq.apache.org/camel/schema/spring">
+    <route>
+      <from uri="activemq:My.Queue"/>
+      <to uri="xslt:org/apache/camel/spring/processor/example.xsl"/>
+      <to uri="activemq:Another.Queue"/>
+    </route>
+  </camelContext>
+-----------------------------------------------------------------------
+
+There is a
+http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/processor/XsltTest.java[test
+case] along with
+http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/processor/XsltTest-context.xml[its
+Spring XML] if you want a concrete example.
+
+[[XSLT-Usingxsl:include]]
+Using xsl:include
+^^^^^^^^^^^^^^^^^
+
+*Camel 2.2 or older* +
+ If you use xsl:include in your XSL files then in Camel 2.2 or older it
+uses the default `javax.xml.transform.URIResolver` which means it can
+only lookup files from file system, and its does that relative from the
+JVM starting folder.
+
+For example this include:
+
+[source,xml]
+----------------------------------------
+<xsl:include href="staff_template.xsl"/>
+----------------------------------------
+
+Will lookup the `staff_tempkalte.xsl` file from the starting folder
+where the application was started.
+
+*Camel 2.3 or newer*  +
+ Now Camel provides its own implementation of `URIResolver` which allows
+Camel to load included files from the classpath and more intelligent
+than before.
+
+For example this include:
+
+[source,xml]
+----------------------------------------
+<xsl:include href="staff_template.xsl"/>
+----------------------------------------
+
+Will now be located relative from the starting endpoint, which for
+example could be:
+
+[source,java]
+----------------------------------------------------------------------
+.to("xslt:org/apache/camel/component/xslt/staff_include_relative.xsl")
+----------------------------------------------------------------------
+
+Which means Camel will locate the file in the *classpath* as
+`org/apache/camel/component/xslt/staff_template.xsl`. +
+ This allows you to use xsl include and have xsl files located in the
+same folder such as we do in the example
+`org/apache/camel/component/xslt`.
+
+You can use the following two prefixes `classpath:` or `file:` to
+instruct Camel to look either in classpath or file system. If you omit
+the prefix then Camel uses the prefix from the endpoint configuration.
+If that neither has one, then classpath is assumed.
+
+You can also refer back in the paths such as
+
+[source,java]
+-----------------------------------------------------
+    <xsl:include href="../staff_other_template.xsl"/>
+-----------------------------------------------------
+
+Which then will resolve the xsl file under `org/apache/camel/component`.
+
+[[XSLT-Usingxsl:includeanddefaultprefix]]
+Using xsl:include and default prefix
+++++++++++++++++++++++++++++++++++++
+
+When using xsl:include such as:
+
+[source,xml]
+----------------------------------------
+<xsl:include href="staff_template.xsl"/>
+----------------------------------------
+
+Then in Camel 2.10.3 and older, then Camel will use "classpath:" as the
+default prefix, and load the resource from the classpath. This works for
+most cases, but if you configure the starting resource to load from
+file,
+
+[source,java]
+----------------------------------------------------
+.to("xslt:file:etc/xslt/staff_include_relative.xsl")
+----------------------------------------------------
+
+.. then you would have to prefix all your includes with "file:" as well.
+
+[source,xml]
+---------------------------------------------
+<xsl:include href="file:staff_template.xsl"/>
+---------------------------------------------
+
+From Camel 2.10.4 onwards we have made this easier as Camel will use the
+prefix from the endpoint configuration as the default prefix. So from
+Camel 2.10.4 onwards you can do:
+
+[source,xml]
+----------------------------------------
+<xsl:include href="staff_template.xsl"/>
+----------------------------------------
+
+Which will load the staff_template.xsl resource from the file system, as
+the endpoint was configured with "file:" as prefix. +
+ You can still though explicit configure a prefix, and then mix and
+match. And have both file and classpath loading. But that would be
+unusual, as most people either use file or classpath based resources.
+
+[[XSLT-UsingSaxonextensionfunctions]]
+Using Saxon extension functions
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Since Saxon 9.2, writing extension functions has been supplemented by a
+new mechanism, referred to
+as�http://www.saxonica.com/html/documentation/extensibility/integratedfunctions[integrated
+extension functions]�you can now easily use camel:
+
+�
+
+-�Java example:
+
+[source,java]
+---------------------------------------------------------------------------------------------------------------------------------
+SimpleRegistry registry = new SimpleRegistry();
+registry.put("function1", new MyExtensionFunction1());
+registry.put("function2", new MyExtensionFunction2());
+
+CamelContext context = new DefaultCamelContext(registry);
+context.addRoutes(new RouteBuilder() {
+    @Override
+    public void configure() throws Exception {
+        from("direct:start")
+            .to("xslt:org/apache/camel/component/xslt/extensions/extensions.xslt?saxonExtensionFunctions=#function1,#function2");
+    }
+});
+---------------------------------------------------------------------------------------------------------------------------------
+
+�
+
+Spring example:
+
+[source,xml]
+-----------------------------------------------------------------------------------------------------------------------------
+<camelContext xmlns="http://camel.apache.org/schema/spring">
+  <route>
+    <from uri="direct:extensions"/>
+    <to uri="xslt:org/apache/camel/component/xslt/extensions/extensions.xslt?saxonExtensionFunctions=#function1,#function2"/>
+  </route>
+</camelContext>
+
+
+<bean id="function1" class="org.apache.camel.component.xslt.extensions.MyExtensionFunction1"/>
+<bean id="function2" class="org.apache.camel.component.xslt.extensions.MyExtensionFunction2"/>
+-----------------------------------------------------------------------------------------------------------------------------
+
+�
+
+�
+
+[[XSLT-Dynamicstylesheets]]
+Dynamic stylesheets
+^^^^^^^^^^^^^^^^^^^
+
+To provide a dynamic stylesheet at runtime you can define a dynamic URI.
+See�link:how-to-use-a-dynamic-uri-in-to.html[How to use a dynamic URI in
+to()] for more information.
+
+*Available as of Camel 2.9 (removed in 2.11.4, 2.12.3 and 2.13.0)* +
+ Camel provides the `CamelXsltResourceUri` header which you can use to
+define a stylesheet to use instead of what is configured on the endpoint
+URI. This allows you to provide a dynamic stylesheet at runtime.
+
+[[XSLT-Accessingwarnings,errorsandfatalErrorsfromXSLTErrorListener]]
+Accessing warnings, errors and fatalErrors from XSLT ErrorListener
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+*Available as of Camel 2.14*
+
+From Camel 2.14 onwards, any warning/error or fatalError is stored on
+the current Exchange as a property with the
+keys�`Exchange.XSLT_ERROR`,�`Exchange.XSLT_FATAL_ERROR`,
+or�`Exchange.XSLT_WARNING` which allows end users to get hold of any
+errors happening during transformation.
+
+For example in the stylesheet below, we want to terminate if a staff has
+an empty dob field. And to include a custom error message using
+xsl:message.
+
+[source,java]
+---------------------------------------------------------------------------------------
+  <xsl:template match="/">
+    <html>
+      <body>
+        <xsl:for-each select="staff/programmer">
+          <p>Name: <xsl:value-of select="name"/><br />
+            <xsl:if test="dob=''">
+              <xsl:message terminate="yes">Error: DOB is an empty string!</xsl:message>
+            </xsl:if>
+          </p>
+        </xsl:for-each>
+      </body>
+    </html>
+  </xsl:template>
+---------------------------------------------------------------------------------------
+
+This information is not available on the Exchange stored as an Exception
+that contains the message in the `getMessage()` method on the exception.
+The exception is stored on the Exchange as a warning with the
+key�`Exchange.XSLT_WARNING.`
+
+[[XSLT-NotesonusingXSLTandJavaVersions]]
+Notes on using XSLT and Java Versions
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Here are some observations from Sameer, a Camel user, which he kindly
+shared with us:
+
+________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________
+In case anybody faces issues with the XSLT endpoint please review these
+points.
+
+I was trying to use an xslt endpoint for a simple transformation from
+one xml to another using a simple xsl. The output xml kept appearing
+(after the xslt processor in the route) with outermost xml tag with no
+content within.
+
+No explanations show up in the DEBUG logs. On the TRACE logs however I
+did find some error/warning indicating that the XMLConverter bean could
+no be initialized.
+
+After a few hours of cranking my mind, I had to do the following to get
+it to work (thanks to some posts on the users forum that gave some
+clue):
+
+\1. Use the transformerFactory option in the route
+`("xslt:my-transformer.xsl?transformerFactory=tFactory")` with the
+`tFactory` bean having bean defined in the spring context for
+`class="org.apache.xalan.xsltc.trax.TransformerFactoryImpl"`. +
+ 2. Added the Xalan jar into my maven pom.
+
+My guess is that the default xml parsing mechanism supplied within the
+JDK (I am using 1.6.0_03) does not work right in this context and does
+not throw up any error either. When I switched to Xalan this way it
+works. This is not a Camel issue, but might need a mention on the xslt
+component page.
+
+Another note, jdk 1.6.0_03 ships with JAXB 2.0 while Camel needs 2.1.
+One workaround is to add the 2.1 jar to the `jre/lib/endorsed` directory
+for the jvm or as specified by the container.
+
+Hope this post saves newbie Camel riders some time.
+________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________
+
+[[XSLT-SeeAlso]]
+See Also
+^^^^^^^^
+
+* link:configuring-camel.html[Configuring Camel]
+* link:component.html[Component]
+* link:endpoint.html[Endpoint]
+* link:getting-started.html[Getting Started]
+

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/camel-core/src/main/docs/xslt.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/xslt.adoc b/camel-core/src/main/docs/xslt.adoc
deleted file mode 100644
index 3373031..0000000
--- a/camel-core/src/main/docs/xslt.adoc
+++ /dev/null
@@ -1,455 +0,0 @@
-[[XSLT-XSLT]]
-XSLT
-~~~~
-
-The *xslt:* component allows you to process a message using an
-http://www.w3.org/TR/xslt[XSLT] template. This can be ideal when using
-link:templating.html[Templating] to generate respopnses for requests.
-
-[[XSLT-URIformat]]
-URI format
-^^^^^^^^^^
-
-[source,java]
----------------------------
-xslt:templateName[?options]
----------------------------
-
-Where *templateName* is the classpath-local URI of the template to
-invoke; or the complete URL of the remote template. Refer to the
-http://static.springframework.org/spring/docs/2.5.x/api/org/springframework/core/io/DefaultResourceLoader.html[Spring
-Documentation for more detail of the URI syntax]
-
-You can append query options to the URI in the following format,
-`?option=value&option=value&...`
-
-Here are some example URIs
-
-URI
-
-Description
-
-[source,java]
------------------------------
-xslt:com/acme/mytransform.xsl
------------------------------
-
-refers to the file com/acme/mytransform.xsl on the classpath
-
-[source,java]
-------------------------
-xslt:file:///foo/bar.xsl
-------------------------
-
-refers to the file /foo/bar.xsl
-
-[source,java]
------------------------------------
-xslt:http://acme.com/cheese/foo.xsl
------------------------------------
-
-refers to the remote http resource
-
-Maven users will need to add the following dependency to their `pom.xml`
-for this component when using *Camel 2.8* or older:
-
-[source,xml]
-------------------------------------------------------------
-<dependency>
-    <groupId>org.apache.camel</groupId>
-    <artifactId>camel-spring</artifactId>
-    <version>x.x.x</version>
-    <!-- use the same version as your Camel core version -->
-</dependency>
-------------------------------------------------------------
-
-From Camel 2.9 onwards the link:xslt.html[XSLT] component is provided
-directly in the camel-core.
-
-[[XSLT-Options]]
-Options
-^^^^^^^
-
-
-// component options: START
-The XSLT component supports 5 options which are listed below.
-
-
-
-{% raw %}
-[width="100%",cols="2s,1m,8",options="header"]
-|=======================================================================
-| Name | Java Type | Description
-| xmlConverter | XmlConverter | To use a custom implementation of org.apache.camel.converter.jaxp.XmlConverter
-| uriResolverFactory | XsltUriResolverFactory | To use a custom javax.xml.transform.URIResolver which depends on a dynamic endpoint resource URI or which is a subclass of XsltUriResolver. Do not use in combination with uriResolver. See also link setUriResolver(URIResolver).
-| uriResolver | URIResolver | To use a custom javax.xml.transform.URIResolver. Do not use in combination with uriResolverFactory. See also link setUriResolverFactory(XsltUriResolverFactory).
-| contentCache | boolean | Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.
-| saxon | boolean | Whether to use Saxon as the transformerFactoryClass. If enabled then the class net.sf.saxon.TransformerFactoryImpl. You would need to add Saxon to the classpath.
-|=======================================================================
-{% endraw %}
-// component options: END
-
-
-
-// endpoint options: START
-The XSLT component supports 18 endpoint options which are listed below:
-
-{% raw %}
-[width="100%",cols="2s,1,1m,1m,5",options="header"]
-|=======================================================================
-| Name | Group | Default | Java Type | Description
-| resourceUri | producer |  | String | *Required* The name of the template to load from classpath or file system
-| allowStAX | producer | true | boolean | Whether to allow using StAX as the javax.xml.transform.Source.
-| contentCache | producer | true | boolean | Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.
-| deleteOutputFile | producer | false | boolean | If you have output=file then this option dictates whether or not the output file should be deleted when the Exchange is done processing. For example suppose the output file is a temporary file then it can be a good idea to delete it after use.
-| failOnNullBody | producer | true | boolean | Whether or not to throw an exception if the input body is null.
-| output | producer | string | XsltOutput | Option to specify which output type to use. Possible values are: string bytes DOM file. The first three options are all in memory based where as file is streamed directly to a java.io.File. For file you must specify the filename in the IN header with the key Exchange.XSLT_FILE_NAME which is also CamelXsltFileName. Also any paths leading to the filename must be created beforehand otherwise an exception is thrown at runtime.
-| saxon | producer | false | boolean | Whether to use Saxon as the transformerFactoryClass. If enabled then the class net.sf.saxon.TransformerFactoryImpl. You would need to add Saxon to the classpath.
-| transformerCacheSize | producer | 0 | int | The number of javax.xml.transform.Transformer object that are cached for reuse to avoid calls to Template.newTransformer().
-| converter | advanced |  | XmlConverter | To use a custom implementation of org.apache.camel.converter.jaxp.XmlConverter
-| entityResolver | advanced |  | EntityResolver | To use a custom org.xml.sax.EntityResolver with javax.xml.transform.sax.SAXSource.
-| errorListener | advanced |  | ErrorListener | Allows to configure to use a custom javax.xml.transform.ErrorListener. Beware when doing this then the default error listener which captures any errors or fatal errors and store information on the Exchange as properties is not in use. So only use this option for special use-cases.
-| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange.
-| resultHandlerFactory | advanced |  | ResultHandlerFactory | Allows you to use a custom org.apache.camel.builder.xml.ResultHandlerFactory which is capable of using custom org.apache.camel.builder.xml.ResultHandler types.
-| saxonExtensionFunctions | advanced |  | String | Allows you to use a custom net.sf.saxon.lib.ExtensionFunctionDefinition. You would need to add camel-saxon to the classpath. The function is looked up in the registry where you can comma to separate multiple values to lookup.
-| synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
-| transformerFactory | advanced |  | TransformerFactory | To use a custom XSLT transformer factory
-| transformerFactoryClass | advanced |  | String | To use a custom XSLT transformer factory specified as a FQN class name
-| uriResolver | advanced |  | URIResolver | To use a custom javax.xml.transform.URIResolver
-|=======================================================================
-{% endraw %}
-// endpoint options: END
-
-
-[[XSLT-UsingXSLTendpoints]]
-Using XSLT endpoints
-^^^^^^^^^^^^^^^^^^^^
-
-For example you could use something like
-
-[source,java]
---------------------------------------
-from("activemq:My.Queue").
-  to("xslt:com/acme/mytransform.xsl");
---------------------------------------
-
-To use an XSLT template to formulate a response for a message for InOut
-message exchanges (where there is a `JMSReplyTo` header).
-
-If you want to use InOnly and consume the message and send it to another
-destination you could use the following route:
-
-[source,java]
---------------------------------------
-from("activemq:My.Queue").
-  to("xslt:com/acme/mytransform.xsl").
-  to("activemq:Another.Queue");
---------------------------------------
-
-[[XSLT-GettingParametersintotheXSLTtoworkwith]]
-Getting Parameters into the XSLT to work with
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-By default, all headers are added as parameters which are available in
-the XSLT. +
- To do this you will need to declare the parameter so it is then
-_useable_.
-
-[source,xml]
--------------------------------------------------------------------
-<setHeader headerName="myParam"><constant>42</constant></setHeader>
-<to uri="xslt:MyTransform.xsl"/>
--------------------------------------------------------------------
-
-And the XSLT just needs to declare it at the top level for it to be
-available:
-
-[source,xml]
-------------------------------
-<xsl: ...... >
-
-   <xsl:param name="myParam"/>
-  
-    <xsl:template ...>
-------------------------------
-
-[[XSLT-SpringXMLversions]]
-Spring XML versions
-^^^^^^^^^^^^^^^^^^^
-
-To use the above examples in Spring XML you would use something like
-
-[source,xml]
------------------------------------------------------------------------
-  <camelContext xmlns="http://activemq.apache.org/camel/schema/spring">
-    <route>
-      <from uri="activemq:My.Queue"/>
-      <to uri="xslt:org/apache/camel/spring/processor/example.xsl"/>
-      <to uri="activemq:Another.Queue"/>
-    </route>
-  </camelContext>
------------------------------------------------------------------------
-
-There is a
-http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/processor/XsltTest.java[test
-case] along with
-http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/processor/XsltTest-context.xml[its
-Spring XML] if you want a concrete example.
-
-[[XSLT-Usingxsl:include]]
-Using xsl:include
-^^^^^^^^^^^^^^^^^
-
-*Camel 2.2 or older* +
- If you use xsl:include in your XSL files then in Camel 2.2 or older it
-uses the default `javax.xml.transform.URIResolver` which means it can
-only lookup files from file system, and its does that relative from the
-JVM starting folder.
-
-For example this include:
-
-[source,xml]
-----------------------------------------
-<xsl:include href="staff_template.xsl"/>
-----------------------------------------
-
-Will lookup the `staff_tempkalte.xsl` file from the starting folder
-where the application was started.
-
-*Camel 2.3 or newer*  +
- Now Camel provides its own implementation of `URIResolver` which allows
-Camel to load included files from the classpath and more intelligent
-than before.
-
-For example this include:
-
-[source,xml]
-----------------------------------------
-<xsl:include href="staff_template.xsl"/>
-----------------------------------------
-
-Will now be located relative from the starting endpoint, which for
-example could be:
-
-[source,java]
-----------------------------------------------------------------------
-.to("xslt:org/apache/camel/component/xslt/staff_include_relative.xsl")
-----------------------------------------------------------------------
-
-Which means Camel will locate the file in the *classpath* as
-`org/apache/camel/component/xslt/staff_template.xsl`. +
- This allows you to use xsl include and have xsl files located in the
-same folder such as we do in the example
-`org/apache/camel/component/xslt`.
-
-You can use the following two prefixes `classpath:` or `file:` to
-instruct Camel to look either in classpath or file system. If you omit
-the prefix then Camel uses the prefix from the endpoint configuration.
-If that neither has one, then classpath is assumed.
-
-You can also refer back in the paths such as
-
-[source,java]
------------------------------------------------------
-    <xsl:include href="../staff_other_template.xsl"/>
------------------------------------------------------
-
-Which then will resolve the xsl file under `org/apache/camel/component`.
-
-[[XSLT-Usingxsl:includeanddefaultprefix]]
-Using xsl:include and default prefix
-++++++++++++++++++++++++++++++++++++
-
-When using xsl:include such as:
-
-[source,xml]
-----------------------------------------
-<xsl:include href="staff_template.xsl"/>
-----------------------------------------
-
-Then in Camel 2.10.3 and older, then Camel will use "classpath:" as the
-default prefix, and load the resource from the classpath. This works for
-most cases, but if you configure the starting resource to load from
-file,
-
-[source,java]
-----------------------------------------------------
-.to("xslt:file:etc/xslt/staff_include_relative.xsl")
-----------------------------------------------------
-
-.. then you would have to prefix all your includes with "file:" as well.
-
-[source,xml]
----------------------------------------------
-<xsl:include href="file:staff_template.xsl"/>
----------------------------------------------
-
-From Camel 2.10.4 onwards we have made this easier as Camel will use the
-prefix from the endpoint configuration as the default prefix. So from
-Camel 2.10.4 onwards you can do:
-
-[source,xml]
-----------------------------------------
-<xsl:include href="staff_template.xsl"/>
-----------------------------------------
-
-Which will load the staff_template.xsl resource from the file system, as
-the endpoint was configured with "file:" as prefix. +
- You can still though explicit configure a prefix, and then mix and
-match. And have both file and classpath loading. But that would be
-unusual, as most people either use file or classpath based resources.
-
-[[XSLT-UsingSaxonextensionfunctions]]
-Using Saxon extension functions
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-Since Saxon 9.2, writing extension functions has been supplemented by a
-new mechanism, referred to
-as�http://www.saxonica.com/html/documentation/extensibility/integratedfunctions[integrated
-extension functions]�you can now easily use camel:
-
-�
-
--�Java example:
-
-[source,java]
----------------------------------------------------------------------------------------------------------------------------------
-SimpleRegistry registry = new SimpleRegistry();
-registry.put("function1", new MyExtensionFunction1());
-registry.put("function2", new MyExtensionFunction2());
-
-CamelContext context = new DefaultCamelContext(registry);
-context.addRoutes(new RouteBuilder() {
-    @Override
-    public void configure() throws Exception {
-        from("direct:start")
-            .to("xslt:org/apache/camel/component/xslt/extensions/extensions.xslt?saxonExtensionFunctions=#function1,#function2");
-    }
-});
----------------------------------------------------------------------------------------------------------------------------------
-
-�
-
-Spring example:
-
-[source,xml]
------------------------------------------------------------------------------------------------------------------------------
-<camelContext xmlns="http://camel.apache.org/schema/spring">
-  <route>
-    <from uri="direct:extensions"/>
-    <to uri="xslt:org/apache/camel/component/xslt/extensions/extensions.xslt?saxonExtensionFunctions=#function1,#function2"/>
-  </route>
-</camelContext>
-
-
-<bean id="function1" class="org.apache.camel.component.xslt.extensions.MyExtensionFunction1"/>
-<bean id="function2" class="org.apache.camel.component.xslt.extensions.MyExtensionFunction2"/>
------------------------------------------------------------------------------------------------------------------------------
-
-�
-
-�
-
-[[XSLT-Dynamicstylesheets]]
-Dynamic stylesheets
-^^^^^^^^^^^^^^^^^^^
-
-To provide a dynamic stylesheet at runtime you can define a dynamic URI.
-See�link:how-to-use-a-dynamic-uri-in-to.html[How to use a dynamic URI in
-to()] for more information.
-
-*Available as of Camel 2.9 (removed in 2.11.4, 2.12.3 and 2.13.0)* +
- Camel provides the `CamelXsltResourceUri` header which you can use to
-define a stylesheet to use instead of what is configured on the endpoint
-URI. This allows you to provide a dynamic stylesheet at runtime.
-
-[[XSLT-Accessingwarnings,errorsandfatalErrorsfromXSLTErrorListener]]
-Accessing warnings, errors and fatalErrors from XSLT ErrorListener
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-*Available as of Camel 2.14*
-
-From Camel 2.14 onwards, any warning/error or fatalError is stored on
-the current Exchange as a property with the
-keys�`Exchange.XSLT_ERROR`,�`Exchange.XSLT_FATAL_ERROR`,
-or�`Exchange.XSLT_WARNING` which allows end users to get hold of any
-errors happening during transformation.
-
-For example in the stylesheet below, we want to terminate if a staff has
-an empty dob field. And to include a custom error message using
-xsl:message.
-
-[source,java]
----------------------------------------------------------------------------------------
-  <xsl:template match="/">
-    <html>
-      <body>
-        <xsl:for-each select="staff/programmer">
-          <p>Name: <xsl:value-of select="name"/><br />
-            <xsl:if test="dob=''">
-              <xsl:message terminate="yes">Error: DOB is an empty string!</xsl:message>
-            </xsl:if>
-          </p>
-        </xsl:for-each>
-      </body>
-    </html>
-  </xsl:template>
----------------------------------------------------------------------------------------
-
-This information is not available on the Exchange stored as an Exception
-that contains the message in the `getMessage()` method on the exception.
-The exception is stored on the Exchange as a warning with the
-key�`Exchange.XSLT_WARNING.`
-
-[[XSLT-NotesonusingXSLTandJavaVersions]]
-Notes on using XSLT and Java Versions
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-Here are some observations from Sameer, a Camel user, which he kindly
-shared with us:
-
-________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________
-In case anybody faces issues with the XSLT endpoint please review these
-points.
-
-I was trying to use an xslt endpoint for a simple transformation from
-one xml to another using a simple xsl. The output xml kept appearing
-(after the xslt processor in the route) with outermost xml tag with no
-content within.
-
-No explanations show up in the DEBUG logs. On the TRACE logs however I
-did find some error/warning indicating that the XMLConverter bean could
-no be initialized.
-
-After a few hours of cranking my mind, I had to do the following to get
-it to work (thanks to some posts on the users forum that gave some
-clue):
-
-\1. Use the transformerFactory option in the route
-`("xslt:my-transformer.xsl?transformerFactory=tFactory")` with the
-`tFactory` bean having bean defined in the spring context for
-`class="org.apache.xalan.xsltc.trax.TransformerFactoryImpl"`. +
- 2. Added the Xalan jar into my maven pom.
-
-My guess is that the default xml parsing mechanism supplied within the
-JDK (I am using 1.6.0_03) does not work right in this context and does
-not throw up any error either. When I switched to Xalan this way it
-works. This is not a Camel issue, but might need a mention on the xslt
-component page.
-
-Another note, jdk 1.6.0_03 ships with JAXB 2.0 while Camel needs 2.1.
-One workaround is to add the 2.1 jar to the `jre/lib/endorsed` directory
-for the jvm or as specified by the container.
-
-Hope this post saves newbie Camel riders some time.
-________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________
-
-[[XSLT-SeeAlso]]
-See Also
-^^^^^^^^
-
-* link:configuring-camel.html[Configuring Camel]
-* link:component.html[Component]
-* link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
-

http://git-wip-us.apache.org/repos/asf/camel/blob/9c0b7baf/components/camel-ahc-ws/src/main/docs/ahc-ws-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-ahc-ws/src/main/docs/ahc-ws-component.adoc b/components/camel-ahc-ws/src/main/docs/ahc-ws-component.adoc
new file mode 100644
index 0000000..3a9cc36
--- /dev/null
+++ b/components/camel-ahc-ws/src/main/docs/ahc-ws-component.adoc
@@ -0,0 +1,165 @@
+[[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]
+------------------------------------------------------------
+<dependency>
+    <groupId>org.apache.camel</groupId>
+    <artifactId>camel-ahc-ws</artifactId>
+    <version>x.x.x</version>
+    <!-- use the same version as your Camel core version -->
+</dependency>
+------------------------------------------------------------
+
+[[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="2s,1m,8",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="2s,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.
+| 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.
+| exchangePattern | advanced | InOnly | 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).
+| 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]
+------------------------------------------------------------
+<camelContext xmlns="http://camel.apache.org/schema/spring">
+  <route>
+    <from uri="direct:start"/>
+    <to uri="ahc-ws://targethost"/>
+  </route>
+</camelContext>
+------------------------------------------------------------
+
+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]
+------------------------------------------------------------
+<camelContext xmlns="http://camel.apache.org/schema/spring">
+  <route>
+    <from uri="ahc-ws://targethost"/>
+    <to uri="direct:next"/>
+  </route>
+</camelContext>
+------------------------------------------------------------
+
+�
+
+[[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]
+