Author: buildbot
Date: Fri Dec 4 11:19:20 2015
New Revision: 974504
Log:
Production update by buildbot for camel
Modified:
websites/production/camel/content/cache/main.pageCache
websites/production/camel/content/netty-http.html
websites/production/camel/content/netty4-http.html
Modified: websites/production/camel/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.
Modified: websites/production/camel/content/netty-http.html
==============================================================================
--- websites/production/camel/content/netty-http.html (original)
+++ websites/production/camel/content/netty-http.html Fri Dec 4 11:19:20 2015
@@ -96,7 +96,7 @@
</div></div><h3 id="NettyHTTP-URIformat">URI format</h3><p>The URI scheme for
a netty component is as follows</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[netty-http:http://localhost:8080[?options]
]]></script>
-</div></div><p>You can append query options to the URI in the following
format, <code>?option=value&option=value&...</code></p><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">Query parameters vs
endpoint options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p>You may be wondering how Camel
recognizes URI query parameters and endpoint options. For example you might
create endpoint URI as follows -
<code>netty-http:http//example.com?myParam=myValue&compression=true</code>
. In this example <code>myParam</code> is the HTTP parameter, while
<code>compression</code> is the Camel endpoint option. The strategy used by
Camel in such situations is to resolve available endpoint options and remove
them from the URI. It means that for the discussed example, the HTTP request
sent by Netty HTTP producer to the endpoint will look as f
ollows - <code>http//example.com?myParam=myValue</code> , because
<code>compression</code> endpoint option will be resolved and removed from the
target URL.</p><p>Keep also in mind that you cannot specify endpoint options
using dynamic headers (like <code>CamelHttpQuery</code>). Endpoint options can
be specified only at the endpoint URI definition level (like <code>to</code> or
<code>from</code> DSL elements).</p></div></div><h3
id="NettyHTTP-HTTPOptions">HTTP Options</h3><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">A lot more
options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p><strong>Important:</strong> This
component inherits all the options from <a shape="rect"
href="netty.html">Netty</a>. So make sure to look at the <a shape="rect"
href="netty.html">Netty</a> documentation as well.<br clear="none"> Notice that
some
options from <a shape="rect" href="netty.html">Netty</a> is not applicable
when using this <a shape="rect" href="netty-http.html">Netty HTTP</a>
component, such as options related to UDP transport.</p></div></div><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>chunkedMaxContentLength</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>1mb</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Value in bytes the max content
length per chunked frame received on the Netty HTTP
server.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>compression</code></p></td><td colspan="1"
rowspan="1" class="confluenc
eTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allow using gzip/deflate for compression on the Netty
HTTP server if the client supports it from the HTTP
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>headerFilterStrategy</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.spi.HeaderFilterStrategy</code> to filter
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>httpMethodRestrict</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To disable HTTP methods on the Netty HTTP consumer. You
can specify multiple separated by comma.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>mapHeaders</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd">
<p><code>true</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the headers
will be mapped as well (eg added as header to the Camel <a shape="rect"
href="message.html">Message</a> as well). You can turn off this option to
disable this. The headers can still be accessed from the
<code>org.apache.camel.component.netty.http.NettyHttpMessage</code> message
with the method <code>getHttpRequest()</code> that returns the Netty HTTP
request <code>org.jboss.netty.handler.codec.http.HttpRequest</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>matchOnUriPrefix</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Whether or not Camel should try to find a
target consumer by matching the URI prefix if no exact match is found. Se
e further below for more details.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettyHttpBinding</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To use a custom
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> for binding
to/from Netty and Camel Message API.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>bridgeEndpoint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>If the option is
<code>true</code>, the producer will ignore the <code>Exchange.HTTP_URI</code>
header, and use the endpoint's URI for request. You may also set the
<code>throwExceptionOnFailure</code> to be <code>false</code> to let the
producer send all the fault response back. The consumer working in the bridge
mode will skip the gzip compression and WWW URL form
encoding (by adding the <code>Exchange.SKIP_GZIP_ENCODING</code> and
<code>Exchange.SKIP_WWW_FORM_URLENCODED</code> headers to the consumed
exchange).</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>throwExceptionOnFailure</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Option to disable throwing the
<code>HttpOperationFailedException</code> in case of failed responses from the
remote server. This allows you to get all responses regardles of the HTTP
status code.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>traceEnabled</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Specifies whether to enable HTTP TRACE for
this Netty HTTP consumer. By default TRACE is turned off.</p></td></tr><tr><td
colspan="1" rowspan="1" class="confluenceTd"><p>
<code>transferException</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If enabled and an <a shape="rect"
href="exchange.html">Exchange</a> failed processing on the consumer side, and
if the caused Exception was send back serialized in the response as a
<code>application/x-java-serialized-object</code> content type. On the producer
side the exception will be deserialized and thrown as is, instead of the
<code>HttpOperationFailedException</code>. The caused exception is required to
be serialized.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>urlDecodeHeaders</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the header
values will be URL decoded (eg %20 will b
e a space character. Notice this option is used by the default
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> and
therefore if you implement a custom
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> then you
would need to decode the headers accordingly to this option.
<strong>Notice:</strong> This option is default <code>true</code> for Camel
2.12.x, and default <code>false</code> from Camel 2.13
onwards.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettySharedHttpServer</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>To use a shared <a shape="rect"
href="netty-http.html">Netty HTTP</a> server. See <a shape="rect"
href="netty-http-server-example.html">Netty HTTP Server Example</a> for more
details.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>disableStreamCache</code></p></td><td colspan="
1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Determines whether or not the
raw input stream from Netty <code>HttpRequest#getContent()</code> is cached or
not (Camel will read the stream into a in light-weight memory based Stream
caching) cache. By default Camel will cache the Netty 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 <code>true</code> when you for
example need to access the raw stream, such as streaming it directly to a file
or other persistent store. Mind that if you enable this option, then you cannot
read the Netty stream multiple times out of the box, and you would need
manually to reset the reader index on the Netty raw
stream.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConfiguration</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</
code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><strong>Consumer only</strong>. Refers to a
<code>org.apache.camel.component.netty.http.NettyHttpSecurityConfiguration</code>
for configuring secure web resources.</p></td></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>send503whenSuspended</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Whether to send back HTTP status code 503 when the consumer has been suspended.
If the option is <code>false</code> then the Netty Acceptor is unbound when the
consumer is suspended, so clients cannot connect anymore.</p></td></tr><tr><td
colspan="1" rowspan="1" class="confluenceTd"><code>maxHeaderSize</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><code>8192</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><strong>Camel
2.15.3:</strong> <strong>Consumer only.
</strong>The maximum length of all headers. If the sum of the length of each
header exceeds this value, a TooLongFrameException will be
raised.</td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><code>okStatusCodeRange</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>200-299</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.16:</strong><span> 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.</span></td></tr></tbody></table></div></div><p>The
<code>NettyHttpSecurityConfiguration</code> has the following options:</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colsp
an="1" rowspan="1"
class="confluenceTd"><p><code>authenticate</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Whether authentication is enabled. Can be
used to quickly turn this off.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>constraint</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>Basic</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The constraint supported. Currently only
<code>Basic</code> is implemented and supported.</p></td></tr><tr><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>realm</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The name of the JAAS security
realm. This option is mandatory.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConstraint</code></p></
td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>null</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allows to plugin a security constraint mapper where you
can define ACL to web resources.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityAuthenticator</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allows to plugin a
authenticator that performs the authentication. If none has been configured
then the
<code>org.apache.camel.component.netty.http.JAASSecurityAuthenticator</code> is
used by default.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>loginDeniedLoggingLevel</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>DEBUG</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Logging level used when a login
attempt failed, which allows to see more details why th
e login failed.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>roleClassName</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To specify FQN class names of
<code>Principal</code> implementations that contains user roles. If none has
been specified, then the <a shape="rect" href="netty-http.html">Netty HTTP</a>
component will by default assume a <code>Principal</code> is role based if its
FQN classname has the lower-case word <code>role</code> in its classname. You
can specify multiple class names separated by
comma.</p></td></tr></tbody></table></div></div><h3
id="NettyHTTP-MessageHeaders">Message Headers</h3><p>The following headers can
be used on the producer to control the HTTP request.</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th co
lspan="1" rowspan="1" class="confluenceTh"><p>Type</p></th><th colspan="1"
rowspan="1" class="confluenceTh"><p>Description</p></th></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allow to control what HTTP method to use
such as GET, POST, TRACE etc. The type can also be a
<code>org.jboss.netty.handler.codec.http.HttpMethod</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpQuery</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI query parameters as a
<code>String</code> value that overrides the endpoint configuration. Separate
multiple parameters using the & sign. For example:
<code>foo=bar&beer=yes</code>.</p></td></tr><tr><td col
span="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpPath</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><strong>Camel 2.13.1/2.12.4:</strong>
Allows to provide URI context-path and query parameters as a
<code>String</code> value that overrides the endpoint configuration. This
allows to reuse the same producer for calling same remote http server, but
using a dynamic context-path and query parameters.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>Content-Type</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To set the content-type of the HTTP body.
For example: <code>text/plain; charset="UTF-8"</code>.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>CamelHttpResponseCode</code></td><td colspan="1"
rowspan="1" class="confluenceTd">
<code>int</code></td><td colspan="1" rowspan="1" class="confluenceTd">Allows
to set the HTTP Status code to use. By default 200 is used for success, and 500
for failure.</td></tr></tbody></table></div></div><p>The following headers is
provided as meta-data when a route starts from an <a shape="rect"
href="netty-http.html">Netty HTTP</a> endpoint:</p><p>The description in the
table takes offset in a route having:
<code>from("netty-http:http:0.0.0.0:8080/myapp")...</code></p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td
colspan="1" rowspan="1" class="conf
luenceTd"><p>The HTTP method used, such as GET, POST, TRACE
etc.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUrl</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The URL including protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
+</div></div><p>You can append query options to the URI in the following
format, <code>?option=value&option=value&...</code></p><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">Query parameters vs
endpoint options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p>You may be wondering how Camel
recognizes URI query parameters and endpoint options. For example you might
create endpoint URI as follows -
<code>netty-http:http//example.com?myParam=myValue&compression=true</code>
. In this example <code>myParam</code> is the HTTP parameter, while
<code>compression</code> is the Camel endpoint option. The strategy used by
Camel in such situations is to resolve available endpoint options and remove
them from the URI. It means that for the discussed example, the HTTP request
sent by Netty HTTP producer to the endpoint will look as f
ollows - <code>http//example.com?myParam=myValue</code> , because
<code>compression</code> endpoint option will be resolved and removed from the
target URL.</p><p>Keep also in mind that you cannot specify endpoint options
using dynamic headers (like <code>CamelHttpQuery</code>). Endpoint options can
be specified only at the endpoint URI definition level (like <code>to</code> or
<code>from</code> DSL elements).</p></div></div><h3
id="NettyHTTP-HTTPOptions">HTTP Options</h3><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">A lot more
options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p><strong>Important:</strong> This
component inherits all the options from <a shape="rect"
href="netty.html">Netty</a>. So make sure to look at the <a shape="rect"
href="netty.html">Netty</a> documentation as well.<br clear="none"> Notice that
some
options from <a shape="rect" href="netty.html">Netty</a> is not applicable
when using this <a shape="rect" href="netty-http.html">Netty HTTP</a>
component, such as options related to UDP transport.</p></div></div><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>chunkedMaxContentLength</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>1mb</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Value in bytes the max content
length per chunked frame received on the Netty HTTP
server.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>compression</code></p></td><td colspan="1"
rowspan="1" class="confluenc
eTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allow using gzip/deflate for compression on the Netty
HTTP server if the client supports it from the HTTP
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>headerFilterStrategy</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.spi.HeaderFilterStrategy</code> to filter
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>httpMethodRestrict</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To disable HTTP methods on the Netty HTTP consumer. You
can specify multiple separated by comma.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>mapHeaders</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd">
<p><code>true</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the headers
will be mapped as well (eg added as header to the Camel <a shape="rect"
href="message.html">Message</a> as well). You can turn off this option to
disable this. The headers can still be accessed from the
<code>org.apache.camel.component.netty.http.NettyHttpMessage</code> message
with the method <code>getHttpRequest()</code> that returns the Netty HTTP
request <code>org.jboss.netty.handler.codec.http.HttpRequest</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>matchOnUriPrefix</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Whether or not Camel should try to find a
target consumer by matching the URI prefix if no exact match is found. Se
e further below for more details.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettyHttpBinding</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To use a custom
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> for binding
to/from Netty and Camel Message API.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>bridgeEndpoint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>If the option is
<code>true</code>, the producer will ignore the <code>Exchange.HTTP_URI</code>
header, and use the endpoint's URI for request. You may also set the
<code>throwExceptionOnFailure</code> to be <code>false</code> to let the
producer send all the fault response back. The consumer working in the bridge
mode will skip the gzip compression and WWW URL form
encoding (by adding the <code>Exchange.SKIP_GZIP_ENCODING</code> and
<code>Exchange.SKIP_WWW_FORM_URLENCODED</code> headers to the consumed
exchange).</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>throwExceptionOnFailure</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Option to disable throwing the
<code>HttpOperationFailedException</code> in case of failed responses from the
remote server. This allows you to get all responses regardles of the HTTP
status code.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>traceEnabled</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Specifies whether to enable HTTP TRACE for
this Netty HTTP consumer. By default TRACE is turned off.</p></td></tr><tr><td
colspan="1" rowspan="1" class="confluenceTd"><p>
<code>transferException</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If enabled and an <a shape="rect"
href="exchange.html">Exchange</a> failed processing on the consumer side, and
if the caused Exception was send back serialized in the response as a
<code>application/x-java-serialized-object</code> content type. On the producer
side the exception will be deserialized and thrown as is, instead of the
<code>HttpOperationFailedException</code>. The caused exception is required to
be serialized.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>urlDecodeHeaders</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the header
values will be URL decoded (eg %20 will b
e a space character. Notice this option is used by the default
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> and
therefore if you implement a custom
<code>org.apache.camel.component.netty.http.NettyHttpBinding</code> then you
would need to decode the headers accordingly to this option.
<strong>Notice:</strong> This option is default <code>true</code> for Camel
2.12.x, and default <code>false</code> from Camel 2.13
onwards.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettySharedHttpServer</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>To use a shared <a shape="rect"
href="netty-http.html">Netty HTTP</a> server. See <a shape="rect"
href="netty-http-server-example.html">Netty HTTP Server Example</a> for more
details.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>disableStreamCache</code></p></td><td colspan="
1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Determines whether or not the
raw input stream from Netty <code>HttpRequest#getContent()</code> is cached or
not (Camel will read the stream into a in light-weight memory based Stream
caching) cache. By default Camel will cache the Netty 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 <code>true</code> when you for
example need to access the raw stream, such as streaming it directly to a file
or other persistent store. Mind that if you enable this option, then you cannot
read the Netty stream multiple times out of the box, and you would need
manually to reset the reader index on the Netty raw
stream.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConfiguration</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</
code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><strong>Consumer only</strong>. Refers to a
<code>org.apache.camel.component.netty.http.NettyHttpSecurityConfiguration</code>
for configuring secure web resources.</p></td></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>send503whenSuspended</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Whether to send back HTTP status code 503 when the consumer has been suspended.
If the option is <code>false</code> then the Netty Acceptor is unbound when the
consumer is suspended, so clients cannot connect anymore.</p></td></tr><tr><td
colspan="1" rowspan="1" class="confluenceTd"><code>maxHeaderSize</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><code>8192</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><strong>Camel
2.15.3:</strong> <strong>Consumer only.
</strong>The maximum length of all headers. If the sum of the length of each
header exceeds this value, a TooLongFrameException will be
raised.</td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><code>okStatusCodeRange</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>200-299</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.16:</strong><span> 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.</span></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><span class="hl_identifier">useRelativePath</span></td><td
colspan="1" rowspan="1" class="confluenceTd">false</td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.16: Producer only:</strong>
Whether to use a path (/myapp) in the request line or an absolute URI (<a
shape="rect" class="external-link" href="http://0.0.0.0:8080/myapp%29,"
rel="nofollow">http://0.0.0.0:80
80/myapp),</a> which is default.</td></tr></tbody></table></div></div><p>The
<code>NettyHttpSecurityConfiguration</code> has the following options:</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>authenticate</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Whether authentication is
enabled. Can be used to quickly turn this off.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>constraint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>Basic</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The c
onstraint supported. Currently only <code>Basic</code> is implemented and
supported.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>realm</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>null</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>The name of the JAAS security realm. This option is
mandatory.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConstraint</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to plugin a security constraint
mapper where you can define ACL to web resources.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityAuthenticator</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allows to plugin a
authenticator that performs the au
thentication. If none has been configured then the
<code>org.apache.camel.component.netty.http.JAASSecurityAuthenticator</code> is
used by default.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>loginDeniedLoggingLevel</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>DEBUG</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Logging level used when a login
attempt failed, which allows to see more details why the login
failed.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>roleClassName</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To specify FQN class names of
<code>Principal</code> implementations that contains user roles. If none has
been specified, then the <a shape="rect" href="netty-http.html">Netty HTTP</a>
component will by default assume a <code>Principal</code> is role based if its
FQ
N classname has the lower-case word <code>role</code> in its classname. You
can specify multiple class names separated by
comma.</p></td></tr></tbody></table></div></div><h3
id="NettyHTTP-MessageHeaders">Message Headers</h3><p>The following headers can
be used on the producer to control the HTTP request.</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allow to control what HTTP
method to use such as GET, POST, TRACE etc. The type can also be a
<code>org.jboss.netty.handler.codec.http.HttpMethod</code> ins
tance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpQuery</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI query parameters as a
<code>String</code> value that overrides the endpoint configuration. Separate
multiple parameters using the & sign. For example:
<code>foo=bar&beer=yes</code>.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpPath</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><strong>Camel 2.13.1/2.12.4:</strong>
Allows to provide URI context-path and query parameters as a
<code>String</code> value that overrides the endpoint configuration. This
allows to reuse the same producer for calling same remote http server, but
using a dynamic context-path and query parameters.</p></t
d></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>Content-Type</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To set the content-type of the HTTP body.
For example: <code>text/plain; charset="UTF-8"</code>.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>CamelHttpResponseCode</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>int</code></td><td colspan="1"
rowspan="1" class="confluenceTd">Allows to set the HTTP Status code to use. By
default 200 is used for success, and 500 for
failure.</td></tr></tbody></table></div></div><p>The following headers is
provided as meta-data when a route starts from an <a shape="rect"
href="netty-http.html">Netty HTTP</a> endpoint:</p><p>The description in the
table takes offset in a route having:
<code>from("netty-http:http:0.0.0.0:8080/myapp")...</code></p><div
class="confluenceTableSmall"><div
class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1"
rowspan="1" class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The HTTP method used, such as
GET, POST, TRACE etc.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUrl</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The URL including protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[http://0.0.0.0:8080/myapp]]></script>
</div></div></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUri</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The URI without protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[/myapp]]></script>
Modified: websites/production/camel/content/netty4-http.html
==============================================================================
--- websites/production/camel/content/netty4-http.html (original)
+++ websites/production/camel/content/netty4-http.html Fri Dec 4 11:19:20 2015
@@ -96,7 +96,7 @@
</div></div><h3 id="Netty4HTTP-URIformat">URI format</h3><p>The URI scheme for
a netty component is as follows</p><div class="code panel pdl"
style="border-width: 1px;"><div class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[netty4-http:http://localhost:8080[?options]
]]></script>
-</div></div><p>You can append query options to the URI in the following
format, <code>?option=value&option=value&...</code></p><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">Query parameters vs
endpoint options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p>You may be wondering how Camel
recognizes URI query parameters and endpoint options. For example you might
create endpoint URI as follows - <code><a shape="rect" class="external-link"
href="http://netty-httphttp"
rel="nofollow">netty4-http:http//example.com?myParam=myValue&compression=true</a></code>
. In this example <code>myParam</code> is the HTTP parameter, while
<code>compression</code> is the Camel endpoint option. The strategy used by
Camel in such situations is to resolve available endpoint options and remove
them from the URI. It means that for the discuss
ed example, the HTTP request sent by Netty HTTP producer to the endpoint will
look as follows - <code>http//example.com?myParam=myValue</code> , because
<code>compression</code> endpoint option will be resolved and removed from the
target URL.</p><p>Keep also in mind that you cannot specify endpoint options
using dynamic headers (like <code>CamelHttpQuery</code>). Endpoint options can
be specified only at the endpoint URI definition level (like <code>to</code> or
<code>from</code> DSL elements).</p></div></div><h3
id="Netty4HTTP-HTTPOptions">HTTP Options</h3><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">A lot more
options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p
class="confluence-link"><strong>Important:</strong> This component inherits all
the options from <a shape="rect" href="netty4.html">Netty4</a>. So make sure t
o look at the <a shape="rect" href="netty4.html">Netty4</a> documentation
as well.<br clear="none"> Notice that some options from <a shape="rect"
href="netty4.html">Netty4</a> is not applicable when using this Netty4
HTTP component, such as options related to UDP transport.</p></div></div><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>chunkedMaxContentLength</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>1mb</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Value in bytes the max content
length per chunked frame received on the Netty HTTP
server.</p></td></tr><tr><td colspan="1" rowspan="1" class="con
fluenceTd"><p><code>compression</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allow using gzip/deflate for compression on the Netty
HTTP server if the client supports it from the HTTP
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>headerFilterStrategy</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.spi.HeaderFilterStrategy</code> to filter
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>httpMethodRestrict</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To disable HTTP methods on the Netty HTTP consumer. You
can specify multiple separated by comma.</p></td></tr><tr><td colspan="1"
rowspan="1" class="conflue
nceTd"><p><code>mapHeaders</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>true</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the headers
will be mapped as well (eg added as header to the Camel <a shape="rect"
href="message.html">Message</a> as well). You can turn off this option to
disable this. The headers can still be accessed from the
<code>org.apache.camel.component.netty4.http.NettyHttpMessage</code> message
with the method <code>getHttpRequest()</code> that returns the Netty HTTP
request <code>io.netty.handler.codec.http.HttpRequest</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>matchOnUriPrefix</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Whether or not Camel should tr
y to find a target consumer by matching the URI prefix if no exact match is
found. See further below for more details.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>nettyHttpBinding</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> for
binding to/from Netty and Camel Message API.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>bridgeEndpoint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>If the option is
<code>true</code>, the producer will ignore the <code>Exchange.HTTP_URI</code>
header, and use the endpoint's URI for request. You may also set the
<code>throwExceptionOnFailure</code> to be <code>false</code> to let the
producer send all the fault response back.</
p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>throwExceptionOnFailure</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Option to disable throwing the
<code>HttpOperationFailedException</code> in case of failed responses from the
remote server. This allows you to get all responses regardles of the HTTP
status code.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>traceEnabled</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Specifies whether to enable HTTP TRACE for
this Netty HTTP consumer. By default TRACE is turned off.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>transferException</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="
confluenceTd"><p>If enabled and an <a shape="rect"
href="exchange.html">Exchange</a> failed processing on the consumer side, and
if the caused Exception was send back serialized in the response as a
<code>application/x-java-serialized-object</code> content type. On the producer
side the exception will be deserialized and thrown as is, instead of the
<code>HttpOperationFailedException</code>. The caused exception is required to
be serialized.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>urlDecodeHeaders</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the header
values will be URL decoded (eg %20 will be a space character. Notice this
option is used by the default
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> and
therefore if you
implement a custom
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> then you
would need to decode the headers accordingly to this option.
<strong>Notice:</strong> This option is default
<code>false</code>.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettySharedHttpServer</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>To use a shared Netty4 HTTP
server. See <a shape="rect" href="netty-http-server-example.html">Netty HTTP
Server Example</a> for more details.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>disableStreamCache</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Determines whether or not the
raw input stream from Netty <code>HttpRequest#getContent()</code> is cached or
not (Camel will read the stream into a
in light-weight memory based Stream caching) cache. By default Camel will
cache the Netty 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
<code>true</code> when you for example need to access the raw stream, such as
streaming it directly to a file or other persistent store. Mind that if you
enable this option, then you cannot read the Netty stream multiple times out of
the box, and you would need manually to reset the reader index on the Netty raw
stream.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConfiguration</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Refers to a
<code>org.apache.camel.component.netty4.http.NettyHttpSecurityConfiguration</code>
for configuring secure web resources.</p></td></tr><tr><td colspan="1" r
owspan="1"
class="confluenceTd"><p><code>send503whenSuspended</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Whether to send back HTTP status code 503 when the consumer has been suspended.
If the option is <code>false</code> then the Netty Acceptor is unbound when the
consumer is suspended, so clients cannot connect anymore.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>maxHeadersSize</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>8192</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.15.3:</strong>
<strong>Consumer only</strong>. The maximum length of all headers. If the sum
of the length of each header exceeds this value, a
io.netty.handler.codec.TooLongFrameException will be raised.</td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>okStatusCodeRange</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><code>200-299</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><strong>Camel 2.16:</strong><span>
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.</span></td></tr></tbody></table></div></div><p>The
<code>NettyHttpSecurityConfiguration</code> has the following options:</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>authenticate</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Whether authentication is
enabled. Can
be used to quickly turn this off.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>constraint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>Basic</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The constraint supported.
Currently only <code>Basic</code> is implemented and
supported.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>realm</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>null</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>The name of the JAAS security realm. This option is
mandatory.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConstraint</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to plugin a security constraint
mapper where you can define ACL to web resources.</p></td></tr><tr><td co
lspan="1" rowspan="1"
class="confluenceTd"><p><code>securityAuthenticator</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allows to plugin a
authenticator that performs the authentication. If none has been configured
then the
<code>org.apache.camel.component.netty4.http.JAASSecurityAuthenticator</code>
is used by default.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>loginDeniedLoggingLevel</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>DEBUG</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Logging level used when a login
attempt failed, which allows to see more details why the login
failed.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>roleClassName</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceT
d"><p>To specify FQN class names of <code>Principal</code> implementations
that contains user roles. If none has been specified, then the Netty4 HTTP
component will by default assume a <code>Principal</code> is role based if its
FQN classname has the lower-case word <code>role</code> in its classname. You
can specify multiple class names separated by
comma.</p></td></tr></tbody></table></div></div><h3
id="Netty4HTTP-MessageHeaders">Message Headers</h3><p>The following headers can
be used on the producer to control the HTTP request.</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><cod
e>String</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allow to control what HTTP method to use such as GET,
POST, TRACE etc. The type can also be a
<code>io.netty.handler.codec.http.HttpMethod</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpQuery</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI query parameters as a
<code>String</code> value that overrides the endpoint configuration. Separate
multiple parameters using the & sign. For example:
<code>foo=bar&beer=yes</code>.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpPath</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI context-path and
query parameters as a <code>String</code>
value that overrides the endpoint configuration. This allows to reuse the
same producer for calling same remote http server, but using a dynamic
context-path and query parameters.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>Content-Type</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To set the content-type of the HTTP body.
For example: <code>text/plain; charset="UTF-8"</code>.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>CamelHttpResponseCode</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>int</code></td><td colspan="1"
rowspan="1" class="confluenceTd">Allows to set the HTTP Status code to use. By
default 200 is used for success, and 500 for
failure.</td></tr></tbody></table></div></div><p>The following headers is
provided as meta-data when a route starts from an Netty4 HTTP
endpoint:</p><p>The description i
n the table takes offset in a route having: <code>from("<a shape="rect"
class="external-link" href="http://netty-httphttp:0.0.0.0:8080"
rel="nofollow">netty4-http:http:0.0.0.0:8080/myapp</a>")...</code></p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The HTTP method used, such as
GET, POST, TRACE etc.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUrl</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan=
"1" class="confluenceTd"><p>The URL including protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
+</div></div><p>You can append query options to the URI in the following
format, <code>?option=value&option=value&...</code></p><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">Query parameters vs
endpoint options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p>You may be wondering how Camel
recognizes URI query parameters and endpoint options. For example you might
create endpoint URI as follows - <code><a shape="rect" class="external-link"
href="http://netty-httphttp"
rel="nofollow">netty4-http:http//example.com?myParam=myValue&compression=true</a></code>
. In this example <code>myParam</code> is the HTTP parameter, while
<code>compression</code> is the Camel endpoint option. The strategy used by
Camel in such situations is to resolve available endpoint options and remove
them from the URI. It means that for the discuss
ed example, the HTTP request sent by Netty HTTP producer to the endpoint will
look as follows - <code>http//example.com?myParam=myValue</code> , because
<code>compression</code> endpoint option will be resolved and removed from the
target URL.</p><p>Keep also in mind that you cannot specify endpoint options
using dynamic headers (like <code>CamelHttpQuery</code>). Endpoint options can
be specified only at the endpoint URI definition level (like <code>to</code> or
<code>from</code> DSL elements).</p></div></div><h3
id="Netty4HTTP-HTTPOptions">HTTP Options</h3><div
class="confluence-information-macro
confluence-information-macro-information"><p class="title">A lot more
options</p><span class="aui-icon aui-icon-small aui-iconfont-info
confluence-information-macro-icon"></span><div
class="confluence-information-macro-body"><p
class="confluence-link"><strong>Important:</strong> This component inherits all
the options from <a shape="rect" href="netty4.html">Netty4</a>. So make sure t
o look at the <a shape="rect" href="netty4.html">Netty4</a> documentation
as well.<br clear="none"> Notice that some options from <a shape="rect"
href="netty4.html">Netty4</a> is not applicable when using this Netty4
HTTP component, such as options related to UDP transport.</p></div></div><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Default Value</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1"
class="confluenceTd"><p><code>chunkedMaxContentLength</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>1mb</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Value in bytes the max content
length per chunked frame received on the Netty HTTP
server.</p></td></tr><tr><td colspan="1" rowspan="1" class="con
fluenceTd"><p><code>compression</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Allow using gzip/deflate for compression on the Netty
HTTP server if the client supports it from the HTTP
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>headerFilterStrategy</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.spi.HeaderFilterStrategy</code> to filter
headers.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>httpMethodRestrict</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>To disable HTTP methods on the Netty HTTP consumer. You
can specify multiple separated by comma.</p></td></tr><tr><td colspan="1"
rowspan="1" class="conflue
nceTd"><p><code>mapHeaders</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>true</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the headers
will be mapped as well (eg added as header to the Camel <a shape="rect"
href="message.html">Message</a> as well). You can turn off this option to
disable this. The headers can still be accessed from the
<code>org.apache.camel.component.netty4.http.NettyHttpMessage</code> message
with the method <code>getHttpRequest()</code> that returns the Netty HTTP
request <code>io.netty.handler.codec.http.HttpRequest</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>matchOnUriPrefix</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Whether or not Camel should tr
y to find a target consumer by matching the URI prefix if no exact match is
found. See further below for more details.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>nettyHttpBinding</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To use a custom
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> for
binding to/from Netty and Camel Message API.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>bridgeEndpoint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>If the option is
<code>true</code>, the producer will ignore the <code>Exchange.HTTP_URI</code>
header, and use the endpoint's URI for request. You may also set the
<code>throwExceptionOnFailure</code> to be <code>false</code> to let the
producer send all the fault response back.</
p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>throwExceptionOnFailure</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Option to disable throwing the
<code>HttpOperationFailedException</code> in case of failed responses from the
remote server. This allows you to get all responses regardles of the HTTP
status code.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>traceEnabled</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Specifies whether to enable HTTP TRACE for
this Netty HTTP consumer. By default TRACE is turned off.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>transferException</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1"
rowspan="1" class="
confluenceTd"><p>If enabled and an <a shape="rect"
href="exchange.html">Exchange</a> failed processing on the consumer side, and
if the caused Exception was send back serialized in the response as a
<code>application/x-java-serialized-object</code> content type. On the producer
side the exception will be deserialized and thrown as is, instead of the
<code>HttpOperationFailedException</code>. The caused exception is required to
be serialized.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>urlDecodeHeaders</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p> </p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>If this option is enabled, then during binding from
Netty to Camel <a shape="rect" href="message.html">Message</a> then the header
values will be URL decoded (eg %20 will be a space character. Notice this
option is used by the default
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> and
therefore if you
implement a custom
<code>org.apache.camel.component.netty4.http.NettyHttpBinding</code> then you
would need to decode the headers accordingly to this option.
<strong>Notice:</strong> This option is default
<code>false</code>.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>nettySharedHttpServer</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>To use a shared Netty4 HTTP
server. See <a shape="rect" href="netty-http-server-example.html">Netty HTTP
Server Example</a> for more details.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>disableStreamCache</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Determines whether or not the
raw input stream from Netty <code>HttpRequest#getContent()</code> is cached or
not (Camel will read the stream into a
in light-weight memory based Stream caching) cache. By default Camel will
cache the Netty 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
<code>true</code> when you for example need to access the raw stream, such as
streaming it directly to a file or other persistent store. Mind that if you
enable this option, then you cannot read the Netty stream multiple times out of
the box, and you would need manually to reset the reader index on the Netty raw
stream.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConfiguration</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Refers to a
<code>org.apache.camel.component.netty4.http.NettyHttpSecurityConfiguration</code>
for configuring secure web resources.</p></td></tr><tr><td colspan="1" r
owspan="1"
class="confluenceTd"><p><code>send503whenSuspended</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><strong>Consumer only</strong>.
Whether to send back HTTP status code 503 when the consumer has been suspended.
If the option is <code>false</code> then the Netty Acceptor is unbound when the
consumer is suspended, so clients cannot connect anymore.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>maxHeadersSize</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>8192</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.15.3:</strong>
<strong>Consumer only</strong>. The maximum length of all headers. If the sum
of the length of each header exceeds this value, a
io.netty.handler.codec.TooLongFrameException will be raised.</td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><code>okStatusCodeRange</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><code>200-299</code></td><td
colspan="1" rowspan="1" class="confluenceTd"><strong>Camel 2.16:</strong><span>
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.</span></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><span class="hl_identifier">useRelativePath</span></td><td
colspan="1" rowspan="1" class="confluenceTd">false</td><td colspan="1"
rowspan="1" class="confluenceTd"><strong>Camel 2.16: Producer only:</strong>
Whether to use a path (/myapp) in the request line or an absolute URI (<a
shape="rect" class="external-link" href="http://0.0.0.0:8080/myapp),"
rel="nofollow">http://0.0.0.0:8080/myapp),</a> which is
default.</td></tr></tbody></table></div></div><p>The
<code>NettyHttpSecurityConfiguration</code> has the following options:</p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody>
<tr><th colspan="1" rowspan="1" class="confluenceTh"><p>Name</p></th><th
colspan="1" rowspan="1" class="confluenceTh"><p>Default Value</p></th><th
colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>authenticate</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>true</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Whether authentication is
enabled. Can be used to quickly turn this off.</p></td></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>constraint</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>Basic</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>The constraint supported.
Currently only <code>Basic</code> is implemented and
supported.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>realm</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>null</co
de></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The name of
the JAAS security realm. This option is mandatory.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityConstraint</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to plugin a security constraint
mapper where you can define ACL to web resources.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>securityAuthenticator</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allows to plugin a
authenticator that performs the authentication. If none has been configured
then the
<code>org.apache.camel.component.netty4.http.JAASSecurityAuthenticator</code>
is used by default.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>loginDeniedLoggingLevel
</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>DEBUG</code></p></td><td colspan="1" rowspan="1"
class="confluenceTd"><p>Logging level used when a login attempt failed, which
allows to see more details why the login failed.</p></td></tr><tr><td
colspan="1" rowspan="1"
class="confluenceTd"><p><code>roleClassName</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>null</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To specify FQN class names of
<code>Principal</code> implementations that contains user roles. If none has
been specified, then the Netty4 HTTP component will by default assume a
<code>Principal</code> is role based if its FQN classname has the lower-case
word <code>role</code> in its classname. You can specify multiple class names
separated by comma.</p></td></tr></tbody></table></div></div><h3
id="Netty4HTTP-MessageHeaders">Message Headers</h3><p>The following headers can
be used on the producer to control
the HTTP request.</p><div class="confluenceTableSmall"><div
class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1"
rowspan="1" class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td
colspan="1" rowspan="1" class="confluenceTd"><p>Allow to control what HTTP
method to use such as GET, POST, TRACE etc. The type can also be a
<code>io.netty.handler.codec.http.HttpMethod</code>
instance.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpQuery</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI query parameters as a
<code>
String</code> value that overrides the endpoint configuration. Separate
multiple parameters using the & sign. For example:
<code>foo=bar&beer=yes</code>.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpPath</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>Allows to provide URI context-path and
query parameters as a <code>String</code> value that overrides the endpoint
configuration. This allows to reuse the same producer for calling same remote
http server, but using a dynamic context-path and query
parameters.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>Content-Type</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>To set the content-type of the HTTP body.
For example: <code>text/plain; charset="UTF-8"</code>.</p></t
d></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><code>CamelHttpResponseCode</code></td><td colspan="1"
rowspan="1" class="confluenceTd"><code>int</code></td><td colspan="1"
rowspan="1" class="confluenceTd">Allows to set the HTTP Status code to use. By
default 200 is used for success, and 500 for
failure.</td></tr></tbody></table></div></div><p>The following headers is
provided as meta-data when a route starts from an Netty4 HTTP
endpoint:</p><p>The description in the table takes offset in a route having:
<code>from("<a shape="rect" class="external-link"
href="http://netty-httphttp:0.0.0.0:8080"
rel="nofollow">netty4-http:http:0.0.0.0:8080/myapp</a>")...</code></p><div
class="confluenceTableSmall"><div class="table-wrap"><table
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1"
class="confluenceTh"><p>Name</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Type</p></th><th colspan="1" rowspan="1"
class="confluenceTh"><p>Description</p></th></tr><tr><t
d colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpMethod</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The HTTP method used, such as GET, POST,
TRACE etc.</p></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUrl</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The URL including protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[http://0.0.0.0:8080/myapp]]></script>
</div></div></td></tr><tr><td colspan="1" rowspan="1"
class="confluenceTd"><p><code>CamelHttpUri</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p><code>String</code></p></td><td colspan="1"
rowspan="1" class="confluenceTd"><p>The URI without protocol, host and port,
etc:</p><div class="code panel pdl" style="border-width: 1px;"><div
class="codeContent panelContent pdl">
<script class="brush: java; gutter: false; theme: Default"
type="syntaxhighlighter"><![CDATA[/myapp]]></script>