This is an automated email from the ASF dual-hosted git repository.
Croway pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 7af3e74d8448 CAMEL-24476: camel-mina - add a muteException consumer
option (#25741)
7af3e74d8448 is described below
commit 7af3e74d8448b5f1c6620bbae44d766e3f440704
Author: Andrea Cosentino <[email protected]>
AuthorDate: Fri Aug 28 12:18:55 2026 +0200
CAMEL-24476: camel-mina - add a muteException consumer option (#25741)
* CAMEL-24476: camel-mina - add a muteException consumer option
MinaConsumer wrote exchange.getException() - the Throwable itself - back
over
the socket when the exchange failed and transferExchange was off, so a route
failure handed the remote peer the exception class and message over a
textline
codec, and its serialised form over the object codec. The http consumers
gained
a muteException option defaulting to true in CAMEL-23651; camel-mina had
none.
A reply is still written when muted: suppressing it would set disconnect and
leave a synchronous peer to time out. The stand-in is a java.lang.Exception
with a fixed message and a cleared stack trace, so the object codec cannot
serialise this consumer's own frames to the peer either.
The three existing tests that assert the exception reaches the peer now set
muteException=false, the same migration an affected deployment performs.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
* CAMEL-24476: regenerate camel-catalog mina.json for muteException
CI's uncommitted-changes check failed because catalog/camel-catalog's
generated mina.json was not regenerated after adding the muteException
option in the previous commit.
Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
Signed-off-by: Claus Ibsen <[email protected]>
---------
Signed-off-by: Claus Ibsen <[email protected]>
Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
Co-authored-by: Claus Ibsen <[email protected]>
Co-authored-by: Federico Mariani <[email protected]>
---
.../org/apache/camel/catalog/components/mina.json | 86 ++++++++++-----------
.../component/mina/MinaComponentConfigurer.java | 6 ++
.../component/mina/MinaEndpointConfigurer.java | 6 ++
.../component/mina/MinaEndpointUriFactory.java | 3 +-
.../org/apache/camel/component/mina/mina.json | 86 ++++++++++-----------
.../camel/component/mina/MinaConfiguration.java | 14 ++++
.../apache/camel/component/mina/MinaConsumer.java | 17 ++++-
.../component/mina/MinaMuteExceptionTest.java | 88 ++++++++++++++++++++++
.../MinaTcpLineDelimiterUsingPlainSocketTest.java | 2 +-
.../mina/MinaTcpWithInOutUsingPlainSocketTest.java | 2 +-
.../MinaTcpWithIoOutProcessorExceptionTest.java | 2 +-
.../ROOT/pages/camel-4x-upgrade-guide-4_23.adoc | 25 ++++++
.../component/dsl/MinaComponentBuilderFactory.java | 20 +++++
.../endpoint/dsl/MinaEndpointBuilderFactory.java | 34 +++++++++
14 files changed, 302 insertions(+), 89 deletions(-)
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/mina.json
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/mina.json
index 23053a0d6af3..f730336c73a9 100644
---
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/mina.json
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/mina.json
@@ -31,27 +31,28 @@
"writeTimeout": { "index": 4, "kind": "property", "displayName": "Write
Timeout", "group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 10000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Maximum amount of time it should take to send
data to the MINA session. Default is 10000 milliseconds." },
"bridgeErrorHandler": { "index": 5, "kind": "property", "displayName":
"Bridge Error Handler", "group": "consumer", "label": "consumer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Allows for bridging the consumer to the Camel routing Error Handler, which
mean any exceptions (if possible) occurred while the Camel consumer is trying
to pickup incoming messages, or the like [...]
"clientMode": { "index": 6, "kind": "property", "displayName": "Client
Mode", "group": "consumer", "label": "consumer", "required": false, "type":
"boolean", "javaType": "boolean", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If the clientMode is true, mina consumer will
connect the address as a TCP client." },
- "noReplyLogLevel": { "index": 7, "kind": "property", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration" [...]
- "lazyStartProducer": { "index": 8, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Whether the producer should be started lazy (on the first message). By
starting lazy you can use this to allow CamelContext and routes to startup in
situations where a producer may otherwise fail [...]
- "cachedAddress": { "index": 9, "kind": "property", "displayName": "Cached
Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to false [...]
- "lazySessionCreation": { "index": 10, "kind": "property", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if th [...]
- "autowiredEnabled": { "index": 11, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching [...]
- "configuration": { "index": 12, "kind": "property", "displayName":
"Configuration", "group": "advanced", "label": "advanced", "required": false,
"type": "object", "javaType":
"org.apache.camel.component.mina.MinaConfiguration", "deprecated": false,
"autowired": false, "secret": false, "description": "To use the shared mina
configuration." },
- "disconnectOnNoReply": { "index": 13, "kind": "property", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disco [...]
- "maximumPoolSize": { "index": 14, "kind": "property", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
- "orderedThreadPoolExecutor": { "index": 15, "kind": "property",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are process [...]
- "transferExchange": { "index": 16, "kind": "property", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the exchan
[...]
- "allowDefaultCodec": { "index": 17, "kind": "property", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fals [...]
- "codec": { "index": 18, "kind": "property", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
- "decoderMaxLineLength": { "index": 19, "kind": "property", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value o [...]
- "encoderMaxLineLength": { "index": 20, "kind": "property", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
- "encoding": { "index": 21, "kind": "property", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
- "filters": { "index": 22, "kind": "property", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
- "objectCodecPattern": { "index": 23, "kind": "property", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializat [...]
- "textline": { "index": 24, "kind": "property", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; if [...]
- "textlineDelimiter": { "index": 25, "kind": "property", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
- "sslContextParameters": { "index": 26, "kind": "property", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." },
- "useGlobalSslContextParameters": { "index": 27, "kind": "property",
"displayName": "Use Global Ssl Context Parameters", "group": "security",
"label": "security", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Enable usage of global SSL context
parameters." }
+ "muteException": { "index": 7, "kind": "property", "displayName": "Mute
Exception", "group": "consumer", "label": "consumer", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If enabled and an Exchange failed processing
on the consumer side the response written back [...]
+ "noReplyLogLevel": { "index": 8, "kind": "property", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration" [...]
+ "lazyStartProducer": { "index": 9, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Whether the producer should be started lazy (on the first message). By
starting lazy you can use this to allow CamelContext and routes to startup in
situations where a producer may otherwise fail [...]
+ "cachedAddress": { "index": 10, "kind": "property", "displayName": "Cached
Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fals [...]
+ "lazySessionCreation": { "index": 11, "kind": "property", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if th [...]
+ "autowiredEnabled": { "index": 12, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching [...]
+ "configuration": { "index": 13, "kind": "property", "displayName":
"Configuration", "group": "advanced", "label": "advanced", "required": false,
"type": "object", "javaType":
"org.apache.camel.component.mina.MinaConfiguration", "deprecated": false,
"autowired": false, "secret": false, "description": "To use the shared mina
configuration." },
+ "disconnectOnNoReply": { "index": 14, "kind": "property", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disco [...]
+ "maximumPoolSize": { "index": 15, "kind": "property", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
+ "orderedThreadPoolExecutor": { "index": 16, "kind": "property",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are process [...]
+ "transferExchange": { "index": 17, "kind": "property", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the exchan
[...]
+ "allowDefaultCodec": { "index": 18, "kind": "property", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fals [...]
+ "codec": { "index": 19, "kind": "property", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
+ "decoderMaxLineLength": { "index": 20, "kind": "property", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value o [...]
+ "encoderMaxLineLength": { "index": 21, "kind": "property", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
+ "encoding": { "index": 22, "kind": "property", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
+ "filters": { "index": 23, "kind": "property", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
+ "objectCodecPattern": { "index": 24, "kind": "property", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializat [...]
+ "textline": { "index": 25, "kind": "property", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; if [...]
+ "textlineDelimiter": { "index": 26, "kind": "property", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
+ "sslContextParameters": { "index": 27, "kind": "property", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." },
+ "useGlobalSslContextParameters": { "index": 28, "kind": "property",
"displayName": "Use Global Ssl Context Parameters", "group": "security",
"label": "security", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Enable usage of global SSL context
parameters." }
},
"headers": {
"CamelMinaCloseSessionWhenComplete": { "index": 0, "kind": "header",
"displayName": "", "group": "common", "label": "", "required": false,
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Indicates whether the session should be
closed after complete", "constantName":
"org.apache.camel.component.mina.MinaConstants#MINA_CLOSE_SESSION_WHEN_COMPLETE"
},
@@ -69,26 +70,27 @@
"timeout": { "index": 6, "kind": "parameter", "displayName": "Timeout",
"group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 30000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the timeout that specifies
how long to wait for a response from a remote server. The timeout unit [...]
"writeTimeout": { "index": 7, "kind": "parameter", "displayName": "Write
Timeout", "group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 10000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Maximum amount of time it should take to send
data to the MINA session. Default is 10000 milliseconds." },
"clientMode": { "index": 8, "kind": "parameter", "displayName": "Client
Mode", "group": "consumer", "label": "consumer", "required": false, "type":
"boolean", "javaType": "boolean", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If the clientMode is true, mina consumer will
connect the address as a TCP client." },
- "bridgeErrorHandler": { "index": 9, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
- "exceptionHandler": { "index": 10, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By de [...]
- "exchangePattern": { "index": 11, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." },
- "noReplyLogLevel": { "index": 12, "kind": "parameter", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuratio [...]
- "cachedAddress": { "index": 13, "kind": "parameter", "displayName":
"Cached Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fal [...]
- "lazySessionCreation": { "index": 14, "kind": "parameter", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if t [...]
- "lazyStartProducer": { "index": 15, "kind": "parameter", "displayName":
"Lazy Start Producer", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Whether the producer should be started
lazy (on the first message). By starting lazy you can use this to allow
CamelContext and routes to startup in situations where a produ [...]
- "disconnectOnNoReply": { "index": 16, "kind": "parameter", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disc [...]
- "maximumPoolSize": { "index": 17, "kind": "parameter", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
- "orderedThreadPoolExecutor": { "index": 18, "kind": "parameter",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are proces [...]
- "transferExchange": { "index": 19, "kind": "parameter", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the excha
[...]
- "allowDefaultCodec": { "index": 20, "kind": "parameter", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fal [...]
- "codec": { "index": 21, "kind": "parameter", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
- "decoderMaxLineLength": { "index": 22, "kind": "parameter", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value [...]
- "encoderMaxLineLength": { "index": 23, "kind": "parameter", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
- "encoding": { "index": 24, "kind": "parameter", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
- "filters": { "index": 25, "kind": "parameter", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
- "objectCodecPattern": { "index": 26, "kind": "parameter", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializa [...]
- "textline": { "index": 27, "kind": "parameter", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; i [...]
- "textlineDelimiter": { "index": 28, "kind": "parameter", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
- "sslContextParameters": { "index": 29, "kind": "parameter", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." }
+ "muteException": { "index": 9, "kind": "parameter", "displayName": "Mute
Exception", "group": "consumer", "label": "consumer", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If enabled and an Exchange failed processing
on the consumer side the response written bac [...]
+ "bridgeErrorHandler": { "index": 10, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
+ "exceptionHandler": { "index": 11, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By de [...]
+ "exchangePattern": { "index": 12, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." },
+ "noReplyLogLevel": { "index": 13, "kind": "parameter", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuratio [...]
+ "cachedAddress": { "index": 14, "kind": "parameter", "displayName":
"Cached Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fal [...]
+ "lazySessionCreation": { "index": 15, "kind": "parameter", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if t [...]
+ "lazyStartProducer": { "index": 16, "kind": "parameter", "displayName":
"Lazy Start Producer", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Whether the producer should be started
lazy (on the first message). By starting lazy you can use this to allow
CamelContext and routes to startup in situations where a produ [...]
+ "disconnectOnNoReply": { "index": 17, "kind": "parameter", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disc [...]
+ "maximumPoolSize": { "index": 18, "kind": "parameter", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
+ "orderedThreadPoolExecutor": { "index": 19, "kind": "parameter",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are proces [...]
+ "transferExchange": { "index": 20, "kind": "parameter", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the excha
[...]
+ "allowDefaultCodec": { "index": 21, "kind": "parameter", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fal [...]
+ "codec": { "index": 22, "kind": "parameter", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
+ "decoderMaxLineLength": { "index": 23, "kind": "parameter", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value [...]
+ "encoderMaxLineLength": { "index": 24, "kind": "parameter", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
+ "encoding": { "index": 25, "kind": "parameter", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
+ "filters": { "index": 26, "kind": "parameter", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
+ "objectCodecPattern": { "index": 27, "kind": "parameter", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializa [...]
+ "textline": { "index": 28, "kind": "parameter", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; i [...]
+ "textlineDelimiter": { "index": 29, "kind": "parameter", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
+ "sslContextParameters": { "index": 30, "kind": "parameter", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." }
}
}
diff --git
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaComponentConfigurer.java
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaComponentConfigurer.java
index 1b697bec50e4..3139756c570b 100644
---
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaComponentConfigurer.java
+++
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaComponentConfigurer.java
@@ -59,6 +59,8 @@ public class MinaComponentConfigurer extends
PropertyConfigurerSupport implement
case "maximumPoolSize":
getOrCreateConfiguration(target).setMaximumPoolSize(property(camelContext,
int.class, value)); return true;
case "minalogger":
case "minaLogger":
getOrCreateConfiguration(target).setMinaLogger(property(camelContext,
boolean.class, value)); return true;
+ case "muteexception":
+ case "muteException":
getOrCreateConfiguration(target).setMuteException(property(camelContext,
boolean.class, value)); return true;
case "noreplyloglevel":
case "noReplyLogLevel":
getOrCreateConfiguration(target).setNoReplyLogLevel(property(camelContext,
org.apache.camel.LoggingLevel.class, value)); return true;
case "objectcodecpattern":
@@ -114,6 +116,8 @@ public class MinaComponentConfigurer extends
PropertyConfigurerSupport implement
case "maximumPoolSize": return int.class;
case "minalogger":
case "minaLogger": return boolean.class;
+ case "muteexception":
+ case "muteException": return boolean.class;
case "noreplyloglevel":
case "noReplyLogLevel": return org.apache.camel.LoggingLevel.class;
case "objectcodecpattern":
@@ -170,6 +174,8 @@ public class MinaComponentConfigurer extends
PropertyConfigurerSupport implement
case "maximumPoolSize": return
getOrCreateConfiguration(target).getMaximumPoolSize();
case "minalogger":
case "minaLogger": return
getOrCreateConfiguration(target).isMinaLogger();
+ case "muteexception":
+ case "muteException": return
getOrCreateConfiguration(target).isMuteException();
case "noreplyloglevel":
case "noReplyLogLevel": return
getOrCreateConfiguration(target).getNoReplyLogLevel();
case "objectcodecpattern":
diff --git
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointConfigurer.java
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointConfigurer.java
index 70c6c2d93c2c..291ed3295a55 100644
---
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointConfigurer.java
+++
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointConfigurer.java
@@ -53,6 +53,8 @@ public class MinaEndpointConfigurer extends
PropertyConfigurerSupport implements
case "maximumPoolSize":
target.getConfiguration().setMaximumPoolSize(property(camelContext, int.class,
value)); return true;
case "minalogger":
case "minaLogger":
target.getConfiguration().setMinaLogger(property(camelContext, boolean.class,
value)); return true;
+ case "muteexception":
+ case "muteException":
target.getConfiguration().setMuteException(property(camelContext,
boolean.class, value)); return true;
case "noreplyloglevel":
case "noReplyLogLevel":
target.getConfiguration().setNoReplyLogLevel(property(camelContext,
org.apache.camel.LoggingLevel.class, value)); return true;
case "objectcodecpattern":
@@ -107,6 +109,8 @@ public class MinaEndpointConfigurer extends
PropertyConfigurerSupport implements
case "maximumPoolSize": return int.class;
case "minalogger":
case "minaLogger": return boolean.class;
+ case "muteexception":
+ case "muteException": return boolean.class;
case "noreplyloglevel":
case "noReplyLogLevel": return org.apache.camel.LoggingLevel.class;
case "objectcodecpattern":
@@ -162,6 +166,8 @@ public class MinaEndpointConfigurer extends
PropertyConfigurerSupport implements
case "maximumPoolSize": return
target.getConfiguration().getMaximumPoolSize();
case "minalogger":
case "minaLogger": return target.getConfiguration().isMinaLogger();
+ case "muteexception":
+ case "muteException": return
target.getConfiguration().isMuteException();
case "noreplyloglevel":
case "noReplyLogLevel": return
target.getConfiguration().getNoReplyLogLevel();
case "objectcodecpattern":
diff --git
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointUriFactory.java
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointUriFactory.java
index 95a7208d870c..9fee0c2ace69 100644
---
a/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointUriFactory.java
+++
b/components/camel-mina/src/generated/java/org/apache/camel/component/mina/MinaEndpointUriFactory.java
@@ -24,7 +24,7 @@ public class MinaEndpointUriFactory extends
org.apache.camel.support.component.E
private static final Set<String> ENDPOINT_IDENTITY_PROPERTY_NAMES;
private static final Map<String, String> MULTI_VALUE_PREFIXES;
static {
- Set<String> props = new HashSet<>(30);
+ Set<String> props = new HashSet<>(31);
props.add("allowDefaultCodec");
props.add("bridgeErrorHandler");
props.add("cachedAddress");
@@ -43,6 +43,7 @@ public class MinaEndpointUriFactory extends
org.apache.camel.support.component.E
props.add("lazyStartProducer");
props.add("maximumPoolSize");
props.add("minaLogger");
+ props.add("muteException");
props.add("noReplyLogLevel");
props.add("objectCodecPattern");
props.add("orderedThreadPoolExecutor");
diff --git
a/components/camel-mina/src/generated/resources/META-INF/org/apache/camel/component/mina/mina.json
b/components/camel-mina/src/generated/resources/META-INF/org/apache/camel/component/mina/mina.json
index 23053a0d6af3..f730336c73a9 100644
---
a/components/camel-mina/src/generated/resources/META-INF/org/apache/camel/component/mina/mina.json
+++
b/components/camel-mina/src/generated/resources/META-INF/org/apache/camel/component/mina/mina.json
@@ -31,27 +31,28 @@
"writeTimeout": { "index": 4, "kind": "property", "displayName": "Write
Timeout", "group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 10000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Maximum amount of time it should take to send
data to the MINA session. Default is 10000 milliseconds." },
"bridgeErrorHandler": { "index": 5, "kind": "property", "displayName":
"Bridge Error Handler", "group": "consumer", "label": "consumer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Allows for bridging the consumer to the Camel routing Error Handler, which
mean any exceptions (if possible) occurred while the Camel consumer is trying
to pickup incoming messages, or the like [...]
"clientMode": { "index": 6, "kind": "property", "displayName": "Client
Mode", "group": "consumer", "label": "consumer", "required": false, "type":
"boolean", "javaType": "boolean", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If the clientMode is true, mina consumer will
connect the address as a TCP client." },
- "noReplyLogLevel": { "index": 7, "kind": "property", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration" [...]
- "lazyStartProducer": { "index": 8, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Whether the producer should be started lazy (on the first message). By
starting lazy you can use this to allow CamelContext and routes to startup in
situations where a producer may otherwise fail [...]
- "cachedAddress": { "index": 9, "kind": "property", "displayName": "Cached
Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to false [...]
- "lazySessionCreation": { "index": 10, "kind": "property", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if th [...]
- "autowiredEnabled": { "index": 11, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching [...]
- "configuration": { "index": 12, "kind": "property", "displayName":
"Configuration", "group": "advanced", "label": "advanced", "required": false,
"type": "object", "javaType":
"org.apache.camel.component.mina.MinaConfiguration", "deprecated": false,
"autowired": false, "secret": false, "description": "To use the shared mina
configuration." },
- "disconnectOnNoReply": { "index": 13, "kind": "property", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disco [...]
- "maximumPoolSize": { "index": 14, "kind": "property", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
- "orderedThreadPoolExecutor": { "index": 15, "kind": "property",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are process [...]
- "transferExchange": { "index": 16, "kind": "property", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the exchan
[...]
- "allowDefaultCodec": { "index": 17, "kind": "property", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fals [...]
- "codec": { "index": 18, "kind": "property", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
- "decoderMaxLineLength": { "index": 19, "kind": "property", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value o [...]
- "encoderMaxLineLength": { "index": 20, "kind": "property", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
- "encoding": { "index": 21, "kind": "property", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
- "filters": { "index": 22, "kind": "property", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
- "objectCodecPattern": { "index": 23, "kind": "property", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializat [...]
- "textline": { "index": 24, "kind": "property", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; if [...]
- "textlineDelimiter": { "index": 25, "kind": "property", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
- "sslContextParameters": { "index": 26, "kind": "property", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." },
- "useGlobalSslContextParameters": { "index": 27, "kind": "property",
"displayName": "Use Global Ssl Context Parameters", "group": "security",
"label": "security", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Enable usage of global SSL context
parameters." }
+ "muteException": { "index": 7, "kind": "property", "displayName": "Mute
Exception", "group": "consumer", "label": "consumer", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If enabled and an Exchange failed processing
on the consumer side the response written back [...]
+ "noReplyLogLevel": { "index": 8, "kind": "property", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration" [...]
+ "lazyStartProducer": { "index": 9, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": false, "description":
"Whether the producer should be started lazy (on the first message). By
starting lazy you can use this to allow CamelContext and routes to startup in
situations where a producer may otherwise fail [...]
+ "cachedAddress": { "index": 10, "kind": "property", "displayName": "Cached
Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fals [...]
+ "lazySessionCreation": { "index": 11, "kind": "property", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if th [...]
+ "autowiredEnabled": { "index": 12, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching [...]
+ "configuration": { "index": 13, "kind": "property", "displayName":
"Configuration", "group": "advanced", "label": "advanced", "required": false,
"type": "object", "javaType":
"org.apache.camel.component.mina.MinaConfiguration", "deprecated": false,
"autowired": false, "secret": false, "description": "To use the shared mina
configuration." },
+ "disconnectOnNoReply": { "index": 14, "kind": "property", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disco [...]
+ "maximumPoolSize": { "index": 15, "kind": "property", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
+ "orderedThreadPoolExecutor": { "index": 16, "kind": "property",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are process [...]
+ "transferExchange": { "index": 17, "kind": "property", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the exchan
[...]
+ "allowDefaultCodec": { "index": 18, "kind": "property", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fals [...]
+ "codec": { "index": 19, "kind": "property", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
+ "decoderMaxLineLength": { "index": 20, "kind": "property", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value o [...]
+ "encoderMaxLineLength": { "index": 21, "kind": "property", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
+ "encoding": { "index": 22, "kind": "property", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
+ "filters": { "index": 23, "kind": "property", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
+ "objectCodecPattern": { "index": 24, "kind": "property", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializat [...]
+ "textline": { "index": 25, "kind": "property", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; if [...]
+ "textlineDelimiter": { "index": 26, "kind": "property", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
+ "sslContextParameters": { "index": 27, "kind": "property", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." },
+ "useGlobalSslContextParameters": { "index": 28, "kind": "property",
"displayName": "Use Global Ssl Context Parameters", "group": "security",
"label": "security", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Enable usage of global SSL context
parameters." }
},
"headers": {
"CamelMinaCloseSessionWhenComplete": { "index": 0, "kind": "header",
"displayName": "", "group": "common", "label": "", "required": false,
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Indicates whether the session should be
closed after complete", "constantName":
"org.apache.camel.component.mina.MinaConstants#MINA_CLOSE_SESSION_WHEN_COMPLETE"
},
@@ -69,26 +70,27 @@
"timeout": { "index": 6, "kind": "parameter", "displayName": "Timeout",
"group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 30000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the timeout that specifies
how long to wait for a response from a remote server. The timeout unit [...]
"writeTimeout": { "index": 7, "kind": "parameter", "displayName": "Write
Timeout", "group": "common", "label": "", "required": false, "type": "integer",
"javaType": "long", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": 10000, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Maximum amount of time it should take to send
data to the MINA session. Default is 10000 milliseconds." },
"clientMode": { "index": 8, "kind": "parameter", "displayName": "Client
Mode", "group": "consumer", "label": "consumer", "required": false, "type":
"boolean", "javaType": "boolean", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If the clientMode is true, mina consumer will
connect the address as a TCP client." },
- "bridgeErrorHandler": { "index": 9, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
- "exceptionHandler": { "index": 10, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By de [...]
- "exchangePattern": { "index": 11, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." },
- "noReplyLogLevel": { "index": 12, "kind": "parameter", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuratio [...]
- "cachedAddress": { "index": 13, "kind": "parameter", "displayName":
"Cached Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fal [...]
- "lazySessionCreation": { "index": 14, "kind": "parameter", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if t [...]
- "lazyStartProducer": { "index": 15, "kind": "parameter", "displayName":
"Lazy Start Producer", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Whether the producer should be started
lazy (on the first message). By starting lazy you can use this to allow
CamelContext and routes to startup in situations where a produ [...]
- "disconnectOnNoReply": { "index": 16, "kind": "parameter", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disc [...]
- "maximumPoolSize": { "index": 17, "kind": "parameter", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
- "orderedThreadPoolExecutor": { "index": 18, "kind": "parameter",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are proces [...]
- "transferExchange": { "index": 19, "kind": "parameter", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the excha
[...]
- "allowDefaultCodec": { "index": 20, "kind": "parameter", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fal [...]
- "codec": { "index": 21, "kind": "parameter", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
- "decoderMaxLineLength": { "index": 22, "kind": "parameter", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value [...]
- "encoderMaxLineLength": { "index": 23, "kind": "parameter", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
- "encoding": { "index": 24, "kind": "parameter", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
- "filters": { "index": 25, "kind": "parameter", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
- "objectCodecPattern": { "index": 26, "kind": "parameter", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializa [...]
- "textline": { "index": 27, "kind": "parameter", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; i [...]
- "textlineDelimiter": { "index": 28, "kind": "parameter", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
- "sslContextParameters": { "index": 29, "kind": "parameter", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." }
+ "muteException": { "index": 9, "kind": "parameter", "displayName": "Mute
Exception", "group": "consumer", "label": "consumer", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "If enabled and an Exchange failed processing
on the consumer side the response written bac [...]
+ "bridgeErrorHandler": { "index": 10, "kind": "parameter", "displayName":
"Bridge Error Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Allows for bridging the consumer to the
Camel routing Error Handler, which mean any exceptions (if possible) occurred
while the Camel consumer is trying to pickup incoming [...]
+ "exceptionHandler": { "index": 11, "kind": "parameter", "displayName":
"Exception Handler", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "object", "javaType":
"org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.",
"deprecated": false, "autowired": false, "secret": false, "description": "To
let the consumer use a custom ExceptionHandler. Notice if the option
bridgeErrorHandler is enabled then this option is not in use. By de [...]
+ "exchangePattern": { "index": 12, "kind": "parameter", "displayName":
"Exchange Pattern", "group": "consumer (advanced)", "label":
"consumer,advanced", "required": false, "type": "enum", "javaType":
"org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut" ],
"deprecated": false, "autowired": false, "secret": false, "description": "Sets
the exchange pattern when the consumer creates an exchange." },
+ "noReplyLogLevel": { "index": 13, "kind": "parameter", "displayName": "No
Reply Log Level", "group": "consumer (advanced)", "label": "consumer,advanced",
"required": false, "type": "enum", "javaType": "org.apache.camel.LoggingLevel",
"enum": [ "TRACE", "DEBUG", "INFO", "WARN", "ERROR", "OFF" ], "deprecated":
false, "autowired": false, "secret": false, "defaultValue": "WARN",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuratio [...]
+ "cachedAddress": { "index": 14, "kind": "parameter", "displayName":
"Cached Address", "group": "producer (advanced)", "label": "producer,advanced",
"required": false, "type": "boolean", "javaType": "boolean", "deprecated":
false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to create the
InetAddress once and reuse. Setting this to fal [...]
+ "lazySessionCreation": { "index": 15, "kind": "parameter", "displayName":
"Lazy Session Creation", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Sessions can be lazily created to avoid
exceptions, if t [...]
+ "lazyStartProducer": { "index": 16, "kind": "parameter", "displayName":
"Lazy Start Producer", "group": "producer (advanced)", "label":
"producer,advanced", "required": false, "type": "boolean", "javaType":
"boolean", "deprecated": false, "autowired": false, "secret": false,
"defaultValue": false, "description": "Whether the producer should be started
lazy (on the first message). By starting lazy you can use this to allow
CamelContext and routes to startup in situations where a produ [...]
+ "disconnectOnNoReply": { "index": 17, "kind": "parameter", "displayName":
"Disconnect On No Reply", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "If sync is enabled then
this option dictates MinaConsumer if it should disc [...]
+ "maximumPoolSize": { "index": 18, "kind": "parameter", "displayName":
"Maximum Pool Size", "group": "advanced", "label": "advanced", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 16, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Number of worker threads in the worker pool
for TCP and UDP" },
+ "orderedThreadPoolExecutor": { "index": 19, "kind": "parameter",
"displayName": "Ordered Thread Pool Executor", "group": "advanced", "label":
"advanced", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Whether to use ordered
thread pool, to ensure events are proces [...]
+ "transferExchange": { "index": 20, "kind": "parameter", "displayName":
"Transfer Exchange", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": true,
"autowired": false, "secret": false, "security": "insecure:serialization",
"defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. You can transfer the excha
[...]
+ "allowDefaultCodec": { "index": 21, "kind": "parameter", "displayName":
"Allow Default Codec", "group": "codec", "label": "codec", "required": false,
"type": "boolean", "javaType": "boolean", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": true, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "The mina component installs a default codec if
both, codec is null and textline is fal [...]
+ "codec": { "index": 22, "kind": "parameter", "displayName": "Codec",
"group": "codec", "label": "codec", "required": false, "type": "object",
"javaType": "org.apache.mina.filter.codec.ProtocolCodecFactory", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To use a custom minda codec implementation." },
+ "decoderMaxLineLength": { "index": 23, "kind": "parameter", "displayName":
"Decoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 1024, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol decoder max line
length. By default the default value [...]
+ "encoderMaxLineLength": { "index": 24, "kind": "parameter", "displayName":
"Encoder Max Line Length", "group": "codec", "label": "codec", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": -1, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To set the textline protocol encoder max line
length. By default the default value of [...]
+ "encoding": { "index": 25, "kind": "parameter", "displayName": "Encoding",
"group": "codec", "label": "codec", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can configure the encoding (a charset
name) to use for the TCP textline codec and the UDP protocol. If not provided,
[...]
+ "filters": { "index": 26, "kind": "parameter", "displayName": "Filters",
"group": "codec", "label": "codec", "required": false, "type": "array",
"javaType": "java.util.List<org.apache.mina.core.filterchain.IoFilter>",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "You can set a list of Mina IoFilters to use."
},
+ "objectCodecPattern": { "index": 27, "kind": "parameter", "displayName":
"Object Codec Pattern", "group": "codec", "label": "codec", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "security": "insecure:serialization",
"configurationClass": "org.apache.camel.component.mina.MinaConfiguration",
"configurationField": "configuration", "description": "Accept the wildcard
specified classes for Object deserializa [...]
+ "textline": { "index": 28, "kind": "parameter", "displayName": "Textline",
"group": "codec", "label": "codec", "required": false, "type": "boolean",
"javaType": "boolean", "deprecated": false, "autowired": false, "secret":
false, "defaultValue": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used for TCP. If no codec is specified,
you can use this flag to indicate a text line based codec; i [...]
+ "textlineDelimiter": { "index": 29, "kind": "parameter", "displayName":
"Textline Delimiter", "group": "codec", "label": "codec", "required": false,
"type": "enum", "javaType":
"org.apache.camel.component.mina.MinaTextLineDelimiter", "enum": [ "DEFAULT",
"AUTO", "UNIX", "WINDOWS", "MAC" ], "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "Only used [...]
+ "sslContextParameters": { "index": 30, "kind": "parameter", "displayName":
"Ssl Context Parameters", "group": "security", "label": "security", "required":
false, "type": "object", "javaType":
"org.apache.camel.support.jsse.SSLContextParameters", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.mina.MinaConfiguration", "configurationField":
"configuration", "description": "To configure SSL security." }
}
}
diff --git
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConfiguration.java
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConfiguration.java
index 4a840a5f5d70..f94aa6705328 100644
---
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConfiguration.java
+++
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConfiguration.java
@@ -91,6 +91,8 @@ public class MinaConfiguration implements Cloneable {
private boolean cachedAddress = true;
@UriParam(label = "consumer")
private boolean clientMode;
+ @UriParam(label = "consumer", defaultValue = "true")
+ private boolean muteException = true;
/**
* Returns a copy of this configuration
@@ -429,6 +431,18 @@ public class MinaConfiguration implements Cloneable {
return clientMode;
}
+ /**
+ * If enabled and an Exchange failed processing on the consumer side the
response written back to the remote peer
+ * won't contain the exception's class, message or stack trace.
+ */
+ public void setMuteException(boolean muteException) {
+ this.muteException = muteException;
+ }
+
+ public boolean isMuteException() {
+ return muteException;
+ }
+
// here we just shows the option setting of host, port, protocol
public String getUriString() {
return "mina:" + getProtocol() + ":" + getHost() + ":" + getPort();
diff --git
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConsumer.java
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConsumer.java
index 72877ace2a67..a34161d6d11e 100644
---
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConsumer.java
+++
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaConsumer.java
@@ -64,6 +64,7 @@ import org.slf4j.LoggerFactory;
public class MinaConsumer extends DefaultConsumer {
private static final Logger LOG =
LoggerFactory.getLogger(MinaConsumer.class);
+ private static final String MUTED_EXCEPTION_MESSAGE = "Exchange processing
failed";
private IoSession session;
private IoConnector connector;
private SocketAddress address;
@@ -313,6 +314,19 @@ public class MinaConsumer extends DefaultConsumer {
addCodecFactory(service, codecFactory);
}
+ /**
+ * The stand-in written back to the remote peer when {@code muteException}
is enabled.
+ * <p>
+ * Still a {@link Exception}, so a peer that expects one - the object
codec deserialises whatever was written -
+ * keeps getting one, but it carries neither the class nor the message of
the route's exception. Its own stack trace
+ * is cleared as well: leaving it would serialise this consumer's frames
to the peer instead.
+ */
+ private static Exception mutedException() {
+ Exception muted = new Exception(MUTED_EXCEPTION_MESSAGE);
+ muted.setStackTrace(new StackTraceElement[0]);
+ return muted;
+ }
+
private void addCodecFactory(IoService service, ProtocolCodecFactory
codecFactory) {
service.getFilterChain().addLast("codec", new
ProtocolCodecFilter(codecFactory));
}
@@ -450,7 +464,8 @@ public class MinaConsumer extends DefaultConsumer {
boolean failed = exchange.isFailed();
if (failed &&
!getEndpoint().getConfiguration().isTransferExchange()) {
if (exchange.getException() != null) {
- response = exchange.getException();
+ response =
getEndpoint().getConfiguration().isMuteException()
+ ? mutedException() : exchange.getException();
} else {
// failed and no exception, must be a fault
response = exchange.getOut().getBody();
diff --git
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaMuteExceptionTest.java
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaMuteExceptionTest.java
new file mode 100644
index 000000000000..085e2475ead9
--- /dev/null
+++
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaMuteExceptionTest.java
@@ -0,0 +1,88 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.mina;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.junit.jupiter.api.Test;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+/**
+ * The consumer used to write {@code exchange.getException()} straight back
over the socket, so a route failure handed
+ * the remote peer the exception - its class and message over a textline
codec, and its serialised form, cause chain
+ * included, over the object codec.
+ * <p>
+ * {@code muteException} defaults to true, matching the http consumers aligned
by CAMEL-23651.
+ */
+class MinaMuteExceptionTest extends BaseMinaTest {
+
+ private static final String DETAIL =
"the-internal-detail-a-peer-must-not-see";
+
+ /** getNextPort() allocates a fresh port on every call, so the second
consumer's port is resolved once. */
+ private Integer unmutedPort;
+
+ @Test
+ void aFailedExchangeDoesNotWriteTheExceptionByDefault() {
+ String reply = template.requestBody(mutedUri(), "hello", String.class);
+
+ assertThat(reply)
+ .as("the reply must carry neither the class nor the message of
the route's exception")
+ .doesNotContain(DETAIL)
+ .doesNotContain("IllegalStateException");
+ // still a reply rather than a dropped connection, so a synchronous
peer is not left to time out
+ assertThat(reply).isNotEmpty();
+ }
+
+ @Test
+ void muteExceptionFalseWritesTheExceptionAsBefore() {
+ String reply = template.requestBody(unmutedUri(), "hello",
String.class);
+
+ assertThat(reply).contains(DETAIL).contains("IllegalStateException");
+ }
+
+ private String mutedUri() {
+ return uri(getPort(), "");
+ }
+
+ private String unmutedUri() {
+ if (unmutedPort == null) {
+ unmutedPort = getNextPort();
+ }
+ return uri(unmutedPort, "&muteException=false");
+ }
+
+ private static String uri(int port, String extra) {
+ return
String.format("mina:tcp://localhost:%1$s?sync=true&textline=true%2$s", port,
extra);
+ }
+
+ @Override
+ protected RouteBuilder createRouteBuilder() {
+ return new RouteBuilder() {
+ @Override
+ public void configure() {
+ from(mutedUri())
+ .process(e -> {
+ throw new IllegalStateException(DETAIL);
+ });
+ from(unmutedUri())
+ .process(e -> {
+ throw new IllegalStateException(DETAIL);
+ });
+ }
+ };
+ }
+}
diff --git
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpLineDelimiterUsingPlainSocketTest.java
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpLineDelimiterUsingPlainSocketTest.java
index b2949e9ebf1a..72c4c200f226 100644
---
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpLineDelimiterUsingPlainSocketTest.java
+++
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpLineDelimiterUsingPlainSocketTest.java
@@ -125,7 +125,7 @@ public class MinaTcpLineDelimiterUsingPlainSocketTest
extends BaseMinaTest {
// use no delay for fast unit testing
errorHandler(defaultErrorHandler().maximumRedeliveries(2));
-
fromF("mina:tcp://localhost:%1$s?textline=true&minaLogger=true&textlineDelimiter=MAC&sync=true",
+
fromF("mina:tcp://localhost:%1$s?textline=true&minaLogger=true&textlineDelimiter=MAC&sync=true&muteException=false",
getPort())
.process(e -> {
String in = e.getIn().getBody(String.class);
diff --git
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithInOutUsingPlainSocketTest.java
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithInOutUsingPlainSocketTest.java
index d8bb2dcc00fc..bdfdb0dd1a13 100644
---
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithInOutUsingPlainSocketTest.java
+++
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithInOutUsingPlainSocketTest.java
@@ -134,7 +134,7 @@ public class MinaTcpWithInOutUsingPlainSocketTest extends
BaseMinaTest {
return new RouteBuilder() {
public void configure() {
- fromF("mina:tcp://localhost:%1$s?textline=true&sync=true",
getPort())
+
fromF("mina:tcp://localhost:%1$s?textline=true&sync=true&muteException=false",
getPort())
.process(e -> {
String in = e.getIn().getBody(String.class);
if ("force-null-out-body".equals(in)) {
diff --git
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithIoOutProcessorExceptionTest.java
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithIoOutProcessorExceptionTest.java
index a0d8f065756a..cd76ad498a0b 100644
---
a/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithIoOutProcessorExceptionTest.java
+++
b/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaTcpWithIoOutProcessorExceptionTest.java
@@ -45,7 +45,7 @@ public class MinaTcpWithIoOutProcessorExceptionTest extends
BaseMinaTest {
// use no delay for fast unit testing
errorHandler(defaultErrorHandler().maximumRedeliveries(2));
- fromF("mina:tcp://localhost:%1$s?textline=true&sync=true",
getPort()).process(e -> {
+
fromF("mina:tcp://localhost:%1$s?textline=true&sync=true&muteException=false",
getPort()).process(e -> {
assertEquals("Hello World",
e.getIn().getBody(String.class));
// simulate a problem processing the input to see if we
can handle it properly
throw new IllegalArgumentException("Forced exception");
diff --git
a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc
b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc
index f73ec650e792..64b7415c521e 100644
--- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc
+++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc
@@ -689,6 +689,31 @@ Deployments whose introspection endpoint omits `iss` must
either have it include
`validateIssuer` off. The locally verified JWT path is unaffected — it uses
Keycloak's own
`TokenVerifier.RealmUrlCheck`.
+=== camel-mina
+
+The Mina consumer no longer writes the route's exception back to the remote
peer.
+
+When an exchange failed and `transferExchange` was not enabled, the consumer
wrote
+`exchange.getException()` — the `Throwable` itself — over the socket. With a
textline codec the peer
+received its class and message; with the object codec it received the
serialised exception, cause chain
+and stack trace included.
+
+A new `muteException` consumer option controls this, and it defaults to `true`
— the same default the
+HTTP consumers carry (`camel-http-common` and therefore `camel-servlet` and
`camel-jetty`, plus
+`camel-http`, `camel-platform-http`, and `camel-netty-http` and
`camel-undertow` since 4.21.0).
+
+A reply is still written, so a synchronous peer is not left waiting: it is a
`java.lang.Exception` with
+a fixed message and no stack trace, in place of the route's own exception. A
route that relies on the
+original exception reaching the peer must opt back in explicitly:
+
+[source,text]
+----
+mina:tcp://localhost:9000?sync=true&muteException=false
+----
+
+`transferExchange=true` is unaffected — that option serialises the whole
Exchange by design, and is
+already marked as an insecure-serialization flag.
+
=== camel-cxf
The CXF consumer no longer describes an undeclared route failure in the SOAP
fault returned to the caller.
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/MinaComponentBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/MinaComponentBuilderFactory.java
index 004c2f122894..6f41ced85b0c 100644
---
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/MinaComponentBuilderFactory.java
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/MinaComponentBuilderFactory.java
@@ -187,6 +187,25 @@ public interface MinaComponentBuilderFactory {
}
+ /**
+ * If enabled and an Exchange failed processing on the consumer side
the
+ * response written back to the remote peer won't contain the
+ * exception's class, message or stack trace.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: consumer
+ *
+ * @param muteException the value to set
+ * @return the dsl builder
+ */
+ default MinaComponentBuilder muteException(boolean muteException) {
+ doSetProperty("muteException", muteException);
+ return this;
+ }
+
+
/**
* If sync is enabled this option dictates MinaConsumer which logging
* level to use when logging a there is no reply to send back.
@@ -607,6 +626,7 @@ public interface MinaComponentBuilderFactory {
case "writeTimeout": getOrCreateConfiguration((MinaComponent)
component).setWriteTimeout((long) value); return true;
case "bridgeErrorHandler": ((MinaComponent)
component).setBridgeErrorHandler((boolean) value); return true;
case "clientMode": getOrCreateConfiguration((MinaComponent)
component).setClientMode((boolean) value); return true;
+ case "muteException": getOrCreateConfiguration((MinaComponent)
component).setMuteException((boolean) value); return true;
case "noReplyLogLevel": getOrCreateConfiguration((MinaComponent)
component).setNoReplyLogLevel((org.apache.camel.LoggingLevel) value); return
true;
case "lazyStartProducer": ((MinaComponent)
component).setLazyStartProducer((boolean) value); return true;
case "cachedAddress": getOrCreateConfiguration((MinaComponent)
component).setCachedAddress((boolean) value); return true;
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MinaEndpointBuilderFactory.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MinaEndpointBuilderFactory.java
index 8256cd16a7d4..60b596e2dac9 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MinaEndpointBuilderFactory.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MinaEndpointBuilderFactory.java
@@ -235,6 +235,40 @@ public interface MinaEndpointBuilderFactory {
doSetProperty("clientMode", clientMode);
return this;
}
+ /**
+ * If enabled and an Exchange failed processing on the consumer side
the
+ * response written back to the remote peer won't contain the
+ * exception's class, message or stack trace.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: consumer
+ *
+ * @param muteException the value to set
+ * @return the dsl builder
+ */
+ default MinaEndpointConsumerBuilder muteException(boolean
muteException) {
+ doSetProperty("muteException", muteException);
+ return this;
+ }
+ /**
+ * If enabled and an Exchange failed processing on the consumer side
the
+ * response written back to the remote peer won't contain the
+ * exception's class, message or stack trace.
+ *
+ * The option will be converted to a <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: consumer
+ *
+ * @param muteException the value to set
+ * @return the dsl builder
+ */
+ default MinaEndpointConsumerBuilder muteException(String
muteException) {
+ doSetProperty("muteException", muteException);
+ return this;
+ }
/**
* The mina component installs a default codec if both, codec is null
* and textline is false. Setting allowDefaultCodec to false prevents