This is an automated email from the ASF dual-hosted git repository.

gnodet pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 88bf36b2adef49e3d52faa3d8cb2594db7dbc8ef
Author: Guillaume Nodet <gno...@gmail.com>
AuthorDate: Mon Mar 2 20:27:08 2020 +0100

    Fix rabbitmq doc and regen
---
 .../apache/camel/component/rabbitmq/rabbitmq.json  |  2 +-
 .../src/main/docs/rabbitmq-component.adoc          |  2 +-
 .../dsl/RabbitMQEndpointBuilderFactory.java        | 12 +++++++
 .../modules/ROOT/pages/rabbitmq-component.adoc     |  2 +-
 .../apache/camel/tooling/util/JavadocHelper.java   | 38 +++++++++++-----------
 5 files changed, 34 insertions(+), 22 deletions(-)

diff --git 
a/components/camel-rabbitmq/src/generated/resources/org/apache/camel/component/rabbitmq/rabbitmq.json
 
b/components/camel-rabbitmq/src/generated/resources/org/apache/camel/component/rabbitmq/rabbitmq.json
index d24dc1d..f3aca78 100644
--- 
a/components/camel-rabbitmq/src/generated/resources/org/apache/camel/component/rabbitmq/rabbitmq.json
+++ 
b/components/camel-rabbitmq/src/generated/resources/org/apache/camel/component/rabbitmq/rabbitmq.json
@@ -111,7 +111,7 @@
     "bridgeEndpoint": { "kind": "parameter", "displayName": "Bridge Endpoint", 
"group": "producer", "label": "producer", "required": false, "type": "boolean", 
"javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": 
false, "description": "If the bridgeEndpoint is true, the producer will ignore 
the message header of rabbitmq.EXCHANGE_NAME and rabbitmq.ROUTING_KEY" },
     "channelPoolMaxSize": { "kind": "parameter", "displayName": "Channel Pool 
Max Size", "group": "producer", "label": "producer", "required": false, "type": 
"integer", "javaType": "int", "deprecated": false, "secret": false, 
"defaultValue": "10", "description": "Get maximum number of opened channel in 
pool" },
     "channelPoolMaxWait": { "kind": "parameter", "displayName": "Channel Pool 
Max Wait", "group": "producer", "label": "producer", "required": false, "type": 
"integer", "javaType": "long", "deprecated": false, "secret": false, 
"defaultValue": "1000", "description": "Set the maximum number of milliseconds 
to wait for a channel from the pool" },
-    "guaranteedDeliveries": { "kind": "parameter", "displayName": "Guaranteed 
Deliveries", "group": "producer", "label": "producer", "required": false, 
"type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, 
"defaultValue": false, "description": "When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also a href=https:\/\/ww [...]
+    "guaranteedDeliveries": { "kind": "parameter", "displayName": "Guaranteed 
Deliveries", "group": "producer", "label": "producer", "required": false, 
"type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, 
"defaultValue": false, "description": "When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also publisher acknowled [...]
     "immediate": { "kind": "parameter", "displayName": "Immediate", "group": 
"producer", "label": "producer", "required": false, "type": "boolean", 
"javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": 
false, "description": "This flag tells the server how to react if the message 
cannot be routed to a queue consumer immediately. If this flag is set, the 
server will return an undeliverable message with a Return method. If this flag 
is zero, the server will queue the  [...]
     "lazyStartProducer": { "kind": "parameter", "displayName": "Lazy Start 
Producer", "group": "producer", "label": "producer", "required": false, "type": 
"boolean", "javaType": "boolean", "deprecated": 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 during starting and cause the  [...]
     "mandatory": { "kind": "parameter", "displayName": "Mandatory", "group": 
"producer", "label": "producer", "required": false, "type": "boolean", 
"javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": 
false, "description": "This flag tells the server how to react if the message 
cannot be routed to a queue. If this flag is set, the server will return an 
unroutable message with a Return method. If this flag is zero, the server 
silently drops the message. If the head [...]
diff --git a/components/camel-rabbitmq/src/main/docs/rabbitmq-component.adoc 
b/components/camel-rabbitmq/src/main/docs/rabbitmq-component.adoc
index eb15201..29ef17b 100644
--- a/components/camel-rabbitmq/src/main/docs/rabbitmq-component.adoc
+++ b/components/camel-rabbitmq/src/main/docs/rabbitmq-component.adoc
@@ -176,7 +176,7 @@ with the following path and query parameters:
 | *bridgeEndpoint* (producer) | If the bridgeEndpoint is true, the producer 
will ignore the message header of rabbitmq.EXCHANGE_NAME and 
rabbitmq.ROUTING_KEY | false | boolean
 | *channelPoolMaxSize* (producer) | Get maximum number of opened channel in 
pool | 10 | int
 | *channelPoolMaxWait* (producer) | Set the maximum number of milliseconds to 
wait for a channel from the pool | 1000 | long
-| *guaranteedDeliveries* (producer) | When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also a href=\https://www.rabbitmq.com/confirms.htmlpublisher acknowledgements - 
When will messages be confirmed. | false | boolean
+| *guaranteedDeliveries* (producer) | When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also publisher acknowledgements - When will messages be confirmed. | false | 
boolean
 | *immediate* (producer) | This flag tells the server how to react if the 
message cannot be routed to a queue consumer immediately. If this flag is set, 
the server will return an undeliverable message with a Return method. If this 
flag is zero, the server will queue the message, but with no guarantee that it 
will ever be consumed. If the header is present rabbitmq.IMMEDIATE it will 
override this option. | false | boolean
 | *lazyStartProducer* (producer) | 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 during 
starting and cause the route to fail being started. By deferring this startup 
to be lazy then the startup failure can be handled during routing messages via 
Camel's routing error handlers. Beware that when the first message is processed 
then creating and [...]
 | *mandatory* (producer) | This flag tells the server how to react if the 
message cannot be routed to a queue. If this flag is set, the server will 
return an unroutable message with a Return method. If this flag is zero, the 
server silently drops the message. If the header is present rabbitmq.MANDATORY 
it will override this option. | false | boolean
diff --git 
a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RabbitMQEndpointBuilderFactory.java
 
b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RabbitMQEndpointBuilderFactory.java
index 8083182..cca0f53 100644
--- 
a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RabbitMQEndpointBuilderFactory.java
+++ 
b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RabbitMQEndpointBuilderFactory.java
@@ -555,6 +555,18 @@ public interface RabbitMQEndpointBuilderFactory {
             return this;
         }
         /**
+         * Specify a client-generated consumer tag to establish context when
+         * invoking the consume operation.
+         * 
+         * The option is a: <code>java.lang.String</code> type.
+         * 
+         * Group: consumer
+         */
+        default RabbitMQEndpointConsumerBuilder consumerTag(String 
consumerTag) {
+            doSetProperty("consumerTag", consumerTag);
+            return this;
+        }
+        /**
          * Request exclusive access to the queue (meaning only this consumer 
can
          * access the queue). This is useful when you want a long-lived shared
          * queue to be temporarily accessible by just one consumer.
diff --git a/docs/components/modules/ROOT/pages/rabbitmq-component.adoc 
b/docs/components/modules/ROOT/pages/rabbitmq-component.adoc
index 4d50a41..f0dedb1 100644
--- a/docs/components/modules/ROOT/pages/rabbitmq-component.adoc
+++ b/docs/components/modules/ROOT/pages/rabbitmq-component.adoc
@@ -177,7 +177,7 @@ with the following path and query parameters:
 | *bridgeEndpoint* (producer) | If the bridgeEndpoint is true, the producer 
will ignore the message header of rabbitmq.EXCHANGE_NAME and 
rabbitmq.ROUTING_KEY | false | boolean
 | *channelPoolMaxSize* (producer) | Get maximum number of opened channel in 
pool | 10 | int
 | *channelPoolMaxWait* (producer) | Set the maximum number of milliseconds to 
wait for a channel from the pool | 1000 | long
-| *guaranteedDeliveries* (producer) | When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also a href=\https://www.rabbitmq.com/confirms.htmlpublisher acknowledgements - 
When will messages be confirmed. | false | boolean
+| *guaranteedDeliveries* (producer) | When true, an exception will be thrown 
when the message cannot be delivered (basic.return) and the message is marked 
as mandatory. PublisherAcknowledgement will also be activated in this case. See 
also publisher acknowledgements - When will messages be confirmed. | false | 
boolean
 | *immediate* (producer) | This flag tells the server how to react if the 
message cannot be routed to a queue consumer immediately. If this flag is set, 
the server will return an undeliverable message with a Return method. If this 
flag is zero, the server will queue the message, but with no guarantee that it 
will ever be consumed. If the header is present rabbitmq.IMMEDIATE it will 
override this option. | false | boolean
 | *lazyStartProducer* (producer) | 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 during 
starting and cause the route to fail being started. By deferring this startup 
to be lazy then the startup failure can be handled during routing messages via 
Camel's routing error handlers. Beware that when the first message is processed 
then creating and [...]
 | *mandatory* (producer) | This flag tells the server how to react if the 
message cannot be routed to a queue. If this flag is set, the server will 
return an unroutable message with a Return method. If this flag is zero, the 
server silently drops the message. If the header is present rabbitmq.MANDATORY 
it will override this option. | false | boolean
diff --git 
a/tooling/camel-tooling-util/src/main/java/org/apache/camel/tooling/util/JavadocHelper.java
 
b/tooling/camel-tooling-util/src/main/java/org/apache/camel/tooling/util/JavadocHelper.java
index a10fa1f..0228651 100644
--- 
a/tooling/camel-tooling-util/src/main/java/org/apache/camel/tooling/util/JavadocHelper.java
+++ 
b/tooling/camel-tooling-util/src/main/java/org/apache/camel/tooling/util/JavadocHelper.java
@@ -65,31 +65,13 @@ public final class JavadocHelper {
                 continue;
             }
 
-            // remove all XML tags
-            line = line.replaceAll("<.*?>", "");
-
-            // remove all inlined javadoc links, eg such as {@link 
org.apache.camel.spi.Registry}
-            // use #? to remove leading # in case its a local reference
-            line = line.replaceAll("\\{\\@\\w+\\s#?([\\w.#(\\d,)]+)\\}", "$1");
-
             // we are starting from a new line, so add a whitespace
             if (!first) {
                 sb.append(' ');
             }
 
-            // create a new line
-            StringBuilder cb = new StringBuilder();
-            for (char c : line.toCharArray()) {
-                if (Character.isJavaIdentifierPart(c) || 
VALID_CHARS.indexOf(c) != -1) {
-                    cb.append(c);
-                } else if (Character.isWhitespace(c)) {
-                    // always use space as whitespace, also for line feeds etc
-                    cb.append(' ');
-                }
-            }
-
             // append data
-            String s = cb.toString().trim();
+            String s = line.trim();
             sb.append(s);
 
             boolean empty = isNullOrEmpty(s);
@@ -105,6 +87,24 @@ public final class JavadocHelper {
         }
 
         String s = sb.toString();
+        // remove all XML tags
+        s = s.replaceAll("<.*?>", "");
+        // remove all inlined javadoc links, eg such as {@link 
org.apache.camel.spi.Registry}
+        // use #? to remove leading # in case its a local reference
+        s = s.replaceAll("\\{\\@\\w+\\s#?([\\w.#(\\d,)]+)\\}", "$1");
+
+        // create a new line
+        StringBuilder cb = new StringBuilder();
+        for (char c : s.toCharArray()) {
+            if (Character.isJavaIdentifierPart(c) || VALID_CHARS.indexOf(c) != 
-1) {
+                cb.append(c);
+            } else if (Character.isWhitespace(c)) {
+                // always use space as whitespace, also for line feeds etc
+                cb.append(' ');
+            }
+        }
+        s = cb.toString();
+
         // remove double whitespaces, and trim
         s = s.replaceAll("\\s+", " ");
         // unescape http links

Reply via email to