This is an automated email from the ASF dual-hosted git repository.
davsclaus 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 09a755e18cf9 chore: correct camel-mina disconnectOnNoReply docs
(option has no effect since 4.24.0) (#28947)
09a755e18cf9 is described below
commit 09a755e18cf91bfdf005a5d97b9d7ef121bcf840
Author: Andrea Cosentino <[email protected]>
AuthorDate: Tue Nov 3 18:15:13 2026 +0100
chore: correct camel-mina disconnectOnNoReply docs (option has no effect
since 4.24.0) (#28947)
Signed-off-by: Andrea Cosentino <[email protected]>
Co-Authored-By: Claude <[email protected]>
---
.../org/apache/camel/catalog/components/mina.json | 4 +--
.../org/apache/camel/component/mina/mina.json | 4 +--
.../camel/component/mina/MinaConfiguration.java | 4 +--
.../apache/camel/component/mina/MinaProducer.java | 3 ++-
.../ROOT/pages/camel-4x-upgrade-guide-4_24.adoc | 3 ++-
.../component/dsl/MinaComponentBuilderFactory.java | 5 ++--
.../endpoint/dsl/MinaEndpointBuilderFactory.java | 30 +++++++++++++---------
7 files changed, 31 insertions(+), 22 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 8ae54d3daea6..ab6fd3be6c0d 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
@@ -38,7 +38,7 @@
"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 [...]
+ "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": "This option has no
effect. A synchronous consumer always closes its session [...]
"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
[...]
@@ -85,7 +85,7 @@
"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 [...]
+ "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": "This option has no
effect. A synchronous consumer always closes its session [...]
"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
[...]
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 8ae54d3daea6..ab6fd3be6c0d 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
@@ -38,7 +38,7 @@
"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 [...]
+ "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": "This option has no
effect. A synchronous consumer always closes its session [...]
"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
[...]
@@ -85,7 +85,7 @@
"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 [...]
+ "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": "This option has no
effect. A synchronous consumer always closes its session [...]
"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
[...]
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 e7fcf225b175..f53083f03518 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
@@ -358,8 +358,8 @@ public class MinaConfiguration implements Cloneable {
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it should
disconnect where there is no reply to send
- * back.
+ * This option has no effect. A synchronous consumer always closes its
session when it has no reply to send back,
+ * and the producer always closes its session on a reply timeout.
*/
public void setDisconnectOnNoReply(boolean disconnectOnNoReply) {
this.disconnectOnNoReply = disconnectOnNoReply;
diff --git
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaProducer.java
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaProducer.java
index 764ebd035ce4..ae4e849d933d 100644
---
a/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaProducer.java
+++
b/components/camel-mina/src/main/java/org/apache/camel/component/mina/MinaProducer.java
@@ -201,7 +201,8 @@ public class MinaProducer extends DefaultProducer {
// Always close the session of a producer that timed out waiting for a
reply. A sync producer is
// non-singleton and is returned to the pool for reuse by later
exchanges; if the session stayed open
// the late reply to this exchange could arrive on it and be handed to
the next exchange that reuses
- // this producer. disconnectOnNoReply only governs the consumer, so it
is not consulted here.
+ // this producer. disconnectOnNoReply is not consulted here, and has
no effect anywhere since the
+ // consumer never consulted it either.
LOG.debug("Closing session when timed out at address: {}", address);
closeSessionIfNeededAndAwaitCloseInHandler(session);
}
diff --git
a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc
b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc
index 3c128f7ff550..0054539bf3db 100644
--- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc
+++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc
@@ -3583,7 +3583,8 @@ could receive the late reply to the timed-out exchange
and hand it to the next e
The producer now discards that session, so the next exchange opens a fresh one.
The default behaviour is unchanged: `disconnectOnNoReply` defaults to `true`,
which already closed the session on a
-timeout. Setting `disconnectOnNoReply=false` no longer keeps the producer
session open after a timeout.
+timeout. Setting `disconnectOnNoReply=false` no longer keeps the producer
session open after a timeout. The option
+now has no effect: the consumer never used it, and always closes the session
when it has no reply to send.
=== camel-ftp - the host name of the FTPS server is verified
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 11c6a2de2d5f..32f170f3bc4a 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
@@ -325,8 +325,9 @@ public interface MinaComponentBuilderFactory {
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option is a: <code>boolean</code> type.
*
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 5fa02aa8a6d4..69c83572cdb6 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
@@ -768,8 +768,9 @@ public interface MinaEndpointBuilderFactory {
return this;
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option is a: <code>boolean</code> type.
*
@@ -784,8 +785,9 @@ public interface MinaEndpointBuilderFactory {
return this;
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option will be converted to a <code>boolean</code> type.
*
@@ -1535,8 +1537,9 @@ public interface MinaEndpointBuilderFactory {
return this;
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option is a: <code>boolean</code> type.
*
@@ -1551,8 +1554,9 @@ public interface MinaEndpointBuilderFactory {
return this;
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option will be converted to a <code>boolean</code> type.
*
@@ -2196,8 +2200,9 @@ public interface MinaEndpointBuilderFactory {
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option is a: <code>boolean</code> type.
*
@@ -2212,8 +2217,9 @@ public interface MinaEndpointBuilderFactory {
return this;
}
/**
- * If sync is enabled then this option dictates MinaConsumer if it
- * should disconnect where there is no reply to send back.
+ * This option has no effect. A synchronous consumer always closes its
+ * session when it has no reply to send back, and the producer always
+ * closes its session on a reply timeout.
*
* The option will be converted to a <code>boolean</code> type.
*