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

[1/5] camel git commit: CAMEL-10842: Component JSon schema - JSon values should not always be string types

Repository: camel
Updated Branches:
  refs/heads/master 9ea536050 -> c4607e6c5


http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mqtt/src/main/docs/mqtt-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mqtt/src/main/docs/mqtt-component.adoc b/components/camel-mqtt/src/main/docs/mqtt-component.adoc
index 532293b..67de942 100644
--- a/components/camel-mqtt/src/main/docs/mqtt-component.adoc
+++ b/components/camel-mqtt/src/main/docs/mqtt-component.adoc
@@ -67,7 +67,7 @@ The MQTT component supports 40 endpoint options which are listed below:
 | byDefaultRetain | common | false | boolean | The default retain policy to be used on messages sent to the MQTT broker
 | cleanSession | common | false | boolean | Set to false if you want the MQTT server to persist topic subscriptions and ack positions across client sessions. Defaults to true.
 | clientId | common |  | String | Use to set the client Id of the session. This is what an MQTT server uses to identify a session where setCleanSession(false); is being used. The id must be 23 characters or less. Defaults to auto generated id (based on your socket address port and timestamp).
-| connectAttemptsMax | common | -1 | long | The maximum number of reconnect attempts before an error is reported back to the client on the first attempt by the client to connect to a server. Set to -1 to use unlimited attempts. Defaults to -1.
+| connectAttemptsMax | common | 1 | long | The maximum number of reconnect attempts before an error is reported back to the client on the first attempt by the client to connect to a server. Set to -1 to use unlimited attempts. Defaults to -1.
 | connectWaitInSeconds | common | 10 | int | Delay in seconds the Component will wait for a connection to be established to the MQTT broker
 | disconnectWaitInSeconds | common | 5 | int | The number of seconds the Component will wait for a valid disconnect on stop() from the MQTT broker
 | dispatchQueue | common |  | DispatchQueue | A HawtDispatch dispatch queue is used to synchronize access to the connection. If an explicit queue is not configured via the setDispatchQueue method then a new queue will be created for the connection. Setting an explicit queue might be handy if you want multiple connection to share the same queue for synchronization.
@@ -82,8 +82,8 @@ The MQTT component supports 40 endpoint options which are listed below:
 | publishTopicName | common | camel/mqtt/test | String | The default Topic to publish messages on
 | qualityOfService | common | AtLeastOnce | String | Quality of service level to use for topics.
 | receiveBufferSize | common | 65536 | int | Sets the size of the internal socket receive buffer. Defaults to 65536 (64k)
-| reconnectAttemptsMax | common | -1 | long | The maximum number of reconnect attempts before an error is reported back to the client after a server connection had previously been established. Set to -1 to use unlimited attempts. Defaults to -1.
-| reconnectBackOffMultiplier | common | 2.0 | double | The Exponential backoff be used between reconnect attempts. Set to 1 to disable exponential backoff. Defaults to 2.
+| reconnectAttemptsMax | common | 1 | long | The maximum number of reconnect attempts before an error is reported back to the client after a server connection had previously been established. Set to -1 to use unlimited attempts. Defaults to -1.
+| reconnectBackOffMultiplier | common | 2 | double | The Exponential backoff be used between reconnect attempts. Set to 1 to disable exponential backoff. Defaults to 2.
 | reconnectDelay | common | 10 | long | How long to wait in ms before the first reconnect attempt. Defaults to 10.
 | reconnectDelayMax | common | 30000 | long | The maximum amount of time in ms to wait between reconnect attempts. Defaults to 30000.
 | sendBufferSize | common | 65536 | int | Sets the size of the internal socket send buffer. Defaults to 65536 (64k)
@@ -155,4 +155,4 @@ http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/Pollin
 * link:configuring-camel.html[Configuring Camel]
 * link:message-endpoint.html[Message Endpoint] pattern
 * link:uris.html[URIs]
-* link:writing-components.html[Writing Components]
\ No newline at end of file
+* link:writing-components.html[Writing Components]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-netty-http/src/main/docs/netty-http-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-netty-http/src/main/docs/netty-http-component.adoc b/components/camel-netty-http/src/main/docs/netty-http-component.adoc
index 3ec896d..e7bdb00 100644
--- a/components/camel-netty-http/src/main/docs/netty-http-component.adoc
+++ b/components/camel-netty-http/src/main/docs/netty-http-component.adoc
@@ -153,7 +153,7 @@ The Netty HTTP component supports 82 endpoint options which are listed below:
 | lazyChannelCreation | producer (advanced) | true | boolean | Channels can be lazily created to avoid exceptions if the remote server is not up and running when the Camel producer is started.
 | okStatusCodeRange | producer (advanced) | 200-299 | String | The status codes which is considered a success response. The values are inclusive. The range must be defined as from-to with the dash included. The default range is 200-299
 | producerPoolEnabled | producer (advanced) | true | boolean | Whether producer pool is enabled or not. Important: Do not turn this off as the pooling is needed for handling concurrency and reliable request/reply.
-| producerPoolMaxActive | producer (advanced) | -1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
+| producerPoolMaxActive | producer (advanced) | 1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
 | producerPoolMaxIdle | producer (advanced) | 100 | int | Sets the cap on the number of idle instances in the pool.
 | producerPoolMinEvictableIdle | producer (advanced) | 300000 | long | Sets the minimum amount of time (value in millis) an object may sit idle in the pool before it is eligible for eviction by the idle object evictor.
 | producerPoolMinIdle | producer (advanced) |  | int | Sets the minimum number of instances allowed in the producer pool before the evictor thread (if active) spawns new objects.
@@ -508,4 +508,4 @@ below:
 
 * link:netty.html[Netty]
 * link:netty-http-server-example.html[Netty HTTP Server Example]
-* link:jetty.html[Jetty]
\ No newline at end of file
+* link:jetty.html[Jetty]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-netty/src/main/docs/netty-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-netty/src/main/docs/netty-component.adoc b/components/camel-netty/src/main/docs/netty-component.adoc
index 491834c..1cedf0f 100644
--- a/components/camel-netty/src/main/docs/netty-component.adoc
+++ b/components/camel-netty/src/main/docs/netty-component.adoc
@@ -118,7 +118,7 @@ The Netty component supports 70 endpoint options which are listed below:
 | clientPipelineFactory | producer (advanced) |  | ClientPipelineFactory | To use a custom ClientPipelineFactory
 | lazyChannelCreation | producer (advanced) | true | boolean | Channels can be lazily created to avoid exceptions if the remote server is not up and running when the Camel producer is started.
 | producerPoolEnabled | producer (advanced) | true | boolean | Whether producer pool is enabled or not. Important: Do not turn this off as the pooling is needed for handling concurrency and reliable request/reply.
-| producerPoolMaxActive | producer (advanced) | -1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
+| producerPoolMaxActive | producer (advanced) | 1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
 | producerPoolMaxIdle | producer (advanced) | 100 | int | Sets the cap on the number of idle instances in the pool.
 | producerPoolMinEvictableIdle | producer (advanced) | 300000 | long | Sets the minimum amount of time (value in millis) an object may sit idle in the pool before it is eligible for eviction by the idle object evictor.
 | producerPoolMinIdle | producer (advanced) |  | int | Sets the minimum number of instances allowed in the producer pool before the evictor thread (if active) spawns new objects.
@@ -613,4 +613,4 @@ And if we have another route we can refer to the shared worker pool:
 * link:getting-started.html[Getting Started]
 
 * link:netty-http.html[Netty HTTP]
-* link:mina.html[MINA]
\ No newline at end of file
+* link:mina.html[MINA]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-netty4-http/src/main/docs/netty4-http-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-netty4-http/src/main/docs/netty4-http-component.adoc b/components/camel-netty4-http/src/main/docs/netty4-http-component.adoc
index e33899a..33619ba 100644
--- a/components/camel-netty4-http/src/main/docs/netty4-http-component.adoc
+++ b/components/camel-netty4-http/src/main/docs/netty4-http-component.adoc
@@ -151,7 +151,7 @@ The Netty4 HTTP component supports 83 endpoint options which are listed below:
 | lazyChannelCreation | producer (advanced) | true | boolean | Channels can be lazily created to avoid exceptions if the remote server is not up and running when the Camel producer is started.
 | okStatusCodeRange | producer (advanced) | 200-299 | String | The status codes which is considered a success response. The values are inclusive. The range must be defined as from-to with the dash included. The default range is 200-299
 | producerPoolEnabled | producer (advanced) | true | boolean | Whether producer pool is enabled or not. Important: Do not turn this off as the pooling is needed for handling concurrency and reliable request/reply.
-| producerPoolMaxActive | producer (advanced) | -1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
+| producerPoolMaxActive | producer (advanced) | 1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
 | producerPoolMaxIdle | producer (advanced) | 100 | int | Sets the cap on the number of idle instances in the pool.
 | producerPoolMinEvictableIdle | producer (advanced) | 300000 | long | Sets the minimum amount of time (value in millis) an object may sit idle in the pool before it is eligible for eviction by the idle object evictor.
 | producerPoolMinIdle | producer (advanced) |  | int | Sets the minimum number of instances allowed in the producer pool before the evictor thread (if active) spawns new objects.
@@ -510,4 +510,4 @@ below:
 
 * link:netty.html[Netty]
 * link:netty-http-server-example.html[Netty HTTP Server Example]
-* link:jetty.html[Jetty]
\ No newline at end of file
+* link:jetty.html[Jetty]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-netty4/src/main/docs/netty4-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-netty4/src/main/docs/netty4-component.adoc b/components/camel-netty4/src/main/docs/netty4-component.adoc
index ad41d38..d1d5ac4 100644
--- a/components/camel-netty4/src/main/docs/netty4-component.adoc
+++ b/components/camel-netty4/src/main/docs/netty4-component.adoc
@@ -117,7 +117,7 @@ The Netty4 component supports 74 endpoint options which are listed below:
 | clientInitializerFactory | producer (advanced) |  | ClientInitializerFactory | To use a custom ClientInitializerFactory
 | lazyChannelCreation | producer (advanced) | true | boolean | Channels can be lazily created to avoid exceptions if the remote server is not up and running when the Camel producer is started.
 | producerPoolEnabled | producer (advanced) | true | boolean | Whether producer pool is enabled or not. Important: Do not turn this off as the pooling is needed for handling concurrency and reliable request/reply.
-| producerPoolMaxActive | producer (advanced) | -1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
+| producerPoolMaxActive | producer (advanced) | 1 | int | Sets the cap on the number of objects that can be allocated by the pool (checked out to clients or idle awaiting checkout) at a given time. Use a negative value for no limit.
 | producerPoolMaxIdle | producer (advanced) | 100 | int | Sets the cap on the number of idle instances in the pool.
 | producerPoolMinEvictableIdle | producer (advanced) | 300000 | long | Sets the minimum amount of time (value in millis) an object may sit idle in the pool before it is eligible for eviction by the idle object evictor.
 | producerPoolMinIdle | producer (advanced) |  | int | Sets the minimum number of instances allowed in the producer pool before the evictor thread (if active) spawns new objects.
@@ -681,4 +681,4 @@ And if we have another route we can refer to the shared worker pool:
 * link:getting-started.html[Getting Started]
 
 * link:netty-http.html[Netty HTTP]
-* link:mina.html[MINA]
\ No newline at end of file
+* link:mina.html[MINA]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-sjms/src/main/docs/sjms-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-sjms/src/main/docs/sjms-component.adoc b/components/camel-sjms/src/main/docs/sjms-component.adoc
index 5d8f615..ce93777 100644
--- a/components/camel-sjms/src/main/docs/sjms-component.adoc
+++ b/components/camel-sjms/src/main/docs/sjms-component.adoc
@@ -131,7 +131,7 @@ The Simple JMS component supports 36 endpoint options which are listed below:
 | namedReplyTo | producer |  | String | Sets the reply to destination name used for InOut producer endpoints.
 | persistent | producer | true | boolean | Flag used to enable/disable message persistence.
 | producerCount | producer | 1 | int | Sets the number of producers used for this endpoint.
-| ttl | producer | -1 | long | Flag used to adjust the Time To Live value of produced messages.
+| ttl | producer | 1 | long | Flag used to adjust the Time To Live value of produced messages.
 | allowNullBody | producer (advanced) | true | boolean | Whether to allow sending messages with no body. If this option is false and the message body is null then an JMSException is thrown.
 | prefillPool | producer (advanced) | true | boolean | Whether to prefill the producer connection pool on startup or create connections lazy when needed.
 | responseTimeOut | producer (advanced) | 5000 | long | Sets the amount of time we should wait before timing out a InOut response.
@@ -150,7 +150,7 @@ The Simple JMS component supports 36 endpoint options which are listed below:
 | errorHandlerLoggingLevel | logging | WARN | LoggingLevel | Allows to configure the default errorHandler logging level for logging uncaught exceptions.
 | errorHandlerLogStackTrace | logging | true | boolean | Allows to control whether stacktraces should be logged or not by the default errorHandler.
 | transacted | transaction | false | boolean | Specifies whether to use transacted mode
-| transactionBatchCount | transaction | -1 | int | If transacted sets the number of messages to process before committing a transaction.
+| transactionBatchCount | transaction | 1 | int | If transacted sets the number of messages to process before committing a transaction.
 | transactionBatchTimeout | transaction | 5000 | long | Sets timeout (in millis) for batch transactions the value should be 1000 or higher.
 | transactionCommitStrategy | transaction |  | TransactionCommitStrategy | Sets the commit strategy.
 | sharedJMSSession | transaction (advanced) | true | boolean | Specifies whether to share JMS session with other SJMS endpoints. Turn this off if your route is accessing to multiple JMS providers. If you need transaction against multiple JMS providers use jms component to leverage XA transaction.
@@ -531,4 +531,4 @@ DSL:
 
 Springless refers to moving away from the dependency on the Spring JMS
 API. A new JMS client API is being developed from the ground up to power
-SJMS.
\ No newline at end of file
+SJMS.

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-sql/src/main/docs/sql-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-sql/src/main/docs/sql-component.adoc b/components/camel-sql/src/main/docs/sql-component.adoc
index fcc273c..aa6ff8f 100644
--- a/components/camel-sql/src/main/docs/sql-component.adoc
+++ b/components/camel-sql/src/main/docs/sql-component.adoc
@@ -141,7 +141,7 @@ The SQL component supports 46 endpoint options which are listed below:
 | separator | common | , | char | The separator to use when parameter values is taken from message body (if the body is a String type) to be inserted at placeholders. Notice if you use named parameters then a Map type is used instead. The default value is comma.
 | breakBatchOnConsumeFail | consumer | false | boolean | Sets whether to break batch if onConsume failed.
 | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN or ERROR level and ignored.
-| expectedUpdateCount | consumer | -1 | int | Sets an expected update count to validate when using onConsume.
+| expectedUpdateCount | consumer | 1 | int | Sets an expected update count to validate when using onConsume.
 | maxMessagesPerPoll | consumer |  | int | Sets the maximum number of messages to poll
 | onConsume | consumer |  | String | After processing each row then this query can be executed if the Exchange was processed successfully for example to mark the row as processed. The query can have parameter.
 | onConsumeBatchComplete | consumer |  | String | After processing the entire batch this query can be executed to bulk update rows etc. The query cannot have parameters.
@@ -768,4 +768,4 @@ You should also include the specific database driver, if needed.
 
 link:sql-stored-procedure.html[SQL Stored Procedure]
 
-link:jdbc.html[JDBC]
\ No newline at end of file
+link:jdbc.html[JDBC]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-websocket/src/main/docs/websocket-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-websocket/src/main/docs/websocket-component.adoc b/components/camel-websocket/src/main/docs/websocket-component.adoc
index a35cc87..cc284ee 100644
--- a/components/camel-websocket/src/main/docs/websocket-component.adoc
+++ b/components/camel-websocket/src/main/docs/websocket-component.adoc
@@ -75,7 +75,7 @@ The Jetty Websocket component supports 21 endpoint options which are listed belo
 | host | common | 0.0.0.0 | String | The hostname. The default value is 0.0.0.0. Setting this option on the component will use the component configured value as default.
 | port | common | 9292 | Integer | The port number. The default value is 9292. Setting this option on the component will use the component configured value as default.
 | resourceUri | common |  | String | *Required* Name of the websocket channel to use
-| maxBinaryMessageSize | common | -1 | Integer | Can be used to set the size in bytes that the websocket created by the websocketServlet may be accept before closing. (Default is -1 - or unlimited)
+| maxBinaryMessageSize | common | 1 | Integer | Can be used to set the size in bytes that the websocket created by the websocketServlet may be accept before closing. (Default is -1 - or unlimited)
 | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN or ERROR level and ignored.
 | sessionSupport | consumer | false | boolean | Whether to enable session support which enables HttpSession for each http request.
 | staticResources | consumer |  | String | Set a resource path for static resources (such as .html files etc). The resources can be loaded from classpath if you prefix with classpath: otherwise the resources is loaded from file system or from JAR files. For example to load from root classpath use classpath:. or classpath:WEB-INF/static If not configured (eg null) then no static resource is in use.
@@ -233,4 +233,4 @@ Java DSL based configuration of endpoint
 * link:jetty.html[Jetty]
 * link:twitter-websocket-example.html[Twitter Websocket Example]
 demonstrates how to poll a constant feed of twitter searches and publish
-results in real time using web socket to a web page.
\ No newline at end of file
+results in real time using web socket to a web page.

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-yammer/src/main/docs/yammer-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-yammer/src/main/docs/yammer-component.adoc b/components/camel-yammer/src/main/docs/yammer-component.adoc
index 92330c6..e0fd3f5 100644
--- a/components/camel-yammer/src/main/docs/yammer-component.adoc
+++ b/components/camel-yammer/src/main/docs/yammer-component.adoc
@@ -77,9 +77,9 @@ The Yammer component supports 29 endpoint options which are listed below:
 | useJson | common | false | boolean | Set to true if you want to use raw JSON rather than converting to POJOs.
 | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN or ERROR level and ignored.
 | delay | consumer | 5000 | long | Delay between polling in millis
-| limit | consumer | -1 | int | Return only the specified number of messages. Works for threaded=true and threaded=extended.
-| newerThan | consumer | -1 | int | Returns messages newer than the message ID specified as a numeric string. This should be used when polling for new messages. If you're looking at messages and the most recent message returned is 3516 you can make a request with the parameter newerThan=3516 to ensure that you do not get duplicate copies of messages already on your page.
-| olderThan | consumer | -1 | int | Returns messages older than the message ID specified as a numeric string. This is useful for paginating messages. For example if you're currently viewing 20 messages and the oldest is number 2912 you could append olderThan=2912 to your request to get the 20 messages prior to those you're seeing.
+| limit | consumer | 1 | int | Return only the specified number of messages. Works for threaded=true and threaded=extended.
+| newerThan | consumer | 1 | int | Returns messages newer than the message ID specified as a numeric string. This should be used when polling for new messages. If you're looking at messages and the most recent message returned is 3516 you can make a request with the parameter newerThan=3516 to ensure that you do not get duplicate copies of messages already on your page.
+| olderThan | consumer | 1 | int | Returns messages older than the message ID specified as a numeric string. This is useful for paginating messages. For example if you're currently viewing 20 messages and the oldest is number 2912 you could append olderThan=2912 to your request to get the 20 messages prior to those you're seeing.
 | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead.
 | threaded | consumer |  | String | threaded=true will only return the first message in each thread. This parameter is intended for apps which display message threads collapsed. threaded=extended will return the thread starter messages in order of most recently active as well as the two most recent messages as they are viewed in the default view on the Yammer web interface.
 | userId | consumer |  | String | The user id
@@ -348,4 +348,4 @@ the Camel message body.
 * link:configuring-camel.html[Configuring Camel]
 * link:component.html[Component]
 * link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
\ No newline at end of file
+* link:getting-started.html[Getting Started]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java b/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
index daaf3cd..1258256 100644
--- a/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
+++ b/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
@@ -27,7 +27,8 @@ import java.util.regex.Pattern;
 
 public final class JSonSchemaHelper {
 
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
     private static final String QUOT = """;
 
     private JSonSchemaHelper() {
@@ -81,19 +82,34 @@ public final class JSonSchemaHelper {
                     key = matcher.group(1);
                 } else {
                     String value = matcher.group(1);
-                    if (value == null) {
-                        value = matcher.group(2);
-                        // its an enum so strip out " and trim spaces after comma
-                        value = value.replaceAll("\"", "");
-                        value = value.replaceAll(", ", ",");
-                    }
                     if (value != null) {
+                        // its text based
                         value = value.trim();
                         // decode
                         value = value.replaceAll(QUOT, "\"");
                         value = decodeJson(value);
                     }
-                    row.put(key, value);
+                    if (value == null) {
+                        // not text then its maybe an enum?
+                        value = matcher.group(2);
+                        if (value != null) {
+                            // its an enum so strip out " and trim spaces after comma
+                            value = value.replaceAll("\"", "");
+                            value = value.replaceAll(", ", ",");
+                            value = value.trim();
+                        }
+                    }
+                    if (value == null) {
+                        // not text then its maybe a boolean?
+                        value = matcher.group(3);
+                    }
+                    if (value == null) {
+                        // not text then its maybe a integer?
+                        value = matcher.group(4);
+                    }
+                    if (value != null) {
+                        row.put(key, value);
+                    }
                     // reset
                     key = null;
                 }

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java b/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
index ff9a7fb..c98cd1d 100644
--- a/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
+++ b/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
@@ -1061,4 +1061,44 @@ public class CamelCatalogTest {
         assertEquals("delete", result.getNotProducerOnly().iterator().next());
     }
 
+    @Test
+    public void testJSonSchemaHelper() throws Exception {
+        String json = loadText(new FileInputStream("src/test/resources/org/foo/camel/dummy.json"));
+        assertNotNull(json);
+
+        // component
+        List<Map<String, String>> rows = JSonSchemaHelper.parseJsonSchema("component", json, false);
+        assertEquals(12, rows.size());
+        assertTrue(JSonSchemaHelper.isComponentProducerOnly(rows));
+        assertFalse(JSonSchemaHelper.isComponentConsumerOnly(rows));
+        String desc = null;
+        for (Map<String, String> row : rows) {
+            if (row.containsKey("description")) {
+                desc = row.get("description");
+                break;
+            }
+        }
+
+        // componentProperties
+        rows = JSonSchemaHelper.parseJsonSchema("componentProperties", json, true);
+        assertEquals(1, rows.size());
+        Map<String, String> row = JSonSchemaHelper.getRow(rows, "exchangeFormatter");
+        assertNotNull(row);
+        assertEquals("org.apache.camel.spi.ExchangeFormatter", row.get("javaType"));
+
+        // properties
+        rows = JSonSchemaHelper.parseJsonSchema("properties", json, true);
+        assertEquals(27, rows.size());
+        row = JSonSchemaHelper.getRow(rows, "level");
+        assertNotNull(row);
+        assertEquals("INFO", row.get("defaultValue"));
+        String enums = JSonSchemaHelper.getPropertyEnum(rows, "level");
+        assertEquals("ERROR,WARN,INFO,DEBUG,TRACE,OFF", enums);
+
+        row = JSonSchemaHelper.getRow(rows, "maxChars");
+        assertNotNull(row);
+        assertEquals("false", row.get("deprecated"));
+        assertEquals("10000", row.get("defaultValue"));
+    }
+
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/test/resources/org/foo/camel/dummy.json b/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
index 4c04238..feee3de 100644
--- a/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
+++ b/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
@@ -6,43 +6,44 @@
     "title": "Dummy",
     "description": "The dummy component logs message exchanges to the underlying logging mechanism.",
     "label": "core,monitoring",
-    "producerOnly": "true",
+    "producerOnly": true,
+    "consumerOnly": false,
     "javaType": "org.foo.camel.DummyComponent",
     "groupId": "org.foo.camel",
     "artifactId": "dummy",
     "version": "1.0"
   },
   "componentProperties": {
-    "exchangeFormatter": { "kind": "property", "type": "object", "javaType": "org.apache.camel.spi.ExchangeFormatter", "deprecated": "false", "description": "Sets a custom ExchangeFormatter to convert the Exchange to a String suitable for logging. If not specified we default to DefaultExchangeFormatter." }
+    "exchangeFormatter": { "kind": "property", "type": "object", "javaType": "org.apache.camel.spi.ExchangeFormatter", "deprecated": false, "description": "Sets a custom ExchangeFormatter to convert the Exchange to a String suitable for logging. If not specified we default to DefaultExchangeFormatter." }
   },
   "properties": {
-    "loggerName": { "kind": "path", "group": "producer", "required": "true", "type": "string", "javaType": "java.lang.String", "deprecated": "false", "description": "The logger name to use" },
-    "groupActiveOnly": { "kind": "parameter", "group": "producer", "type": "boolean", "javaType": "java.lang.Boolean", "deprecated": "false", "defaultValue": "true", "description": "If true will hide stats when no new messages have been received for a time interval if false show stats regardless of message traffic." },
-    "groupDelay": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Long", "deprecated": "false", "description": "Set the initial delay for stats (in millis)" },
-    "groupInterval": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Long", "deprecated": "false", "description": "If specified will group message stats by this time interval (in millis)" },
-    "groupSize": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Integer", "deprecated": "false", "description": "An integer that specifies a group size for throughput logging." },
-    "level": { "kind": "parameter", "group": "producer", "type": "string", "javaType": "java.lang.String", "enum": [ "ERROR", "WARN", "INFO", "DEBUG", "TRACE", "OFF" ], "deprecated": "false", "defaultValue": "INFO", "description": "Logging level to use. The default value is INFO." },
-    "marker": { "kind": "parameter", "group": "producer", "type": "string", "javaType": "java.lang.String", "deprecated": "false", "description": "An optional Marker name to use." },
-    "exchangePattern": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "string", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "RobustInOnly", "InOut", "InOptionalOut", "OutOnly", "RobustOutOnly", "OutIn", "OutOptionalIn" ], "deprecated": "false", "defaultValue": "InOnly", "description": "Sets the default exchange pattern when creating an exchange." },
-    "synchronous": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported)." },
-    "maxChars": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "integer", "javaType": "int", "deprecated": "false", "defaultValue": "10000", "description": "Limits the number of characters logged per line." },
-    "multiline": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "If enabled then each information is outputted on a newline." },
-    "showAll": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Quick option for turning all options on. (multiline maxChars has to be manually set if to be used)" },
-    "showBody": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "true", "description": "Show the message body." },
-    "showBodyType": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "true", "description": "Show the body Java type." },
-    "showCaughtException": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "f the exchange has a caught exception show the exception message (no stack trace). A caught exception is stored as a property on the exchange (using the key link org.apache.camel.ExchangeEXCEPTION_CAUGHT and for instance a doCatch can catch exceptions." },
-    "showException": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "If the exchange has an exception show the exception message (no stacktrace)" },
-    "showExchangeId": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Show the unique exchange ID." },
-    "showExchangePattern": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "true", "description": "Shows the Message Exchange Pattern (or MEP for short)." },
-    "showFiles": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "If enabled Camel will output files" },
-    "showFuture": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "If enabled Camel will on Future objects wait for it to complete to obtain the payload to be logged." },
-    "showHeaders": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Show the message headers." },
-    "showOut": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "If the exchange has an out message show the out message." },
-    "showProperties": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Show the exchange properties." },
-    "showStackTrace": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Show the stack trace if an exchange has an exception. Only effective if one of showAll showException or showCaughtException are enabled." },
-    "showStreams": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "false", "description": "Whether Camel should show stream bodies or not (eg such as java.io.InputStream). Beware if you enable this option then you may not be able later to access the message body as the stream have already been read by this logger. To remedy this you will have to use Stream Caching." },
-    "skipBodyLineSeparator": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": "false", "defaultValue": "true", "description": "Whether to skip line separators when logging the message body. This allows to log the message body in one line setting this option to false will preserve any line separators from the body which then will log the body as is." },
-    "style": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "string", "javaType": "org.apache.camel.processor.DefaultExchangeFormatter.OutputStyle", "enum": [ "Default", "Tab", "Fixed" ], "deprecated": "false", "defaultValue": "Default", "description": "Sets the outputs style to use." }
+    "loggerName": { "kind": "path", "group": "producer", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "description": "The logger name to use" },
+    "groupActiveOnly": { "kind": "parameter", "group": "producer", "type": "boolean", "javaType": "java.lang.Boolean", "deprecated": false, "defaultValue": true, "description": "If true will hide stats when no new messages have been received for a time interval if false show stats regardless of message traffic." },
+    "groupDelay": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Long", "deprecated": false, "description": "Set the initial delay for stats (in millis)" },
+    "groupInterval": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Long", "deprecated": false, "description": "If specified will group message stats by this time interval (in millis)" },
+    "groupSize": { "kind": "parameter", "group": "producer", "type": "integer", "javaType": "java.lang.Integer", "deprecated": false, "description": "An integer that specifies a group size for throughput logging." },
+    "level": { "kind": "parameter", "group": "producer", "type": "string", "javaType": "java.lang.String", "enum": [ "ERROR", "WARN", "INFO", "DEBUG", "TRACE", "OFF" ], "deprecated": false, "defaultValue": "INFO", "description": "Logging level to use. The default value is INFO." },
+    "marker": { "kind": "parameter", "group": "producer", "type": "string", "javaType": "java.lang.String", "deprecated": false, "description": "An optional Marker name to use." },
+    "exchangePattern": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "string", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "RobustInOnly", "InOut", "InOptionalOut", "OutOnly", "RobustOutOnly", "OutIn", "OutOptionalIn" ], "deprecated": false, "defaultValue": "InOnly", "description": "Sets the default exchange pattern when creating an exchange." },
+    "synchronous": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported)." },
+    "maxChars": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "integer", "javaType": "int", "deprecated": false, "defaultValue": 10000, "description": "Limits the number of characters logged per line." },
+    "multiline": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If enabled then each information is outputted on a newline." },
+    "showAll": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Quick option for turning all options on. (multiline maxChars has to be manually set if to be used)" },
+    "showBody": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": true, "description": "Show the message body." },
+    "showBodyType": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": true, "description": "Show the body Java type." },
+    "showCaughtException": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "f the exchange has a caught exception show the exception message (no stack trace). A caught exception is stored as a property on the exchange (using the key link org.apache.camel.ExchangeEXCEPTION_CAUGHT and for instance a doCatch can catch exceptions." },
+    "showException": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If the exchange has an exception show the exception message (no stacktrace)" },
+    "showExchangeId": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Show the unique exchange ID." },
+    "showExchangePattern": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": true, "description": "Shows the Message Exchange Pattern (or MEP for short)." },
+    "showFiles": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If enabled Camel will output files" },
+    "showFuture": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If enabled Camel will on Future objects wait for it to complete to obtain the payload to be logged." },
+    "showHeaders": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Show the message headers." },
+    "showOut": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If the exchange has an out message show the out message." },
+    "showProperties": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Show the exchange properties." },
+    "showStackTrace": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Show the stack trace if an exchange has an exception. Only effective if one of showAll showException or showCaughtException are enabled." },
+    "showStreams": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Whether Camel should show stream bodies or not (eg such as java.io.InputStream). Beware if you enable this option then you may not be able later to access the message body as the stream have already been read by this logger. To remedy this you will have to use Stream Caching." },
+    "skipBodyLineSeparator": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": true, "description": "Whether to skip line separators when logging the message body. This allows to log the message body in one line setting this option to false will preserve any line separators from the body which then will log the body as is." },
+    "style": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "string", "javaType": "org.apache.camel.processor.DefaultExchangeFormatter.OutputStyle", "enum": [ "Default", "Tab", "Fixed" ], "deprecated": false, "defaultValue": "Default", "description": "Sets the outputs style to use." }
   }
 }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-amqp-starter/src/main/java/org/apache/camel/component/amqp/springboot/AMQPComponentConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-amqp-starter/src/main/java/org/apache/camel/component/amqp/springboot/AMQPComponentConfiguration.java b/platforms/spring-boot/components-starter/camel-amqp-starter/src/main/java/org/apache/camel/component/amqp/springboot/AMQPComponentConfiguration.java
index a1d2929..5c5d623 100644
--- a/platforms/spring-boot/components-starter/camel-amqp-starter/src/main/java/org/apache/camel/component/amqp/springboot/AMQPComponentConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-amqp-starter/src/main/java/org/apache/camel/component/amqp/springboot/AMQPComponentConfiguration.java
@@ -246,7 +246,7 @@ public class AMQPComponentConfiguration {
      * value to eg 100 to control how fast the consumers will shrink when less
      * work is required.
      */
-    private Integer maxMessagesPerTask = -1;
+    private Integer maxMessagesPerTask = 1;
     /**
      * To use a custom Spring
      * org.springframework.jms.support.converter.MessageConverter so you can be
@@ -323,7 +323,7 @@ public class AMQPComponentConfiguration {
      * When sending messages specifies the time-to-live of the message (in
      * milliseconds).
      */
-    private Long timeToLive = -1L;
+    private Long timeToLive = 1L;
     /**
      * Specifies whether to use transacted mode
      */
@@ -346,7 +346,7 @@ public class AMQPComponentConfiguration {
      * The timeout value of the transaction (in seconds) if using transacted
      * mode.
      */
-    private Integer transactionTimeout = -1;
+    private Integer transactionTimeout = 1;
     /**
      * Specifies whether to test the connection on startup. This ensures that
      * when Camel starts that all the JMS consumers have a valid connection to

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/csv/springboot/BindyCsvDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/csv/springboot/BindyCsvDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/csv/springboot/BindyCsvDataFormatConfiguration.java
index 0327be2..8589bf0 100644
--- a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/csv/springboot/BindyCsvDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/csv/springboot/BindyCsvDataFormatConfiguration.java
@@ -16,7 +16,6 @@
  */
 package org.apache.camel.dataformat.bindy.csv.springboot;
 
-import org.apache.camel.dataformat.bindy.csv.BindyCsvDataFormat;
 import org.apache.camel.model.dataformat.BindyType;
 import org.springframework.boot.context.properties.ConfigurationProperties;
 
@@ -31,7 +30,7 @@ public class BindyCsvDataFormatConfiguration {
     /**
      * Whether to use csv fixed or key value pairs mode.
      */
-    private BindyType type = BindyType.Csv;
+    private BindyType type;
     /**
      * Name of model class to use.
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/fixed/springboot/BindyFixedLengthDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/fixed/springboot/BindyFixedLengthDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/fixed/springboot/BindyFixedLengthDataFormatConfiguration.java
index d852707..91ef2f5 100644
--- a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/fixed/springboot/BindyFixedLengthDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/fixed/springboot/BindyFixedLengthDataFormatConfiguration.java
@@ -16,7 +16,6 @@
  */
 package org.apache.camel.dataformat.bindy.fixed.springboot;
 
-import org.apache.camel.dataformat.bindy.fixed.BindyFixedLengthDataFormat;
 import org.apache.camel.model.dataformat.BindyType;
 import org.springframework.boot.context.properties.ConfigurationProperties;
 
@@ -31,7 +30,7 @@ public class BindyFixedLengthDataFormatConfiguration {
     /**
      * Whether to use csv fixed or key value pairs mode.
      */
-    private BindyType type = BindyType.Fixed;
+    private BindyType type;
     /**
      * Name of model class to use.
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/kvp/springboot/BindyKeyValuePairDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/kvp/springboot/BindyKeyValuePairDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/kvp/springboot/BindyKeyValuePairDataFormatConfiguration.java
index e8d6b2b..a26c9fa 100644
--- a/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/kvp/springboot/BindyKeyValuePairDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-bindy-starter/src/main/java/org/apache/camel/dataformat/bindy/kvp/springboot/BindyKeyValuePairDataFormatConfiguration.java
@@ -16,7 +16,6 @@
  */
 package org.apache.camel.dataformat.bindy.kvp.springboot;
 
-import org.apache.camel.dataformat.bindy.kvp.BindyKeyValuePairDataFormat;
 import org.apache.camel.model.dataformat.BindyType;
 import org.springframework.boot.context.properties.ConfigurationProperties;
 
@@ -31,7 +30,7 @@ public class BindyKeyValuePairDataFormatConfiguration {
     /**
      * Whether to use csv fixed or key value pairs mode.
      */
-    private BindyType type = BindyType.KeyValue;
+    private BindyType type;
     /**
      * Name of model class to use.
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-core-starter/src/main/java/org/apache/camel/impl/springboot/ZipDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-core-starter/src/main/java/org/apache/camel/impl/springboot/ZipDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-core-starter/src/main/java/org/apache/camel/impl/springboot/ZipDataFormatConfiguration.java
index 401acb9..466fe22 100644
--- a/platforms/spring-boot/components-starter/camel-core-starter/src/main/java/org/apache/camel/impl/springboot/ZipDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-core-starter/src/main/java/org/apache/camel/impl/springboot/ZipDataFormatConfiguration.java
@@ -30,7 +30,7 @@ public class ZipDataFormatConfiguration {
      * To specify a specific compression between 0-9. -1 is default compression
      * 0 is no compression and 9 is best compression.
      */
-    private Integer compressionLevel = -1;
+    private Integer compressionLevel = 1;
     /**
      * Whether the data format should set the Content-Type header with the type
      * from the data format if the data format is capable of doing so. For

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-gson-starter/src/main/java/org/apache/camel/component/gson/springboot/GsonDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-gson-starter/src/main/java/org/apache/camel/component/gson/springboot/GsonDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-gson-starter/src/main/java/org/apache/camel/component/gson/springboot/GsonDataFormatConfiguration.java
index ed36e44..cf25b31 100644
--- a/platforms/spring-boot/components-starter/camel-gson-starter/src/main/java/org/apache/camel/component/gson/springboot/GsonDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-gson-starter/src/main/java/org/apache/camel/component/gson/springboot/GsonDataFormatConfiguration.java
@@ -40,7 +40,7 @@ public class GsonDataFormatConfiguration {
     /**
      * Which json library to use.
      */
-    private JsonLibrary library = JsonLibrary.Gson;
+    private JsonLibrary library = JsonLibrary.XStream;
     /**
      * Class name of the java type to use when unarmshalling
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-jackson-starter/src/main/java/org/apache/camel/component/jackson/springboot/JacksonDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-jackson-starter/src/main/java/org/apache/camel/component/jackson/springboot/JacksonDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-jackson-starter/src/main/java/org/apache/camel/component/jackson/springboot/JacksonDataFormatConfiguration.java
index 862eb38..e5dcbc2 100644
--- a/platforms/spring-boot/components-starter/camel-jackson-starter/src/main/java/org/apache/camel/component/jackson/springboot/JacksonDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-jackson-starter/src/main/java/org/apache/camel/component/jackson/springboot/JacksonDataFormatConfiguration.java
@@ -40,7 +40,7 @@ public class JacksonDataFormatConfiguration {
     /**
      * Which json library to use.
      */
-    private JsonLibrary library = JsonLibrary.Jackson;
+    private JsonLibrary library = JsonLibrary.XStream;
     /**
      * Class name of the java type to use when unarmshalling
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-jms-starter/src/main/java/org/apache/camel/component/jms/springboot/JmsComponentConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-jms-starter/src/main/java/org/apache/camel/component/jms/springboot/JmsComponentConfiguration.java b/platforms/spring-boot/components-starter/camel-jms-starter/src/main/java/org/apache/camel/component/jms/springboot/JmsComponentConfiguration.java
index ee464ce..d01e5af 100644
--- a/platforms/spring-boot/components-starter/camel-jms-starter/src/main/java/org/apache/camel/component/jms/springboot/JmsComponentConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-jms-starter/src/main/java/org/apache/camel/component/jms/springboot/JmsComponentConfiguration.java
@@ -250,7 +250,7 @@ public class JmsComponentConfiguration {
      * value to eg 100 to control how fast the consumers will shrink when less
      * work is required.
      */
-    private Integer maxMessagesPerTask = -1;
+    private Integer maxMessagesPerTask = 1;
     /**
      * To use a custom Spring
      * org.springframework.jms.support.converter.MessageConverter so you can be
@@ -325,7 +325,7 @@ public class JmsComponentConfiguration {
      * When sending messages specifies the time-to-live of the message (in
      * milliseconds).
      */
-    private Long timeToLive = -1L;
+    private Long timeToLive = 1L;
     /**
      * Specifies whether to use transacted mode
      */
@@ -348,7 +348,7 @@ public class JmsComponentConfiguration {
      * The timeout value of the transaction (in seconds) if using transacted
      * mode.
      */
-    private Integer transactionTimeout = -1;
+    private Integer transactionTimeout = 1;
     /**
      * Specifies whether to test the connection on startup. This ensures that
      * when Camel starts that all the JMS consumers have a valid connection to

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/platforms/spring-boot/components-starter/camel-johnzon-starter/src/main/java/org/apache/camel/component/johnzon/springboot/JohnzonDataFormatConfiguration.java
----------------------------------------------------------------------
diff --git a/platforms/spring-boot/components-starter/camel-johnzon-starter/src/main/java/org/apache/camel/component/johnzon/springboot/JohnzonDataFormatConfiguration.java b/platforms/spring-boot/components-starter/camel-johnzon-starter/src/main/java/org/apache/camel/component/johnzon/springboot/JohnzonDataFormatConfiguration.java
index a12c22e..47b9093 100644
--- a/platforms/spring-boot/components-starter/camel-johnzon-starter/src/main/java/org/apache/camel/component/johnzon/springboot/JohnzonDataFormatConfiguration.java
+++ b/platforms/spring-boot/components-starter/camel-johnzon-starter/src/main/java/org/apache/camel/component/johnzon/springboot/JohnzonDataFormatConfiguration.java
@@ -40,7 +40,7 @@ public class JohnzonDataFormatConfiguration {
     /**
      * Which json library to use.
      */
-    private JsonLibrary library = JsonLibrary.Johnzon;
+    private JsonLibrary library = JsonLibrary.XStream;
     /**
      * Class name of the java type to use when unarmshalling
      */

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/tooling/apt/src/main/java/org/apache/camel/tools/apt/CoreEipAnnotationProcessor.java
----------------------------------------------------------------------
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/CoreEipAnnotationProcessor.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/CoreEipAnnotationProcessor.java
index 68063a2..b1293b5 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/CoreEipAnnotationProcessor.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/CoreEipAnnotationProcessor.java
@@ -173,9 +173,9 @@ public class CoreEipAnnotationProcessor {
         }
         buffer.append("\n    \"javaType\": \"").append(eipModel.getJavaType()).append("\",");
         buffer.append("\n    \"label\": \"").append(safeNull(eipModel.getLabel())).append("\",");
-        buffer.append("\n    \"deprecated\": \"").append(eipModel.isDeprecated()).append("\",");
-        buffer.append("\n    \"input\": \"").append(eipModel.getInput()).append("\",");
-        buffer.append("\n    \"output\": \"").append(eipModel.getOutput()).append("\"");
+        buffer.append("\n    \"deprecated\": ").append(eipModel.isDeprecated()).append(",");
+        buffer.append("\n    \"input\": ").append(eipModel.getInput()).append(",");
+        buffer.append("\n    \"output\": ").append(eipModel.getOutput());
         buffer.append("\n  },");
 
         buffer.append("\n  \"properties\": {");

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
----------------------------------------------------------------------
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
index 29dc640..e962ad4 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/EndpointAnnotationProcessor.java
@@ -180,16 +180,11 @@ public class EndpointAnnotationProcessor extends AbstractProcessor {
         buffer.append("\n    \"title\": \"").append(componentModel.getTitle()).append("\",");
         buffer.append("\n    \"description\": \"").append(componentModel.getDescription()).append("\",");
         buffer.append("\n    \"label\": \"").append(getOrElse(componentModel.getLabel(), "")).append("\",");
-        buffer.append("\n    \"deprecated\": \"").append(componentModel.isDeprecated()).append("\",");
-        buffer.append("\n    \"async\": \"").append(componentModel.isAsync()).append("\",");
-        if (componentModel.isConsumerOnly()) {
-            buffer.append("\n    \"consumerOnly\": \"").append("true").append("\",");
-        } else if (componentModel.isProducerOnly()) {
-            buffer.append("\n    \"producerOnly\": \"").append("true").append("\",");
-        }
-        if (componentModel.isLenientProperties()) {
-            buffer.append("\n    \"lenientProperties\": \"").append("true").append("\",");
-        }
+        buffer.append("\n    \"deprecated\": ").append(componentModel.isDeprecated()).append(",");
+        buffer.append("\n    \"async\": ").append(componentModel.isAsync()).append(",");
+        buffer.append("\n    \"consumerOnly\": ").append(componentModel.isConsumerOnly()).append(",");
+        buffer.append("\n    \"producerOnly\": ").append(componentModel.isProducerOnly()).append(",");
+        buffer.append("\n    \"lenientProperties\": ").append(componentModel.isLenientProperties()).append(",");
         buffer.append("\n    \"javaType\": \"").append(componentModel.getJavaType()).append("\",");
         if (componentModel.getFirstVersion() != null) {
             buffer.append("\n    \"firstVersion\": \"").append(componentModel.getFirstVersion()).append("\",");

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/tooling/apt/src/main/java/org/apache/camel/tools/apt/SpringAnnotationProcessor.java
----------------------------------------------------------------------
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/SpringAnnotationProcessor.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/SpringAnnotationProcessor.java
index 081d845..108386b 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/SpringAnnotationProcessor.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/SpringAnnotationProcessor.java
@@ -129,9 +129,9 @@ public class SpringAnnotationProcessor {
         buffer.append("\n    \"description\": \"").append(safeNull(eipModel.getDescription())).append("\",");
         buffer.append("\n    \"javaType\": \"").append(eipModel.getJavaType()).append("\",");
         buffer.append("\n    \"label\": \"").append(safeNull(eipModel.getLabel())).append("\",");
-        buffer.append("\n    \"deprecated\": \"").append("false").append("\",");
-        buffer.append("\n    \"input\": \"").append("false").append("\",");
-        buffer.append("\n    \"output\": \"").append("false").append("\"");
+        buffer.append("\n    \"deprecated\": false,");
+        buffer.append("\n    \"input\": false,");
+        buffer.append("\n    \"output\": false");
         buffer.append("\n  },");
 
         buffer.append("\n  \"properties\": {");

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
index 5b96033..955e915 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
@@ -34,7 +34,8 @@ import java.util.regex.Pattern;
 public final class JsonSchemaHelper {
 
     private static final String VALID_CHARS = ".-='/\\!&():;";
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
     private static final String QUOT = "&quot;";
 
     private JsonSchemaHelper() {
@@ -63,8 +64,9 @@ public final class JsonSchemaHelper {
         }
 
         if (required != null) {
+            // boolean type
             sb.append(", \"required\": ");
-            sb.append(Strings.doubleQuote(required.toString()));
+            sb.append(required.toString());
         }
 
         sb.append(", \"type\": ");
@@ -109,24 +111,32 @@ public final class JsonSchemaHelper {
             sb.append(Strings.doubleQuote(text));
         }
         if (multiValue) {
-            sb.append(", \"multiValue\": ");
-            sb.append(Strings.doubleQuote("true"));
+            // boolean value
+            sb.append(", \"multiValue\": true");
         }
 
         if (deprecated != null) {
             sb.append(", \"deprecated\": ");
-            sb.append(Strings.doubleQuote(deprecated.toString()));
+            // boolean value
+            sb.append(deprecated.toString());
         }
 
         if (secret != null) {
             sb.append(", \"secret\": ");
-            sb.append(Strings.doubleQuote(secret.toString()));
+            // boolean value
+            sb.append(secret.toString());
         }
 
         if (!Strings.isNullOrEmpty(defaultValue)) {
             sb.append(", \"defaultValue\": ");
             String text = safeDefaultValue(defaultValue);
-            sb.append(Strings.doubleQuote(text));
+            // the type can either be boolean, integer, number or text based
+            if ("boolean".equals(typeName) || "integer".equals(typeName) || "number".equals(typeName)) {
+                sb.append(text);
+            } else {
+                // text should be quoted
+                sb.append(Strings.doubleQuote(text));
+            }
         }
 
         // for expressions we want to know if it must be used as predicate or not
@@ -134,9 +144,9 @@ public final class JsonSchemaHelper {
         if (predicate) {
             sb.append(", \"asPredicate\": ");
             if (asPredicate) {
-                sb.append(Strings.doubleQuote("true"));
+                sb.append("true");
             } else {
-                sb.append(Strings.doubleQuote("false"));
+                sb.append("false");
             }
         }
 
@@ -345,19 +355,34 @@ public final class JsonSchemaHelper {
                     key = matcher.group(1);
                 } else {
                     String value = matcher.group(1);
-                    if (value == null) {
-                        value = matcher.group(2);
-                        // its an enum so strip out " and trim spaces after comma
-                        value = value.replaceAll("\"", "");
-                        value = value.replaceAll(", ", ",");
-                    }
                     if (value != null) {
+                        // its text based
                         value = value.trim();
                         // decode
                         value = value.replaceAll(QUOT, "\"");
                         value = decodeJson(value);
                     }
-                    row.put(key, value);
+                    if (value == null) {
+                        // not text then its maybe an enum?
+                        value = matcher.group(2);
+                        if (value != null) {
+                            // its an enum so strip out " and trim spaces after comma
+                            value = value.replaceAll("\"", "");
+                            value = value.replaceAll(", ", ",");
+                            value = value.trim();
+                        }
+                    }
+                    if (value == null) {
+                        // not text then its maybe a boolean?
+                        value = matcher.group(3);
+                    }
+                    if (value == null) {
+                        // not text then its maybe a integer?
+                        value = matcher.group(4);
+                    }
+                    if (value != null) {
+                        row.put(key, value);
+                    }
                     // reset
                     key = null;
                 }

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
index 1ac0e33..27bc6e4 100644
--- a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
+++ b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
@@ -25,7 +25,8 @@ import java.util.regex.Pattern;
 
 public final class JSonSchemaHelper {
 
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
     private static final String QUOT = "&quot;";
 
     private JSonSchemaHelper() {
@@ -79,19 +80,34 @@ public final class JSonSchemaHelper {
                     key = matcher.group(1);
                 } else {
                     String value = matcher.group(1);
-                    if (value == null) {
-                        value = matcher.group(2);
-                        // its an enum so strip out " and trim spaces after comma
-                        value = value.replaceAll("\"", "");
-                        value = value.replaceAll(", ", ",");
-                    }
                     if (value != null) {
+                        // its text based
                         value = value.trim();
                         // decode
                         value = value.replaceAll(QUOT, "\"");
                         value = decodeJson(value);
                     }
-                    row.put(key, value);
+                    if (value == null) {
+                        // not text then its maybe an enum?
+                        value = matcher.group(2);
+                        if (value != null) {
+                            // its an enum so strip out " and trim spaces after comma
+                            value = value.replaceAll("\"", "");
+                            value = value.replaceAll(", ", ",");
+                            value = value.trim();
+                        }
+                    }
+                    if (value == null) {
+                        // not text then its maybe a boolean?
+                        value = matcher.group(3);
+                    }
+                    if (value == null) {
+                        // not text then its maybe a integer?
+                        value = matcher.group(4);
+                    }
+                    if (value != null) {
+                        row.put(key, value);
+                    }
                     // reset
                     key = null;
                 }


[3/5] camel git commit: CAMEL-10842: Component JSon schema - JSon values should not always be string types

Posted by da...@apache.org.
CAMEL-10842: Component JSon schema - JSon values should not always be string types


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/197b54a3
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/197b54a3
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/197b54a3

Branch: refs/heads/master
Commit: 197b54a3d60b378eff3804ed1efb0d5c3c97a2a0
Parents: 55dcbe8
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Feb 16 13:09:44 2017 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Feb 16 13:09:44 2017 +0100

----------------------------------------------------------------------
 .../java/org/apache/camel/util/JsonSchemaHelper.java   |  4 ++--
 .../org/apache/camel/catalog/JSonSchemaHelper.java     |  4 ++--
 .../org/apache/camel/catalog/CamelCatalogTest.java     | 13 ++++++++++++-
 .../src/test/resources/org/foo/camel/dummy.json        |  2 ++
 .../camel/tools/apt/helper/JsonSchemaHelper.java       |  4 ++--
 .../apache/camel/maven/packaging/JSonSchemaHelper.java |  4 ++--
 6 files changed, 22 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java b/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
index 09e89c0..1c2c638 100644
--- a/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
+++ b/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
@@ -30,8 +30,8 @@ import java.util.regex.Pattern;
  */
 public final class JsonSchemaHelper {
 
-    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer or number
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+\\.?\\d+)");
     private static final String QUOT = "&quot;";
 
     private JsonSchemaHelper() {

http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java b/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
index 1258256..fbd2fff 100644
--- a/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
+++ b/platforms/catalog/src/main/java/org/apache/camel/catalog/JSonSchemaHelper.java
@@ -27,8 +27,8 @@ import java.util.regex.Pattern;
 
 public final class JSonSchemaHelper {
 
-    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer or number
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+\\.?\\d+)");
     private static final String QUOT = "&quot;";
 
     private JSonSchemaHelper() {

http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java b/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
index c98cd1d..78c1052 100644
--- a/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
+++ b/platforms/catalog/src/test/java/org/apache/camel/catalog/CamelCatalogTest.java
@@ -1078,6 +1078,7 @@ public class CamelCatalogTest {
                 break;
             }
         }
+        assertEquals("The dummy component logs message exchanges to the underlying logging mechanism.", desc);
 
         // componentProperties
         rows = JSonSchemaHelper.parseJsonSchema("componentProperties", json, true);
@@ -1088,7 +1089,7 @@ public class CamelCatalogTest {
 
         // properties
         rows = JSonSchemaHelper.parseJsonSchema("properties", json, true);
-        assertEquals(27, rows.size());
+        assertEquals(29, rows.size());
         row = JSonSchemaHelper.getRow(rows, "level");
         assertNotNull(row);
         assertEquals("INFO", row.get("defaultValue"));
@@ -1099,6 +1100,16 @@ public class CamelCatalogTest {
         assertNotNull(row);
         assertEquals("false", row.get("deprecated"));
         assertEquals("10000", row.get("defaultValue"));
+
+        row = JSonSchemaHelper.getRow(rows, "fontSize");
+        assertNotNull(row);
+        assertEquals("false", row.get("deprecated"));
+        assertEquals("14", row.get("defaultValue"));
+
+        row = JSonSchemaHelper.getRow(rows, "kerberosRenewJitter");
+        assertNotNull(row);
+        assertEquals("java.lang.Double", row.get("javaType"));
+        assertEquals("0.05", row.get("defaultValue"));
     }
 
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
----------------------------------------------------------------------
diff --git a/platforms/catalog/src/test/resources/org/foo/camel/dummy.json b/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
index feee3de..8dfd7b3 100644
--- a/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
+++ b/platforms/catalog/src/test/resources/org/foo/camel/dummy.json
@@ -26,6 +26,7 @@
     "marker": { "kind": "parameter", "group": "producer", "type": "string", "javaType": "java.lang.String", "deprecated": false, "description": "An optional Marker name to use." },
     "exchangePattern": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "string", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "RobustInOnly", "InOut", "InOptionalOut", "OutOnly", "RobustOutOnly", "OutIn", "OutOptionalIn" ], "deprecated": false, "defaultValue": "InOnly", "description": "Sets the default exchange pattern when creating an exchange." },
     "synchronous": { "kind": "parameter", "group": "advanced", "label": "advanced", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported)." },
+    "kerberosRenewJitter": { "kind": "parameter", "group": "security", "label": "common,security", "type": "number", "javaType": "java.lang.Double", "deprecated": false, "secret": false, "defaultValue": 0.05, "description": "Percentage of random jitter added to the renewal time." },
     "maxChars": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "integer", "javaType": "int", "deprecated": false, "defaultValue": 10000, "description": "Limits the number of characters logged per line." },
     "multiline": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "If enabled then each information is outputted on a newline." },
     "showAll": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Quick option for turning all options on. (multiline maxChars has to be manually set if to be used)" },
@@ -43,6 +44,7 @@
     "showStackTrace": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Show the stack trace if an exchange has an exception. Only effective if one of showAll showException or showCaughtException are enabled." },
     "showStreams": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": false, "description": "Whether Camel should show stream bodies or not (eg such as java.io.InputStream). Beware if you enable this option then you may not be able later to access the message body as the stream have already been read by this logger. To remedy this you will have to use Stream Caching." },
     "skipBodyLineSeparator": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "boolean", "javaType": "boolean", "deprecated": false, "defaultValue": true, "description": "Whether to skip line separators when logging the message body. This allows to log the message body in one line setting this option to false will preserve any line separators from the body which then will log the body as is." },
+    "fontSize": { "kind": "parameter", "group": "producer", "type": "number", "javaType": "float", "deprecated": false, "secret": false, "defaultValue": 14, "description": "Font size in pixels" },
     "style": { "kind": "parameter", "group": "formatting", "label": "formatting", "type": "string", "javaType": "org.apache.camel.processor.DefaultExchangeFormatter.OutputStyle", "enum": [ "Default", "Tab", "Fixed" ], "deprecated": false, "defaultValue": "Default", "description": "Sets the outputs style to use." }
   }
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java b/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
index 955e915..cf3588f 100644
--- a/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
+++ b/tooling/apt/src/main/java/org/apache/camel/tools/apt/helper/JsonSchemaHelper.java
@@ -34,8 +34,8 @@ import java.util.regex.Pattern;
 public final class JsonSchemaHelper {
 
     private static final String VALID_CHARS = ".-='/\\!&():;";
-    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer or number
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+\\.?\\d+)");
     private static final String QUOT = "&quot;";
 
     private JsonSchemaHelper() {

http://git-wip-us.apache.org/repos/asf/camel/blob/197b54a3/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
index 27bc6e4..2fbd27f 100644
--- a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
+++ b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/JSonSchemaHelper.java
@@ -25,8 +25,8 @@ import java.util.regex.Pattern;
 
 public final class JSonSchemaHelper {
 
-    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer or number
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+\\.?\\d+)");
     private static final String QUOT = "&quot;";
 
     private JSonSchemaHelper() {


[4/5] camel git commit: CAMEL-10842: Component JSon schema - JSon values should not always be string types

Posted by da...@apache.org.
CAMEL-10842: Component JSon schema - JSon values should not always be string types


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/e5a35595
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/e5a35595
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/e5a35595

Branch: refs/heads/master
Commit: e5a355952e221fac38c090df2db07a376b27a2bd
Parents: 197b54a
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Feb 16 13:16:02 2017 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Feb 16 13:16:02 2017 +0100

----------------------------------------------------------------------
 components/camel-irc/src/main/docs/irc-component.adoc            | 2 +-
 .../java/org/apache/camel/component/irc/IrcConfiguration.java    | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/e5a35595/components/camel-irc/src/main/docs/irc-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-irc/src/main/docs/irc-component.adoc b/components/camel-irc/src/main/docs/irc-component.adoc
index 13e8a15..b496788 100644
--- a/components/camel-irc/src/main/docs/irc-component.adoc
+++ b/components/camel-irc/src/main/docs/irc-component.adoc
@@ -51,7 +51,7 @@ The IRC component supports 26 endpoint options which are listed below:
 |=======================================================================
 | Name | Group | Default | Java Type | Description
 | hostname | common |  | String | *Required* Hostname for the IRC chat server
-| port | common | 6667 | int | Port number for the IRC chat server
+| port | common |  | int | Port number for the IRC chat server. If no port is configured then a default port of either 6667 6668 or 6669 is used.
 | autoRejoin | common | true | boolean | Whether to auto re-join when being kicked
 | namesOnJoin | common | false | boolean | Sends NAMES command to channel after joining it. link onReply has to be true in order to process the result which will have the header value irc.num = '353'.
 | nickname | common |  | String | The nickname used in chat.

http://git-wip-us.apache.org/repos/asf/camel/blob/e5a35595/components/camel-irc/src/main/java/org/apache/camel/component/irc/IrcConfiguration.java
----------------------------------------------------------------------
diff --git a/components/camel-irc/src/main/java/org/apache/camel/component/irc/IrcConfiguration.java b/components/camel-irc/src/main/java/org/apache/camel/component/irc/IrcConfiguration.java
index beebf81..abaeb65 100644
--- a/components/camel-irc/src/main/java/org/apache/camel/component/irc/IrcConfiguration.java
+++ b/components/camel-irc/src/main/java/org/apache/camel/component/irc/IrcConfiguration.java
@@ -48,7 +48,7 @@ public class IrcConfiguration implements Cloneable {
 
     @UriPath @Metadata(required = "true")
     private String hostname;
-    @UriPath(defaultValue = "6667,6668,6669")
+    @UriPath
     private int port;
     private int[] ports = {6667, 6668, 6669};
     @UriParam(label = "security", secret = true)
@@ -295,7 +295,7 @@ public class IrcConfiguration implements Cloneable {
     }
 
     /**
-     * Port number for the IRC chat server
+     * Port number for the IRC chat server. If no port is configured then a default port of either 6667, 6668 or 6669 is used.
      */
     public void setPort(int port) {
         this.port = port;


[5/5] camel git commit: CAMEL-10842: Component JSon schema - JSon values should not always be string types

Posted by da...@apache.org.
CAMEL-10842: Component JSon schema - JSon values should not always be string types


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/c4607e6c
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/c4607e6c
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/c4607e6c

Branch: refs/heads/master
Commit: c4607e6c519541a1870ce225cbdd8fa8a3ea2e3e
Parents: e5a3559
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Feb 16 13:25:04 2017 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Feb 16 13:25:04 2017 +0100

----------------------------------------------------------------------
 ...wseComponentConfigurationAndDocumentationTest.java |  2 +-
 ...matComponentConfigurationAndDocumentationTest.java | 14 +++++++-------
 ...SetComponentConfigurationAndDocumentationTest.java |  2 +-
 ...ectComponentConfigurationAndDocumentationTest.java |  2 +-
 ...tVmComponentConfigurationAndDocumentationTest.java |  2 +-
 .../apache/camel/itest/doc/EipDocumentationTest.java  |  6 +++---
 ...ileComponentConfigurationAndDocumentationTest.java |  2 +-
 ...ageComponentConfigurationAndDocumentationTest.java |  2 +-
 ...LogComponentConfigurationAndDocumentationTest.java |  2 +-
 ...ockComponentConfigurationAndDocumentationTest.java |  2 +-
 ...mpleLanguageConfigurationAndDocumentationTest.java |  2 +-
 ...ngDataFormatConfigurationAndDocumentationTest.java |  2 +-
 ...estComponentConfigurationAndDocumentationTest.java |  2 +-
 ...merComponentConfigurationAndDocumentationTest.java |  2 +-
 ...sltComponentConfigurationAndDocumentationTest.java |  2 +-
 15 files changed, 23 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/BrowseComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/BrowseComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/BrowseComponentConfigurationAndDocumentationTest.java
index 5e93898..af4caaf 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/BrowseComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/BrowseComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class BrowseComponentConfigurationAndDocumentationTest extends CamelTestS
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": \"true\", \"type\": \"string\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": true, \"type\": \"string\""));
         assertTrue(json.contains("\"synchronous\": { \"kind\": \"parameter\", \"group\": \"advanced\", \"label\": \"advanced\", \"type\": \"boolean\""));
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataFormatComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataFormatComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataFormatComponentConfigurationAndDocumentationTest.java
index 2dc0f58..483d7e3 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataFormatComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataFormatComponentConfigurationAndDocumentationTest.java
@@ -46,9 +46,9 @@ public class DataFormatComponentConfigurationAndDocumentationTest extends CamelT
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\", \"type\": \"string\", \"javaType\": \"java.lang.String\","
-            + " \"deprecated\": \"false\", \"secret\": \"false\", \"description\": \"Name of data format\" }"));
-        assertTrue(json.contains("\"operation\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\", \"type\": \"string\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true, \"type\": \"string\", \"javaType\": \"java.lang.String\","
+            + " \"deprecated\": false, \"secret\": false, \"description\": \"Name of data format\" }"));
+        assertTrue(json.contains("\"operation\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true, \"type\": \"string\""));
         assertTrue(json.contains("\"synchronous\": { \"kind\": \"parameter\", \"group\": \"advanced\", \"label\": \"advanced\", \"type\": \"boolean\""));
     }
 
@@ -61,8 +61,8 @@ public class DataFormatComponentConfigurationAndDocumentationTest extends CamelT
         assertTrue(json.contains("\"name\": \"flatpack"));
 
         // the default value is a bit tricky as its ", which is written escaped as \"
-        assertTrue(json.contains("\"textQualifier\": { \"kind\": \"attribute\", \"required\": \"false\", \"type\": \"string\""
-            + ", \"javaType\": \"java.lang.String\", \"deprecated\": \"false\", \"secret\": \"false\", \"defaultValue\": \"\\\"\""));
+        assertTrue(json.contains("\"textQualifier\": { \"kind\": \"attribute\", \"required\": false, \"type\": \"string\""
+            + ", \"javaType\": \"java.lang.String\", \"deprecated\": false, \"secret\": false, \"defaultValue\": \"\\\"\""));
 
         List<Map<String, String>> rows = JsonSchemaHelper.parseJsonSchema("properties", json, true);
         assertEquals(10, rows.size());
@@ -95,8 +95,8 @@ public class DataFormatComponentConfigurationAndDocumentationTest extends CamelT
         assertTrue(json.contains("\"name\": \"univocity-tsv"));
 
         // the default value is a bit tricky as its \, which is written escaped as \\
-        assertTrue(json.contains("\"escapeChar\": { \"kind\": \"attribute\", \"required\": \"false\", \"type\": \"string\", \"javaType\": \"java.lang.String\","
-            + " \"deprecated\": \"false\", \"secret\": \"false\", \"defaultValue\": \"\\\\\", \"description\": \"The escape character.\""));
+        assertTrue(json.contains("\"escapeChar\": { \"kind\": \"attribute\", \"required\": false, \"type\": \"string\", \"javaType\": \"java.lang.String\","
+            + " \"deprecated\": false, \"secret\": false, \"defaultValue\": \"\\\\\", \"description\": \"The escape character.\""));
 
         List<Map<String, String>> rows = JsonSchemaHelper.parseJsonSchema("properties", json, true);
         assertEquals(16, rows.size());

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataSetComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataSetComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataSetComponentConfigurationAndDocumentationTest.java
index 0c324fa..6e831d6 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataSetComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DataSetComponentConfigurationAndDocumentationTest.java
@@ -45,7 +45,7 @@ public class DataSetComponentConfigurationAndDocumentationTest extends CamelTest
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": \"true\", \"type\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": true, \"type\""));
         assertTrue(json.contains("\"kind\": \"parameter\", \"group\": \"consumer\", \"label\": \"consumer\", \"type\": \"integer\""));
         assertTrue(json.contains("\"retainFirst\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\", \"type\": \"integer"));
     }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectComponentConfigurationAndDocumentationTest.java
index bd23882..34ba179 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectComponentConfigurationAndDocumentationTest.java
@@ -42,7 +42,7 @@ public class DirectComponentConfigurationAndDocumentationTest extends CamelTestS
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": \"true\", \"type\": \"string\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": true, \"type\": \"string\""));
         assertTrue(json.contains("\"timeout\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\", \"type\": \"integer\""));
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectVmComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectVmComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectVmComponentConfigurationAndDocumentationTest.java
index 57d7fff..32f5750 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectVmComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/DirectVmComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class DirectVmComponentConfigurationAndDocumentationTest extends CamelTes
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": \"true\", \"type\": \"string\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"common\", \"required\": true, \"type\": \"string\""));
         assertTrue(json.contains("\"timeout\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\", \"type\": \"integer\""));
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/EipDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/EipDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/EipDocumentationTest.java
index 6d96a9c..2a8cef1 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/EipDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/EipDocumentationTest.java
@@ -51,7 +51,7 @@ public class EipDocumentationTest extends CamelTestSupport {
         // there should be javadoc included
         assertTrue(json.contains("If enabled then processing each splitted messages occurs concurrently."));
         // and it support outputs
-        assertTrue(json.contains("\"outputs\": { \"kind\": \"element\", \"required\": \"true\", \"type\": \"array\", \"javaType\""));
+        assertTrue(json.contains("\"outputs\": { \"kind\": \"element\", \"required\": true, \"type\": \"array\", \"javaType\""));
     }
 
     @Test
@@ -73,8 +73,8 @@ public class EipDocumentationTest extends CamelTestSupport {
         assertNotNull("Should have found json for failover", json);
 
         assertTrue(json.contains("\"name\": \"failover\""));
-        assertTrue(json.contains("\"exception\": { \"kind\": \"element\", \"required\": \"false\", \"type\": \"array\""
-            + ", \"javaType\": \"java.util.List<java.lang.String>\", \"deprecated\": \"false\""));
+        assertTrue(json.contains("\"exception\": { \"kind\": \"element\", \"required\": false, \"type\": \"array\""
+            + ", \"javaType\": \"java.util.List<java.lang.String>\", \"deprecated\": false"));
     }
 
     @Test

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/FileComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/FileComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/FileComponentConfigurationAndDocumentationTest.java
index e221a1b..d1c8548 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/FileComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/FileComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class FileComponentConfigurationAndDocumentationTest extends CamelTestSup
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"directoryName\": { \"kind\": \"path\", \"group\": \"common\", \"required\": \"true\""));
+        assertTrue(json.contains("\"directoryName\": { \"kind\": \"path\", \"group\": \"common\", \"required\": true"));
         assertTrue(json.contains("\"autoCreate\": { \"kind\": \"parameter\", \"group\": \"advanced\", \"label\": \"advanced\", \"type\": \"boolean\""));
         assertTrue(json.contains("\"readLockMinAge\": { \"kind\": \"parameter\", \"group\": \"lock\", \"label\": \"consumer,lock\""));
     }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LanguageComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LanguageComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LanguageComponentConfigurationAndDocumentationTest.java
index dc33117..5e6c3e5 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LanguageComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LanguageComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class LanguageComponentConfigurationAndDocumentationTest extends CamelTes
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"languageName\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"languageName\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true"));
         assertTrue(json.contains("\"script\": { \"kind\": \"parameter\", \"group\": \"producer\", \"type\": \"string\""));
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LogComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LogComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LogComponentConfigurationAndDocumentationTest.java
index f569eb6..2758d70 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LogComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/LogComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class LogComponentConfigurationAndDocumentationTest extends CamelTestSupp
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"loggerName\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"loggerName\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true"));
         assertTrue(json.contains("\"level\": { \"kind\": \"parameter\", \"group\": \"producer\", \"type\": \"string\""));
         assertTrue(json.contains("\"showBody\": { \"kind\": \"parameter\", \"group\": \"formatting\", \"label\": \"formatting\""));
     }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/MockComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/MockComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/MockComponentConfigurationAndDocumentationTest.java
index 1058bbc..596c3c8 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/MockComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/MockComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class MockComponentConfigurationAndDocumentationTest extends CamelTestSup
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true"));
         assertTrue(json.contains("\"expectedCount\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\""));
         assertTrue(json.contains("\"retainFirst\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\""));
     }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/SimpleLanguageConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/SimpleLanguageConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/SimpleLanguageConfigurationAndDocumentationTest.java
index 60c1545..bde859a 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/SimpleLanguageConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/SimpleLanguageConfigurationAndDocumentationTest.java
@@ -37,7 +37,7 @@ public class SimpleLanguageConfigurationAndDocumentationTest extends CamelTestSu
 
         assertTrue(json.contains("\"name\": \"simple\""));
         assertTrue(json.contains("\"modelName\": \"simple\""));
-        assertTrue(json.contains("\"resultType\": { \"kind\": \"attribute\", \"required\": \"false\", \"type\": \"string\", \"javaType\": \"java.lang.String\", \"deprecated\": \"false\""));
+        assertTrue(json.contains("\"resultType\": { \"kind\": \"attribute\", \"required\": false, \"type\": \"string\", \"javaType\": \"java.lang.String\", \"deprecated\": false"));
     }
 
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/StringDataFormatConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/StringDataFormatConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/StringDataFormatConfigurationAndDocumentationTest.java
index e110cc2..8a735fa 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/StringDataFormatConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/StringDataFormatConfigurationAndDocumentationTest.java
@@ -37,7 +37,7 @@ public class StringDataFormatConfigurationAndDocumentationTest extends CamelTest
 
         assertTrue(json.contains("\"name\": \"string\""));
         assertTrue(json.contains("\"modelName\": \"string\""));
-        assertTrue(json.contains("\"charset\": { \"kind\": \"attribute\", \"required\": \"false\", \"type\": \"string\", \"javaType\": \"java.lang.String\", \"deprecated\": \"false\""));
+        assertTrue(json.contains("\"charset\": { \"kind\": \"attribute\", \"required\": false, \"type\": \"string\", \"javaType\": \"java.lang.String\", \"deprecated\": false"));
     }
 
 }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TestComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TestComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TestComponentConfigurationAndDocumentationTest.java
index a6cf07a..3281e49 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TestComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TestComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class TestComponentConfigurationAndDocumentationTest extends CamelTestSup
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"name\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true"));
         assertTrue(json.contains("\"retainFirst\": { \"kind\": \"parameter\", \"group\": \"producer\", \"label\": \"producer\""));
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TimerComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TimerComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TimerComponentConfigurationAndDocumentationTest.java
index 193ab07..e2bc4a3 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TimerComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/TimerComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class TimerComponentConfigurationAndDocumentationTest extends CamelTestSu
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"timerName\": { \"kind\": \"path\", \"group\": \"consumer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"timerName\": { \"kind\": \"path\", \"group\": \"consumer\", \"required\": true"));
         assertTrue(json.contains("\"delay\": { \"kind\": \"parameter\", \"group\": \"consumer\", \"type\": \"integer\""));
         assertTrue(json.contains("\"timer\": { \"kind\": \"parameter\", \"group\": \"advanced\", \"label\": \"advanced\""));
     }

http://git-wip-us.apache.org/repos/asf/camel/blob/c4607e6c/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/XsltComponentConfigurationAndDocumentationTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/XsltComponentConfigurationAndDocumentationTest.java b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/XsltComponentConfigurationAndDocumentationTest.java
index f286ea5..26bb7f9 100644
--- a/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/XsltComponentConfigurationAndDocumentationTest.java
+++ b/tests/camel-itest/src/test/java/org/apache/camel/itest/doc/XsltComponentConfigurationAndDocumentationTest.java
@@ -40,7 +40,7 @@ public class XsltComponentConfigurationAndDocumentationTest extends CamelTestSup
         String json = compConf.createParameterJsonSchema();
         assertNotNull(json);
 
-        assertTrue(json.contains("\"resourceUri\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": \"true\""));
+        assertTrue(json.contains("\"resourceUri\": { \"kind\": \"path\", \"group\": \"producer\", \"required\": true"));
         assertTrue(json.contains("\"allowStAX\": { \"kind\": \"parameter\", \"group\": \"producer\", \"type\": \"boolean\""));
         assertTrue(json.contains("\"transformerFactoryClass\": { \"kind\": \"parameter\", \"group\": \"advanced\", \"label\": \"advanced\""));
     }


[2/5] camel git commit: CAMEL-10842: Component JSon schema - JSon values should not always be string types

Posted by da...@apache.org.
CAMEL-10842: Component JSon schema - JSon values should not always be string types


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/55dcbe80
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/55dcbe80
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/55dcbe80

Branch: refs/heads/master
Commit: 55dcbe801e76bead67a715026e91540b857f5cbf
Parents: 9ea5360
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Feb 16 12:57:29 2017 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Feb 16 12:57:29 2017 +0100

----------------------------------------------------------------------
 camel-core/src/main/docs/dataset-component.adoc |  8 +--
 camel-core/src/main/docs/mock-component.adoc    |  8 +--
 camel-core/src/main/docs/test-component.adoc    |  8 +--
 camel-core/src/main/docs/zip-dataformat.adoc    |  4 +-
 .../org/apache/camel/util/JsonSchemaHelper.java | 76 ++++++++++----------
 .../src/main/docs/amqp-component.adoc           | 14 ++--
 .../src/main/docs/couchbase-component.adoc      |  8 +--
 .../src/main/docs/elsql-component.adoc          |  4 +-
 .../src/main/docs/json-gson-dataformat.adoc     |  4 +-
 .../camel-irc/src/main/docs/irc-component.adoc  |  4 +-
 .../src/main/docs/json-jackson-dataformat.adoc  |  4 +-
 .../camel-jms/src/main/docs/jms-component.adoc  | 14 ++--
 .../src/main/docs/json-johnzon-dataformat.adoc  |  4 +-
 .../camel-jpa/src/main/docs/jpa-component.adoc  |  4 +-
 .../src/main/docs/kafka-component.adoc          |  4 +-
 .../src/main/docs/mail-component.adoc           |  4 +-
 .../src/main/docs/mina-component.adoc           |  4 +-
 .../src/main/docs/mina2-component.adoc          |  4 +-
 .../src/main/docs/mllp-component.adoc           |  4 +-
 .../src/main/docs/mongodb-component.adoc        |  4 +-
 .../src/main/docs/mqtt-component.adoc           |  8 +--
 .../src/main/docs/netty-http-component.adoc     |  4 +-
 .../src/main/docs/netty-component.adoc          |  4 +-
 .../src/main/docs/netty4-http-component.adoc    |  4 +-
 .../src/main/docs/netty4-component.adoc         |  4 +-
 .../src/main/docs/sjms-component.adoc           |  6 +-
 .../camel-sql/src/main/docs/sql-component.adoc  |  4 +-
 .../src/main/docs/websocket-component.adoc      |  4 +-
 .../src/main/docs/yammer-component.adoc         |  8 +--
 .../apache/camel/catalog/JSonSchemaHelper.java  | 32 ++++++---
 .../apache/camel/catalog/CamelCatalogTest.java  | 40 +++++++++++
 .../src/test/resources/org/foo/camel/dummy.json | 59 +++++++--------
 .../springboot/AMQPComponentConfiguration.java  |  6 +-
 .../BindyCsvDataFormatConfiguration.java        |  3 +-
 ...BindyFixedLengthDataFormatConfiguration.java |  3 +-
 ...indyKeyValuePairDataFormatConfiguration.java |  3 +-
 .../springboot/ZipDataFormatConfiguration.java  |  2 +-
 .../springboot/GsonDataFormatConfiguration.java |  2 +-
 .../JacksonDataFormatConfiguration.java         |  2 +-
 .../springboot/JmsComponentConfiguration.java   |  6 +-
 .../JohnzonDataFormatConfiguration.java         |  2 +-
 .../tools/apt/CoreEipAnnotationProcessor.java   |  6 +-
 .../tools/apt/EndpointAnnotationProcessor.java  | 15 ++--
 .../tools/apt/SpringAnnotationProcessor.java    |  6 +-
 .../tools/apt/helper/JsonSchemaHelper.java      | 57 ++++++++++-----
 .../camel/maven/packaging/JSonSchemaHelper.java | 32 ++++++---
 46 files changed, 301 insertions(+), 209 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/camel-core/src/main/docs/dataset-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/dataset-component.adoc b/camel-core/src/main/docs/dataset-component.adoc
index 2170661..b4f8245 100644
--- a/camel-core/src/main/docs/dataset-component.adoc
+++ b/camel-core/src/main/docs/dataset-component.adoc
@@ -67,12 +67,12 @@ The Dataset component supports 20 endpoint options which are listed below:
 | exchangePattern | consumer (advanced) |  | ExchangePattern | Sets the default exchange pattern when creating an exchange.
 | assertPeriod | producer | 0 | long | Sets a grace period after which the mock endpoint will re-assert to ensure the preliminary assertion is still valid. This is used for example to assert that exactly a number of messages arrives. For example if link expectedMessageCount(int) was set to 5 then the assertion is satisfied when 5 or more message arrives. To ensure that exactly 5 messages arrives then you would need to wait a little period to ensure no further message arrives. This is what you can use this link setAssertPeriod(long) method for. By default this period is disabled.
 | consumeDelay | producer | 0 | long | Allows a delay to be specified which causes a delay when a message is consumed by the producer (to simulate slow processing)
-| expectedCount | producer | -1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
+| expectedCount | producer | 1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
 | reportGroup | producer |  | int | A number that is used to turn on throughput logging based on groups of the size.
 | resultMinimumWaitTime | producer | 0 | long | Sets the minimum expected amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
 | resultWaitTime | producer | 0 | long | Sets the maximum amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
-| retainFirst | producer | -1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
-| retainLast | producer | -1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainFirst | producer | 1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainLast | producer | 1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
 | sleepForEmptyTest | producer | 0 | long | Allows a sleep to be specified to wait to check that this endpoint really is empty when link expectedMessageCount(int) is called with zero
 | copyOnExchange | producer (advanced) | true | boolean | Sets whether to make a deep copy of the incoming Exchange when received at this mock endpoint. Is by default true.
 | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
@@ -209,4 +209,4 @@ the file into multiple payloads.
 * link:component.html[Component]
 * link:endpoint.html[Endpoint]
 * link:getting-started.html[Getting Started]
-* link:spring-testing.html[Spring Testing]
\ No newline at end of file
+* link:spring-testing.html[Spring Testing]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/camel-core/src/main/docs/mock-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/mock-component.adoc b/camel-core/src/main/docs/mock-component.adoc
index 6ac3a1c..47b8e39 100644
--- a/camel-core/src/main/docs/mock-component.adoc
+++ b/camel-core/src/main/docs/mock-component.adoc
@@ -101,12 +101,12 @@ The Mock component supports 11 endpoint options which are listed below:
 | Name | Group | Default | Java Type | Description
 | name | producer |  | String | *Required* Name of mock endpoint
 | assertPeriod | producer | 0 | long | Sets a grace period after which the mock endpoint will re-assert to ensure the preliminary assertion is still valid. This is used for example to assert that exactly a number of messages arrives. For example if link expectedMessageCount(int) was set to 5 then the assertion is satisfied when 5 or more message arrives. To ensure that exactly 5 messages arrives then you would need to wait a little period to ensure no further message arrives. This is what you can use this link setAssertPeriod(long) method for. By default this period is disabled.
-| expectedCount | producer | -1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
+| expectedCount | producer | 1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
 | reportGroup | producer |  | int | A number that is used to turn on throughput logging based on groups of the size.
 | resultMinimumWaitTime | producer | 0 | long | Sets the minimum expected amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
 | resultWaitTime | producer | 0 | long | Sets the maximum amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
-| retainFirst | producer | -1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
-| retainLast | producer | -1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainFirst | producer | 1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainLast | producer | 1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
 | sleepForEmptyTest | producer | 0 | long | Allows a sleep to be specified to wait to check that this endpoint really is empty when link expectedMessageCount(int) is called with zero
 | copyOnExchange | producer (advanced) | true | boolean | Sets whether to make a deep copy of the incoming Exchange when received at this mock endpoint. Is by default true.
 | synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
@@ -486,4 +486,4 @@ In the example above we use `seconds` as the time unit, but Camel offers
 * link:getting-started.html[Getting Started]
 
 * link:spring-testing.html[Spring Testing]
-* link:testing.html[Testing]
\ No newline at end of file
+* link:testing.html[Testing]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/camel-core/src/main/docs/test-component.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/test-component.adoc b/camel-core/src/main/docs/test-component.adoc
index 6423fdb..de3a5f1 100644
--- a/camel-core/src/main/docs/test-component.adoc
+++ b/camel-core/src/main/docs/test-component.adoc
@@ -68,12 +68,12 @@ The Test component supports 15 endpoint options which are listed below:
 | anyOrder | producer | false | boolean | Whether the expected messages should arrive in the same order or can be in any order.
 | assertPeriod | producer | 0 | long | Sets a grace period after which the mock endpoint will re-assert to ensure the preliminary assertion is still valid. This is used for example to assert that exactly a number of messages arrives. For example if link expectedMessageCount(int) was set to 5 then the assertion is satisfied when 5 or more message arrives. To ensure that exactly 5 messages arrives then you would need to wait a little period to ensure no further message arrives. This is what you can use this link setAssertPeriod(long) method for. By default this period is disabled.
 | delimiter | producer |  | String | The split delimiter to use when split is enabled. By default the delimiter is new line based. The delimiter can be a regular expression.
-| expectedCount | producer | -1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
+| expectedCount | producer | 1 | int | Specifies the expected number of message exchanges that should be received by this endpoint. Beware: If you want to expect that 0 messages then take extra care as 0 matches when the tests starts so you need to set a assert period time to let the test run for a while to make sure there are still no messages arrived; for that use link setAssertPeriod(long). An alternative is to use NotifyBuilder and use the notifier to know when Camel is done routing some messages before you call the link assertIsSatisfied() method on the mocks. This allows you to not use a fixed assert period to speedup testing times. If you want to assert that exactly n'th message arrives to this mock endpoint then see also the link setAssertPeriod(long) method for further details.
 | reportGroup | producer |  | int | A number that is used to turn on throughput logging based on groups of the size.
 | resultMinimumWaitTime | producer | 0 | long | Sets the minimum expected amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
 | resultWaitTime | producer | 0 | long | Sets the maximum amount of time (in millis) the link assertIsSatisfied() will wait on a latch until it is satisfied
-| retainFirst | producer | -1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
-| retainLast | producer | -1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainFirst | producer | 1 | int | Specifies to only retain the first n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the first 10 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the first 10 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
+| retainLast | producer | 1 | int | Specifies to only retain the last n'th number of received Exchanges. This is used when testing with big data to reduce memory consumption by not storing copies of every Exchange this mock endpoint receives. Important: When using this limitation then the link getReceivedCounter() will still return the actual number of received Exchanges. For example if we have received 5000 Exchanges and have configured to only retain the last 20 Exchanges then the link getReceivedCounter() will still return 5000 but there is only the last 20 Exchanges in the link getExchanges() and link getReceivedExchanges() methods. When using this method then some of the other expectation methods is not supported for example the link expectedBodiesReceived(Object...) sets a expectation on the first number of bodies received. You can configure both link setRetainFirst(int) and link setRetainLast(int) methods to limit both the first and last received.
 | sleepForEmptyTest | producer | 0 | long | Allows a sleep to be specified to wait to check that this endpoint really is empty when link expectedMessageCount(int) is called with zero
 | split | producer | false | boolean | If enabled the the messages loaded from the test endpoint will be split using \n\r delimiters (new lines) so each line is an expected message. For example to use a file endpoint to load a file where each line is an expected message.
 | timeout | producer | 2000 | long | The timeout to use when polling for message bodies from the URI
@@ -108,4 +108,4 @@ link:mock.html[Mock] component.
 * link:endpoint.html[Endpoint]
 * link:getting-started.html[Getting Started]
 
-* link:spring-testing.html[Spring Testing]
\ No newline at end of file
+* link:spring-testing.html[Spring Testing]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/camel-core/src/main/docs/zip-dataformat.adoc
----------------------------------------------------------------------
diff --git a/camel-core/src/main/docs/zip-dataformat.adoc b/camel-core/src/main/docs/zip-dataformat.adoc
index f0ddbee..fd338bb 100644
--- a/camel-core/src/main/docs/zip-dataformat.adoc
+++ b/camel-core/src/main/docs/zip-dataformat.adoc
@@ -27,7 +27,7 @@ The Zip Deflate Compression dataformat supports 2 options which are listed below
 [width="100%",cols="2s,1m,1m,6",options="header"]
 |=======================================================================
 | Name | Default | Java Type | Description
-| compressionLevel | -1 | Integer | To specify a specific compression between 0-9. -1 is default compression 0 is no compression and 9 is best compression.
+| compressionLevel | 1 | Integer | To specify a specific compression between 0-9. -1 is default compression 0 is no compression and 9 is best compression.
 | contentTypeHeader | false | Boolean | Whether the data format should set the Content-Type header with the type from the data format if the data format is capable of doing so. For example application/xml for data formats marshalling to XML or application/json for data formats marshalling to JSon etc.
 |=======================================================================
 {% endraw %}
@@ -68,4 +68,4 @@ from("activemq:queue:MY_QUEUE").unmarshal().zip().process(new UnZippedMessagePro
 ### Dependencies
 
 This data format is provided in *camel-core* so no additional
-dependencies are needed.
\ No newline at end of file
+dependencies are needed.

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java b/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
index df7ff01..09e89c0 100644
--- a/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
+++ b/camel-core/src/main/java/org/apache/camel/util/JsonSchemaHelper.java
@@ -30,7 +30,8 @@ import java.util.regex.Pattern;
  */
 public final class JsonSchemaHelper {
 
-    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]");
+    // 0 = text, 1 = enum, 2 = boolean, 3 = integer
+    private static final Pattern PATTERN = Pattern.compile("\"(.+?)\"|\\[(.+)\\]|(true|false)|(\\d+)");
     private static final String QUOT = "&quot;";
 
     private JsonSchemaHelper() {
@@ -49,10 +50,10 @@ public final class JsonSchemaHelper {
             return "array";
         }
         if (type.isAssignableFrom(URI.class) || type.isAssignableFrom(URL.class)) {
-            return "sting";
+            return "string";
         }
 
-        String primitive = getPrimitiveType(type);
+        String primitive = getPrimitiveType(type.getCanonicalName());
         if (primitive != null) {
             return primitive;
         }
@@ -63,11 +64,10 @@ public final class JsonSchemaHelper {
     /**
      * Gets the JSon schema primitive type.
      *
-     * @param type the java type
-     * @return the json schema primitive type, or <tt>null</tt> if not a primitive
+     * @param   name the java type
+     * @return  the json schema primitive type, or <tt>null</tt> if not a primitive
      */
-    public static String getPrimitiveType(Class<?> type) {
-        String name = type.getCanonicalName();
+    public static String getPrimitiveType(String name) {
 
         // special for byte[] or Object[] as its common to use
         if ("java.lang.byte[]".equals(name) || "byte[]".equals(name)) {
@@ -78,36 +78,23 @@ public final class JsonSchemaHelper {
             return "array";
         } else if ("java.lang.String[]".equals(name) || "String[]".equals(name)) {
             return "array";
-            // and these is common as well
+        } else if ("java.lang.Character".equals(name) || "Character".equals(name) || "char".equals(name)) {
+            return "string";
         } else if ("java.lang.String".equals(name) || "String".equals(name)) {
             return "string";
-        } else if ("java.lang.Boolean".equals(name) || "Boolean".equals(name)) {
+        } else if ("java.lang.Boolean".equals(name) || "Boolean".equals(name) || "boolean".equals(name)) {
             return "boolean";
-        } else if ("boolean".equals(name)) {
-            return "boolean";
-        } else if ("java.lang.Integer".equals(name) || "Integer".equals(name)) {
-            return "integer";
-        } else if ("int".equals(name)) {
-            return "integer";
-        } else if ("java.lang.Long".equals(name) || "Long".equals(name)) {
+        } else if ("java.lang.Integer".equals(name) || "Integer".equals(name) || "int".equals(name)) {
             return "integer";
-        } else if ("long".equals(name)) {
+        } else if ("java.lang.Long".equals(name) || "Long".equals(name) || "long".equals(name)) {
             return "integer";
-        } else if ("java.lang.Short".equals(name) || "Short".equals(name)) {
+        } else if ("java.lang.Short".equals(name) || "Short".equals(name) || "short".equals(name)) {
             return "integer";
-        } else if ("short".equals(name)) {
+        } else if ("java.lang.Byte".equals(name) || "Byte".equals(name) || "byte".equals(name)) {
             return "integer";
-        } else if ("java.lang.Byte".equals(name) || "Byte".equals(name)) {
-            return "integer";
-        } else if ("byte".equals(name)) {
-            return "integer";
-        } else if ("java.lang.Float".equals(name) || "Float".equals(name)) {
-            return "number";
-        } else if ("float".equals(name)) {
+        } else if ("java.lang.Float".equals(name) || "Float".equals(name) || "float".equals(name)) {
             return "number";
-        } else if ("java.lang.Double".equals(name) || "Double".equals(name)) {
-            return "number";
-        } else if ("double".equals(name)) {
+        } else if ("java.lang.Double".equals(name) || "Double".equals(name) || "double".equals(name)) {
             return "number";
         }
 
@@ -118,7 +105,7 @@ public final class JsonSchemaHelper {
      * Parses the json schema to split it into a list or rows, where each row contains key value pairs with the metadata
      *
      * @param group the group to parse from such as <tt>component</tt>, <tt>componentProperties</tt>, or <tt>properties</tt>.
-     * @param json  the json
+     * @param json the json
      * @return a list of all the rows, where each row is a set of key value pairs with metadata
      */
     public static List<Map<String, String>> parseJsonSchema(String group, String json, boolean parseProperties) {
@@ -162,19 +149,34 @@ public final class JsonSchemaHelper {
                     key = matcher.group(1);
                 } else {
                     String value = matcher.group(1);
-                    if (value == null) {
-                        value = matcher.group(2);
-                        // its an enum so strip out " and trim spaces after comma
-                        value = value.replaceAll("\"", "");
-                        value = value.replaceAll(", ", ",");
-                    }
                     if (value != null) {
+                        // its text based
                         value = value.trim();
                         // decode
                         value = value.replaceAll(QUOT, "\"");
                         value = decodeJson(value);
                     }
-                    row.put(key, value);
+                    if (value == null) {
+                        // not text then its maybe an enum?
+                        value = matcher.group(2);
+                        if (value != null) {
+                            // its an enum so strip out " and trim spaces after comma
+                            value = value.replaceAll("\"", "");
+                            value = value.replaceAll(", ", ",");
+                            value = value.trim();
+                        }
+                    }
+                    if (value == null) {
+                        // not text then its maybe a boolean?
+                        value = matcher.group(3);
+                    }
+                    if (value == null) {
+                        // not text then its maybe a integer?
+                        value = matcher.group(4);
+                    }
+                    if (value != null) {
+                        row.put(key, value);
+                    }
                     // reset
                     key = null;
                 }

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-amqp/src/main/docs/amqp-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-amqp/src/main/docs/amqp-component.adoc b/components/camel-amqp/src/main/docs/amqp-component.adoc
index 804ea26..5eabd0f 100644
--- a/components/camel-amqp/src/main/docs/amqp-component.adoc
+++ b/components/camel-amqp/src/main/docs/amqp-component.adoc
@@ -76,7 +76,7 @@ The AMQP component supports 75 options which are listed below.
 | maxConcurrentConsumers | consumer |  | int | Specifies the maximum number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToMaxConcurrentConsumers is used to control number of concurrent consumers on the reply message listener.
 | replyToMaxConcurrentConsumers | producer |  | int | Specifies the maximum number of concurrent consumers when using request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads.
 | replyOnTimeoutToMaxConcurrentConsumers | producer | 1 | int | Specifies the maximum number of concurrent consumers for continue routing when timeout occurred when using request/reply over JMS.
-| maxMessagesPerTask | advanced | -1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
+| maxMessagesPerTask | advanced | 1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
 | messageConverter | advanced |  | MessageConverter | To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message.
 | mapJmsMessage | advanced | true | boolean | Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc.
 | messageIdEnabled | advanced | true | boolean | When sending specifies whether message IDs should be added. This is just an hint to the JMS broker.If the JMS provider accepts this hint these messages must have the message ID set to null; if the provider ignores the hint the message ID must be set to its normal unique value
@@ -89,12 +89,12 @@ The AMQP component supports 75 options which are listed below.
 | recoveryInterval | advanced | 5000 | long | Specifies the interval between recovery attempts i.e. when a connection is being refreshed in milliseconds. The default is 5000 ms that is 5 seconds.
 | subscriptionDurable | common | false | boolean | Deprecated: Enabled by default if you specify a durableSubscriptionName and a clientId.
 | taskExecutor | consumer (advanced) |  | TaskExecutor | Allows you to specify a custom task executor for consuming messages.
-| timeToLive | producer | -1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
+| timeToLive | producer | 1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
 | transacted | transaction | false | boolean | Specifies whether to use transacted mode
 | lazyCreateTransactionManager | transaction (advanced) | true | boolean | If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true.
 | transactionManager | transaction (advanced) |  | PlatformTransactionManager | The Spring transaction manager to use.
 | transactionName | transaction (advanced) |  | String | The name of the transaction to use.
-| transactionTimeout | transaction (advanced) | -1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
+| transactionTimeout | transaction (advanced) | 1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
 | testConnectionOnStartup | common | false | boolean | Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well.
 | asyncStartListener | advanced | false | boolean | Whether to startup the JmsConsumer message listener asynchronously when starting a route. For example if a JmsConsumer cannot get a connection to a remote JMS broker then it may block while retrying and/or failover. This will cause Camel to block while starting routes. By setting this option to true you will let routes startup while the JmsConsumer connects to the JMS broker using a dedicated thread in asynchronous mode. If this option is used then beware that if the connection could not be established then an exception is logged at WARN level and the consumer will not be able to receive messages; You can then restart the route to retry.
 | asyncStopListener | advanced | false | boolean | Whether to stop the JmsConsumer message listener asynchronously when stopping a route.
@@ -178,7 +178,7 @@ The AMQP component supports 87 endpoint options which are listed below:
 | replyToOverride | producer |  | String | Provides an explicit ReplyTo destination in the JMS message which overrides the setting of replyTo. It is useful if you want to forward the message to a remote Queue and receive the reply message from the ReplyTo destination.
 | replyToType | producer |  | ReplyToType | Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary Shared or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details and especially the notes about the implications if running in a clustered environment and the fact that Shared reply queues has lower performance than its alternatives Temporary and Exclusive.
 | requestTimeout | producer | 20000 | long | The timeout for waiting for a reply when using the InOut Exchange Pattern (in milliseconds). The default is 20 seconds. You can include the header CamelJmsRequestTimeout to override this endpoint configured timeout value and thus have per message individual timeout values. See also the requestTimeoutCheckerInterval option.
-| timeToLive | producer | -1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
+| timeToLive | producer | 1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
 | allowNullBody | producer (advanced) | true | boolean | Whether to allow sending messages with no body. If this option is false and the message body is null then an JMSException is thrown.
 | alwaysCopyMessage | producer (advanced) | false | boolean | If true Camel will always make a JMS message copy of the message when it is passed to the producer for sending. Copying the message is needed in some situations such as when a replyToDestinationSelectorName is set (incidentally Camel will set the alwaysCopyMessage option to true if a replyToDestinationSelectorName is set)
 | correlationProperty | producer (advanced) |  | String | When using InOut exchange pattern use this JMS property instead of JMSCorrelationID JMS property to correlate messages. If set messages will be correlated solely on the value of this property JMSCorrelationID property will be ignored and not set by Camel.
@@ -199,7 +199,7 @@ The AMQP component supports 87 endpoint options which are listed below:
 | includeAllJMSXProperties | advanced | false | boolean | Whether to include all JMSXxxx properties when mapping from JMS to Camel Message. Setting this to true will include properties such as JMSXAppID and JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then this option does not apply.
 | jmsKeyFormatStrategy | advanced |  | String | Pluggable strategy for encoding and decoding JMS keys so they can be compliant with the JMS specification. Camel provides two implementations out of the box: default and passthrough. The default strategy will safely marshal dots and hyphens (. and -). The passthrough strategy leaves the key as is. Can be used for JMS brokers which do not care whether JMS header keys contain illegal characters. You can provide your own implementation of the org.apache.camel.component.jms.JmsKeyFormatStrategy and refer to it using the notation.
 | mapJmsMessage | advanced | true | boolean | Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc.
-| maxMessagesPerTask | advanced | -1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
+| maxMessagesPerTask | advanced | 1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
 | messageConverter | advanced |  | MessageConverter | To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message.
 | messageCreatedStrategy | advanced |  | MessageCreatedStrategy | To use the given MessageCreatedStrategy which are invoked when Camel creates new instances of javax.jms.Message objects when Camel is sending a JMS message.
 | messageIdEnabled | advanced | true | boolean | When sending specifies whether message IDs should be added. This is just an hint to the JMS broker.If the JMS provider accepts this hint these messages must have the message ID set to null; if the provider ignores the hint the message ID must be set to its normal unique value
@@ -224,7 +224,7 @@ The AMQP component supports 87 endpoint options which are listed below:
 | lazyCreateTransactionManager | transaction (advanced) | true | boolean | If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true.
 | transactionManager | transaction (advanced) |  | PlatformTransactionManager | The Spring transaction manager to use.
 | transactionName | transaction (advanced) |  | String | The name of the transaction to use.
-| transactionTimeout | transaction (advanced) | -1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
+| transactionTimeout | transaction (advanced) | 1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
 |=======================================================================
 {% endraw %}
 // endpoint options: END
@@ -360,4 +360,4 @@ prefix, so you don't have to configure it explicitly.
 * link:configuring-camel.html[Configuring Camel]
 * link:component.html[Component]
 * link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
\ No newline at end of file
+* link:getting-started.html[Getting Started]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-couchbase/src/main/docs/couchbase-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-couchbase/src/main/docs/couchbase-component.adoc b/components/camel-couchbase/src/main/docs/couchbase-component.adoc
index 9c1c6c2..ae7aace 100644
--- a/components/camel-couchbase/src/main/docs/couchbase-component.adoc
+++ b/components/camel-couchbase/src/main/docs/couchbase-component.adoc
@@ -48,11 +48,11 @@ The Couchbase component supports 50 endpoint options which are listed below:
 | consumerProcessedStrategy | consumer | none | String | Define the consumer Processed strategy to use
 | descending | consumer | false | boolean | Define if this operation is descending or not
 | designDocumentName | consumer | beer | String | The design document name to use
-| limit | consumer | -1 | int | The output limit to use
+| limit | consumer | 1 | int | The output limit to use
 | rangeEndKey | consumer |  | String | Define a range for the end key
 | rangeStartKey | consumer |  | String | Define a range for the start key
 | sendEmptyMessageWhenIdle | consumer | false | boolean | If the polling consumer did not poll any files you can enable this option to send an empty message (no body) instead.
-| skip | consumer | -1 | int | Define the skip to use
+| skip | consumer | 1 | int | Define the skip to use
 | viewName | consumer | brewery_beers | String | The view name to use
 | exceptionHandler | consumer (advanced) |  | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN or ERROR level and ignored.
 | exchangePattern | consumer (advanced) |  | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange.
@@ -67,7 +67,7 @@ The Couchbase component supports 50 endpoint options which are listed below:
 | additionalHosts | advanced |  | String | The additional hosts
 | maxReconnectDelay | advanced | 30000 | long | Define the max delay during a reconnection
 | obsPollInterval | advanced | 400 | long | Define the observation polling interval
-| obsTimeout | advanced | -1 | long | Define the observation timeout
+| obsTimeout | advanced | 1 | long | Define the observation timeout
 | opQueueMaxBlockTime | advanced | 10000 | long | Define the max time an operation can be in queue blocked
 | opTimeOut | advanced | 2500 | long | Define the operation timeout
 | readBufferSize | advanced | 16384 | int | Define the buffer size
@@ -91,4 +91,4 @@ The Couchbase component supports 50 endpoint options which are listed below:
 | username | security |  | String | The username to use
 |=======================================================================
 {% endraw %}
-// endpoint options: END
\ No newline at end of file
+// endpoint options: END

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-elsql/src/main/docs/elsql-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-elsql/src/main/docs/elsql-component.adoc b/components/camel-elsql/src/main/docs/elsql-component.adoc
index fbc9b85..629e9a4 100644
--- a/components/camel-elsql/src/main/docs/elsql-component.adoc
+++ b/components/camel-elsql/src/main/docs/elsql-component.adoc
@@ -84,7 +84,7 @@ The ElSQL component supports 49 endpoint options which are listed below:
 | separator | common | , | char | The separator to use when parameter values is taken from message body (if the body is a String type) to be inserted at placeholders.Notice if you use named parameters then a Map type is used instead. The default value is comma
 | breakBatchOnConsumeFail | consumer | false | boolean | Sets whether to break batch if onConsume failed.
 | bridgeErrorHandler | consumer | false | boolean | Allows for bridging the consumer to the Camel routing Error Handler which mean any exceptions occurred while the consumer is trying to pickup incoming messages or the likes will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions that will be logged at WARN or ERROR level and ignored.
-| expectedUpdateCount | consumer | -1 | int | Sets an expected update count to validate when using onConsume.
+| expectedUpdateCount | consumer | 1 | int | Sets an expected update count to validate when using onConsume.
 | maxMessagesPerPoll | consumer |  | int | Sets the maximum number of messages to poll
 | onConsume | consumer |  | String | After processing each row then this query can be executed if the Exchange was processed successfully for example to mark the row as processed. The query can have parameter.
 | onConsumeBatchComplete | consumer |  | String | After processing the entire batch this query can be executed to bulk update rows etc. The query cannot have parameters.
@@ -216,4 +216,4 @@ assumes to have�`getLicense` and�`getMinimum` methods:
 
 * link:sql-component.html[SQL Component]
 * link:mybatis.html[MyBatis]
-* link:jdbc.html[JDBC]
\ No newline at end of file
+* link:jdbc.html[JDBC]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-gson/src/main/docs/json-gson-dataformat.adoc
----------------------------------------------------------------------
diff --git a/components/camel-gson/src/main/docs/json-gson-dataformat.adoc b/components/camel-gson/src/main/docs/json-gson-dataformat.adoc
index bd1608c..1e69f55 100644
--- a/components/camel-gson/src/main/docs/json-gson-dataformat.adoc
+++ b/components/camel-gson/src/main/docs/json-gson-dataformat.adoc
@@ -26,7 +26,7 @@ The JSon GSon dataformat supports 17 options which are listed below.
 | Name | Default | Java Type | Description
 | objectMapper |  | String | Lookup and use the existing ObjectMapper with the given id when using Jackson.
 | prettyPrint | false | Boolean | To enable pretty printing output nicely formatted. Is by default false.
-| library | Gson | JsonLibrary | Which json library to use.
+| library | XStream | JsonLibrary | Which json library to use.
 | unmarshalTypeName |  | String | Class name of the java type to use when unarmshalling
 | jsonView |  | Class<?> | When marshalling a POJO to JSON you might want to exclude certain fields from the JSON output. With Jackson you can use JSON views to accomplish this. This option is to refer to the class which has JsonView annotations
 | include |  | String | If you want to marshal a pojo to JSON and the pojo has some fields with null values. And you want to skip these null values you can set this option to NOT_NULL
@@ -64,4 +64,4 @@ link:download.html[the download page for the latest versions]).
   <version>x.x.x</version>
   <!-- use the same version as your Camel core version -->
 </dependency>
-----------------------------------------------------------
\ No newline at end of file
+----------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-irc/src/main/docs/irc-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-irc/src/main/docs/irc-component.adoc b/components/camel-irc/src/main/docs/irc-component.adoc
index d0e0477..13e8a15 100644
--- a/components/camel-irc/src/main/docs/irc-component.adoc
+++ b/components/camel-irc/src/main/docs/irc-component.adoc
@@ -51,7 +51,7 @@ The IRC component supports 26 endpoint options which are listed below:
 |=======================================================================
 | Name | Group | Default | Java Type | Description
 | hostname | common |  | String | *Required* Hostname for the IRC chat server
-| port | common | 6667,6668,6669 | int | Port number for the IRC chat server
+| port | common | 6667 | int | Port number for the IRC chat server
 | autoRejoin | common | true | boolean | Whether to auto re-join when being kicked
 | namesOnJoin | common | false | boolean | Sends NAMES command to channel after joining it. link onReply has to be true in order to process the result which will have the header value irc.num = '353'.
 | nickname | common |  | String | The nickname used in chat.
@@ -193,4 +193,4 @@ from("ircs:nick@myserver:1234/#mychannelname?namesOnJoin=true&onReply=true")
 * link:configuring-camel.html[Configuring Camel]
 * link:component.html[Component]
 * link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
\ No newline at end of file
+* link:getting-started.html[Getting Started]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-jackson/src/main/docs/json-jackson-dataformat.adoc
----------------------------------------------------------------------
diff --git a/components/camel-jackson/src/main/docs/json-jackson-dataformat.adoc b/components/camel-jackson/src/main/docs/json-jackson-dataformat.adoc
index 68adcf2..d30b1bd 100644
--- a/components/camel-jackson/src/main/docs/json-jackson-dataformat.adoc
+++ b/components/camel-jackson/src/main/docs/json-jackson-dataformat.adoc
@@ -27,7 +27,7 @@ The JSon Jackson dataformat supports 17 options which are listed below.
 | Name | Default | Java Type | Description
 | objectMapper |  | String | Lookup and use the existing ObjectMapper with the given id when using Jackson.
 | prettyPrint | false | Boolean | To enable pretty printing output nicely formatted. Is by default false.
-| library | Jackson | JsonLibrary | Which json library to use.
+| library | XStream | JsonLibrary | Which json library to use.
 | unmarshalTypeName |  | String | Class name of the java type to use when unarmshalling
 | jsonView |  | Class<?> | When marshalling a POJO to JSON you might want to exclude certain fields from the JSON output. With Jackson you can use JSON views to accomplish this. This option is to refer to the class which has JsonView annotations
 | include |  | String | If you want to marshal a pojo to JSON and the pojo has some fields with null values. And you want to skip these null values you can set this option to NOT_NULL
@@ -65,4 +65,4 @@ link:download.html[the download page for the latest versions]).
   <version>x.x.x</version>
   <!-- use the same version as your Camel core version -->
 </dependency>
-----------------------------------------------------------
\ No newline at end of file
+----------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-jms/src/main/docs/jms-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-jms/src/main/docs/jms-component.adoc b/components/camel-jms/src/main/docs/jms-component.adoc
index db4b2d0..0c2bc37 100644
--- a/components/camel-jms/src/main/docs/jms-component.adoc
+++ b/components/camel-jms/src/main/docs/jms-component.adoc
@@ -237,7 +237,7 @@ The JMS component supports 75 options which are listed below.
 | maxConcurrentConsumers | consumer |  | int | Specifies the maximum number of concurrent consumers when consuming from JMS (not for request/reply over JMS). See also the maxMessagesPerTask option to control dynamic scaling up/down of threads. When doing request/reply over JMS then the option replyToMaxConcurrentConsumers is used to control number of concurrent consumers on the reply message listener.
 | replyToMaxConcurrentConsumers | producer |  | int | Specifies the maximum number of concurrent consumers when using request/reply over JMS. See also the maxMessagesPerTask option to control dynamic scaling up/down of threads.
 | replyOnTimeoutToMaxConcurrentConsumers | producer | 1 | int | Specifies the maximum number of concurrent consumers for continue routing when timeout occurred when using request/reply over JMS.
-| maxMessagesPerTask | advanced | -1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
+| maxMessagesPerTask | advanced | 1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
 | messageConverter | advanced |  | MessageConverter | To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message.
 | mapJmsMessage | advanced | true | boolean | Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc. See section about how mapping works below for more details.
 | messageIdEnabled | advanced | true | boolean | When sending specifies whether message IDs should be added. This is just an hint to the JMS Broker. If the JMS provider accepts this hint these messages must have the message ID set to null; if the provider ignores the hint the message ID must be set to its normal unique value
@@ -250,12 +250,12 @@ The JMS component supports 75 options which are listed below.
 | recoveryInterval | advanced | 5000 | long | Specifies the interval between recovery attempts i.e. when a connection is being refreshed in milliseconds. The default is 5000 ms that is 5 seconds.
 | subscriptionDurable | common | false | boolean | Deprecated: Enabled by default if you specify a durableSubscriptionName and a clientId.
 | taskExecutor | consumer (advanced) |  | TaskExecutor | Allows you to specify a custom task executor for consuming messages.
-| timeToLive | producer | -1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
+| timeToLive | producer | 1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
 | transacted | transaction | false | boolean | Specifies whether to use transacted mode
 | lazyCreateTransactionManager | transaction (advanced) | true | boolean | If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true.
 | transactionManager | transaction (advanced) |  | PlatformTransactionManager | The Spring transaction manager to use.
 | transactionName | transaction (advanced) |  | String | The name of the transaction to use.
-| transactionTimeout | transaction (advanced) | -1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
+| transactionTimeout | transaction (advanced) | 1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
 | testConnectionOnStartup | common | false | boolean | Specifies whether to test the connection on startup. This ensures that when Camel starts that all the JMS consumers have a valid connection to the JMS broker. If a connection cannot be granted then Camel throws an exception on startup. This ensures that Camel is not started with failed connections. The JMS producers is tested as well.
 | asyncStartListener | advanced | false | boolean | Whether to startup the JmsConsumer message listener asynchronously when starting a route. For example if a JmsConsumer cannot get a connection to a remote JMS broker then it may block while retrying and/or failover. This will cause Camel to block while starting routes. By setting this option to true you will let routes startup while the JmsConsumer connects to the JMS broker using a dedicated thread in asynchronous mode. If this option is used then beware that if the connection could not be established then an exception is logged at WARN level and the consumer will not be able to receive messages; You can then restart the route to retry.
 | asyncStopListener | advanced | false | boolean | Whether to stop the JmsConsumer message listener asynchronously when stopping a route.
@@ -350,7 +350,7 @@ The JMS component supports 87 endpoint options which are listed below:
 | replyToOverride | producer |  | String | Provides an explicit ReplyTo destination in the JMS message which overrides the setting of replyTo. It is useful if you want to forward the message to a remote Queue and receive the reply message from the ReplyTo destination.
 | replyToType | producer |  | ReplyToType | Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary Shared or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details and especially the notes about the implications if running in a clustered environment and the fact that Shared reply queues has lower performance than its alternatives Temporary and Exclusive.
 | requestTimeout | producer | 20000 | long | The timeout for waiting for a reply when using the InOut Exchange Pattern (in milliseconds). The default is 20 seconds. You can include the header CamelJmsRequestTimeout to override this endpoint configured timeout value and thus have per message individual timeout values. See also the requestTimeoutCheckerInterval option.
-| timeToLive | producer | -1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
+| timeToLive | producer | 1 | long | When sending messages specifies the time-to-live of the message (in milliseconds).
 | allowNullBody | producer (advanced) | true | boolean | Whether to allow sending messages with no body. If this option is false and the message body is null then an JMSException is thrown.
 | alwaysCopyMessage | producer (advanced) | false | boolean | If true Camel will always make a JMS message copy of the message when it is passed to the producer for sending. Copying the message is needed in some situations such as when a replyToDestinationSelectorName is set (incidentally Camel will set the alwaysCopyMessage option to true if a replyToDestinationSelectorName is set)
 | correlationProperty | producer (advanced) |  | String | Use this JMS property to correlate messages in InOut exchange pattern (request-reply) instead of JMSCorrelationID property. This allows you to exchange messages with systems that do not correlate messages using JMSCorrelationID JMS property. If used JMSCorrelationID will not be used or set by Camel. The value of here named property will be generated if not supplied in the header of the message under the same name.
@@ -371,7 +371,7 @@ The JMS component supports 87 endpoint options which are listed below:
 | includeAllJMSXProperties | advanced | false | boolean | Whether to include all JMSXxxx properties when mapping from JMS to Camel Message. Setting this to true will include properties such as JMSXAppID and JMSXUserID etc. Note: If you are using a custom headerFilterStrategy then this option does not apply.
 | jmsKeyFormatStrategy | advanced |  | String | Pluggable strategy for encoding and decoding JMS keys so they can be compliant with the JMS specification. Camel provides two implementations out of the box: default and passthrough. The default strategy will safely marshal dots and hyphens (. and -). The passthrough strategy leaves the key as is. Can be used for JMS brokers which do not care whether JMS header keys contain illegal characters. You can provide your own implementation of the org.apache.camel.component.jms.JmsKeyFormatStrategy and refer to it using the notation.
 | mapJmsMessage | advanced | true | boolean | Specifies whether Camel should auto map the received JMS message to a suited payload type such as javax.jms.TextMessage to a String etc.
-| maxMessagesPerTask | advanced | -1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
+| maxMessagesPerTask | advanced | 1 | int | The number of messages per task. -1 is unlimited. If you use a range for concurrent consumers (eg min max) then this option can be used to set a value to eg 100 to control how fast the consumers will shrink when less work is required.
 | messageConverter | advanced |  | MessageConverter | To use a custom Spring org.springframework.jms.support.converter.MessageConverter so you can be in control how to map to/from a javax.jms.Message.
 | messageCreatedStrategy | advanced |  | MessageCreatedStrategy | To use the given MessageCreatedStrategy which are invoked when Camel creates new instances of javax.jms.Message objects when Camel is sending a JMS message.
 | messageIdEnabled | advanced | true | boolean | When sending specifies whether message IDs should be added. This is just an hint to the JMS Broker. If the JMS provider accepts this hint these messages must have the message ID set to null; if the provider ignores the hint the message ID must be set to its normal unique value
@@ -396,7 +396,7 @@ The JMS component supports 87 endpoint options which are listed below:
 | lazyCreateTransactionManager | transaction (advanced) | true | boolean | If true Camel will create a JmsTransactionManager if there is no transactionManager injected when option transacted=true.
 | transactionManager | transaction (advanced) |  | PlatformTransactionManager | The Spring transaction manager to use.
 | transactionName | transaction (advanced) |  | String | The name of the transaction to use.
-| transactionTimeout | transaction (advanced) | -1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
+| transactionTimeout | transaction (advanced) | 1 | int | The timeout value of the transaction (in seconds) if using transacted mode.
 |=======================================================================
 {% endraw %}
 // endpoint options: END
@@ -1358,4 +1358,4 @@ wmq.setDestinationResolver(new DestinationResolver() {
 * link:bean-integration.html[Bean Integration]
 * link:tutorial-jmsremoting.html[Tutorial-JmsRemoting]
 * http://activemq.apache.org/jmstemplate-gotchas.html[JMSTemplate
-gotchas]
\ No newline at end of file
+gotchas]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-johnzon/src/main/docs/json-johnzon-dataformat.adoc
----------------------------------------------------------------------
diff --git a/components/camel-johnzon/src/main/docs/json-johnzon-dataformat.adoc b/components/camel-johnzon/src/main/docs/json-johnzon-dataformat.adoc
index ef67134..dc73485 100644
--- a/components/camel-johnzon/src/main/docs/json-johnzon-dataformat.adoc
+++ b/components/camel-johnzon/src/main/docs/json-johnzon-dataformat.adoc
@@ -27,7 +27,7 @@ The JSon Johnzon dataformat supports 17 options which are listed below.
 | Name | Default | Java Type | Description
 | objectMapper |  | String | Lookup and use the existing ObjectMapper with the given id when using Jackson.
 | prettyPrint | false | Boolean | To enable pretty printing output nicely formatted. Is by default false.
-| library | Johnzon | JsonLibrary | Which json library to use.
+| library | XStream | JsonLibrary | Which json library to use.
 | unmarshalTypeName |  | String | Class name of the java type to use when unarmshalling
 | jsonView |  | Class<?> | When marshalling a POJO to JSON you might want to exclude certain fields from the JSON output. With Jackson you can use JSON views to accomplish this. This option is to refer to the class which has JsonView annotations
 | include |  | String | If you want to marshal a pojo to JSON and the pojo has some fields with null values. And you want to skip these null values you can set this option to NOT_NULL
@@ -65,4 +65,4 @@ link:download.html[the download page for the latest versions]).
   <version>x.x.x</version>
   <!-- use the same version as your Camel core version -->
 </dependency>
-----------------------------------------------------------
\ No newline at end of file
+----------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-jpa/src/main/docs/jpa-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-jpa/src/main/docs/jpa-component.adoc b/components/camel-jpa/src/main/docs/jpa-component.adoc
index 49b7e66..d4245a4 100644
--- a/components/camel-jpa/src/main/docs/jpa-component.adoc
+++ b/components/camel-jpa/src/main/docs/jpa-component.adoc
@@ -123,7 +123,7 @@ The JPA component supports 42 endpoint options which are listed below:
 | consumeLockEntity | consumer | true | boolean | Specifies whether or not to set an exclusive lock on each entity bean while processing the results from polling.
 | deleteHandler | consumer |  | Object> | To use a custom DeleteHandler to delete the row after the consumer is done processing the exchange
 | lockModeType | consumer | PESSIMISTIC_WRITE | LockModeType | To configure the lock mode on the consumer.
-| maximumResults | consumer | -1 | int | Set the maximum number of results to retrieve on the Query.
+| maximumResults | consumer | 1 | int | Set the maximum number of results to retrieve on the Query.
 | maxMessagesPerPoll | consumer |  | int | An integer value to define the maximum number of messages to gather per poll. By default no maximum is set. Can be used to avoid polling many thousands of messages when starting up the server. Set a value of 0 or negative to disable.
 | namedQuery | consumer |  | String | To use a named query when consuming data.
 | nativeQuery | consumer |  | String | To use a custom native query when consuming data. You may want to use the option consumer.resultClass also when using native queries.
@@ -365,4 +365,4 @@ image:https://cwiki.apache.org/confluence/s/en_GB/5982/f2b47fb3d636c8bc9fd0b11c0
 * link:endpoint.html[Endpoint]
 * link:getting-started.html[Getting Started]
 
-* link:tracer-example.html[Tracer Example]
\ No newline at end of file
+* link:tracer-example.html[Tracer Example]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-kafka/src/main/docs/kafka-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-kafka/src/main/docs/kafka-component.adoc b/components/camel-kafka/src/main/docs/kafka-component.adoc
index 211d592..8c41c3f 100644
--- a/components/camel-kafka/src/main/docs/kafka-component.adoc
+++ b/components/camel-kafka/src/main/docs/kafka-component.adoc
@@ -117,8 +117,8 @@ The Kafka component supports 80 endpoint options which are listed below:
 | kerberosBeforeReloginMinTime | security | 60000 | Integer | Login thread sleep time between refresh attempts.
 | kerberosInitCmd | security | /usr/bin/kinit | String | Kerberos kinit command path. Default is /usr/bin/kinit
 | kerberosPrincipalToLocalRules | security | DEFAULT | String | A list of rules for mapping from principal names to short names (typically operating system usernames). The rules are evaluated in order and the first rule that matches a principal name is used to map it to a short name. Any later rules in the list are ignored. By default principal names of the form username/hostnameREALM are mapped to username. For more details on the format please see security authorization and acls. Multiple values can be separated by comma
-| kerberosRenewJitter | security | 0.05 | Double | Percentage of random jitter added to the renewal time.
-| kerberosRenewWindowFactor | security | 0.8 | Double | Login thread will sleep until the specified window factor of time from last refresh to ticket's expiry has been reached at which time it will try to renew the ticket.
+| kerberosRenewJitter | security | 0 | Double | Percentage of random jitter added to the renewal time.
+| kerberosRenewWindowFactor | security | 0 | Double | Login thread will sleep until the specified window factor of time from last refresh to ticket's expiry has been reached at which time it will try to renew the ticket.
 | saslKerberosServiceName | security |  | String | The Kerberos principal name that Kafka runs as. This can be defined either in Kafka's JAAS config or in Kafka's config.
 | saslMechanism | security | GSSAPI | String | The Simple Authentication and Security Layer (SASL) Mechanism used. For the valid values see http://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml
 | securityProtocol | security | PLAINTEXT | String | Protocol used to communicate with brokers. Currently only PLAINTEXT and SSL are supported.

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mail/src/main/docs/mail-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mail/src/main/docs/mail-component.adoc b/components/camel-mail/src/main/docs/mail-component.adoc
index 3f0ba33..6874ede 100644
--- a/components/camel-mail/src/main/docs/mail-component.adoc
+++ b/components/camel-mail/src/main/docs/mail-component.adoc
@@ -118,7 +118,7 @@ The Mail component supports 63 endpoint options which are listed below:
 | unseen | consumer | true | boolean | Whether to limit by unseen mails only.
 | exceptionHandler | consumer (advanced) |  | ExceptionHandler | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this options is not in use. By default the consumer will deal with exceptions that will be logged at WARN or ERROR level and ignored.
 | exchangePattern | consumer (advanced) |  | ExchangePattern | Sets the exchange pattern when the consumer creates an exchange.
-| fetchSize | consumer (advanced) | -1 | int | Sets the maximum number of messages to consume during a poll. This can be used to avoid overloading a mail server if a mailbox folder contains a lot of messages. Default value of -1 means no fetch size and all messages will be consumed. Setting the value to 0 is a special corner case where Camel will not consume any messages at all.
+| fetchSize | consumer (advanced) | 1 | int | Sets the maximum number of messages to consume during a poll. This can be used to avoid overloading a mail server if a mailbox folder contains a lot of messages. Default value of -1 means no fetch size and all messages will be consumed. Setting the value to 0 is a special corner case where Camel will not consume any messages at all.
 | folderName | consumer (advanced) | INBOX | String | The folder to poll.
 | mailUidGenerator | consumer (advanced) |  | MailUidGenerator | A pluggable MailUidGenerator that allows to use custom logic to generate UUID of the mail message.
 | mapMailMessage | consumer (advanced) | true | boolean | Specifies whether Camel should map the received mail message to Camel body/headers. If set to true the body of the mail message is mapped to the body of the Camel IN message and the mail headers are mapped to IN headers. If this option is set to false then the IN message contains a raw javax.mail.Message. You can retrieve this raw message by calling exchange.getIn().getBody(javax.mail.Message.class).
@@ -629,4 +629,4 @@ SearchTerm term = builder.build();
 * link:configuring-camel.html[Configuring Camel]
 * link:component.html[Component]
 * link:endpoint.html[Endpoint]
-* link:getting-started.html[Getting Started]
\ No newline at end of file
+* link:getting-started.html[Getting Started]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mina/src/main/docs/mina-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mina/src/main/docs/mina-component.adoc b/components/camel-mina/src/main/docs/mina-component.adoc
index 26febaa..cfa1bf3 100644
--- a/components/camel-mina/src/main/docs/mina-component.adoc
+++ b/components/camel-mina/src/main/docs/mina-component.adoc
@@ -110,7 +110,7 @@ The Mina component supports 24 endpoint options which are listed below:
 | allowDefaultCodec | codec | true | boolean | The mina component installs a default codec if both codec is null and textline is false. Setting allowDefaultCodec to false prevents the mina component from installing a default codec as the first element in the filter chain. This is useful in scenarios where another filter must be the first in the filter chain like the SSL filter.
 | codec | codec |  | ProtocolCodecFactory | To use a custom minda codec implementation.
 | decoderMaxLineLength | codec | 1024 | int | To set the textline protocol decoder max line length. By default the default value of Mina itself is used which are 1024.
-| encoderMaxLineLength | codec | -1 | int | To set the textline protocol encoder max line length. By default the default value of Mina itself is used which are Integer.MAX_VALUE.
+| encoderMaxLineLength | codec | 1 | int | To set the textline protocol encoder max line length. By default the default value of Mina itself is used which are Integer.MAX_VALUE.
 | encoding | codec |  | String | You can configure the encoding (a charset name) to use for the TCP textline codec and the UDP protocol. If not provided Camel will use the JVM default Charset
 | filters | codec |  | List | You can set a list of Mina IoFilters to use.
 | textline | codec | false | boolean | Only used for TCP. If no codec is specified you can use this flag to indicate a text line based codec; if not specified or the value is false then Object Serialization is assumed over TCP.
@@ -324,4 +324,4 @@ Then, you can configure your endpoint using Spring DSL:
 * link:getting-started.html[Getting Started]
 
 * link:mina2.html[MINA2]
-* link:netty.html[Netty]
\ No newline at end of file
+* link:netty.html[Netty]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mina2/src/main/docs/mina2-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mina2/src/main/docs/mina2-component.adoc b/components/camel-mina2/src/main/docs/mina2-component.adoc
index 71c81a2..1d84279 100644
--- a/components/camel-mina2/src/main/docs/mina2-component.adoc
+++ b/components/camel-mina2/src/main/docs/mina2-component.adoc
@@ -112,7 +112,7 @@ The Mina2 component supports 29 endpoint options which are listed below:
 | allowDefaultCodec | codec | true | boolean | The mina component installs a default codec if both codec is null and textline is false. Setting allowDefaultCodec to false prevents the mina component from installing a default codec as the first element in the filter chain. This is useful in scenarios where another filter must be the first in the filter chain like the SSL filter.
 | codec | codec |  | ProtocolCodecFactory | To use a custom minda codec implementation.
 | decoderMaxLineLength | codec | 1024 | int | To set the textline protocol decoder max line length. By default the default value of Mina itself is used which are 1024.
-| encoderMaxLineLength | codec | -1 | int | To set the textline protocol encoder max line length. By default the default value of Mina itself is used which are Integer.MAX_VALUE.
+| encoderMaxLineLength | codec | 1 | int | To set the textline protocol encoder max line length. By default the default value of Mina itself is used which are Integer.MAX_VALUE.
 | encoding | codec |  | String | You can configure the encoding (a charset name) to use for the TCP textline codec and the UDP protocol. If not provided Camel will use the JVM default Charset
 | filters | codec |  | List | You can set a list of Mina IoFilters to use.
 | textline | codec | false | boolean | Only used for TCP. If no codec is specified you can use this flag to indicate a text line based codec; if not specified or the value is false then Object Serialization is assumed over TCP.
@@ -256,4 +256,4 @@ is, after `codec` and `logger`.
 * link:getting-started.html[Getting Started]
 
 * link:mina.html[MINA]
-* link:netty.html[Netty]
\ No newline at end of file
+* link:netty.html[Netty]

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mllp/src/main/docs/mllp-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mllp/src/main/docs/mllp-component.adoc b/components/camel-mllp/src/main/docs/mllp-component.adoc
index dcce353..75f128e 100644
--- a/components/camel-mllp/src/main/docs/mllp-component.adoc
+++ b/components/camel-mllp/src/main/docs/mllp-component.adoc
@@ -78,7 +78,7 @@ The MLLP component supports 24 endpoint options which are listed below:
 | bindRetryInterval | timeout | 5000 | int | TCP Server Only - The number of milliseconds to wait between bind attempts
 | bindTimeout | timeout | 30000 | int | TCP Server Only - The number of milliseconds to retry binding to a server port
 | connectTimeout | timeout | 30000 | int | Timeout (in milliseconds) for establishing for a TCP connection TCP Client only
-| maxReceiveTimeouts | timeout | -1 | int | The maximum number of timeouts (specified by receiveTimeout) allowed before the TCP Connection will be reset.
+| maxReceiveTimeouts | timeout | 1 | int | The maximum number of timeouts (specified by receiveTimeout) allowed before the TCP Connection will be reset.
 | readTimeout | timeout | 500 | int | The SO_TIMEOUT value (in milliseconds) used after the start of an MLLP frame has been received
 | receiveTimeout | timeout | 10000 | int | The SO_TIMEOUT value (in milliseconds) used when waiting for the start of an MLLP frame
 |=======================================================================
@@ -167,4 +167,4 @@ The MLLP Producer adds these headers on the Camel message:
 |===================================
 
 All headers�are�String�types. If a header value is missing, its value
-is�null.
\ No newline at end of file
+is�null.

http://git-wip-us.apache.org/repos/asf/camel/blob/55dcbe80/components/camel-mongodb/src/main/docs/mongodb-component.adoc
----------------------------------------------------------------------
diff --git a/components/camel-mongodb/src/main/docs/mongodb-component.adoc b/components/camel-mongodb/src/main/docs/mongodb-component.adoc
index 4e37155..628d4df 100644
--- a/components/camel-mongodb/src/main/docs/mongodb-component.adoc
+++ b/components/camel-mongodb/src/main/docs/mongodb-component.adoc
@@ -84,7 +84,7 @@ The MongoDB component supports 24 endpoint options which are listed below:
 | writeResultAsHeader | advanced | false | boolean | In write operations it determines whether instead of returning WriteResult as the body of the OUT message we transfer the IN message to the OUT and attach the WriteResult as a header.
 | persistentId | tail |  | String | One tail tracking collection can host many trackers for several tailable consumers. To keep them separate each tracker should have its own unique persistentId.
 | persistentTailTracking | tail | false | boolean | Enable persistent tail tracking which is a mechanism to keep track of the last consumed message across system restarts. The next time the system is up the endpoint will recover the cursor from the point where it last stopped slurping records.
-| persistRecords | tail | -1 | int | Sets the number of tailed records after which the tail tracking data is persisted to MongoDB.
+| persistRecords | tail | 1 | int | Sets the number of tailed records after which the tail tracking data is persisted to MongoDB.
 | tailTrackCollection | tail |  | String | Collection where tail tracking information will be persisted. If not specified link MongoDbTailTrackingConfigDEFAULT_COLLECTION will be used by default.
 | tailTrackDb | tail |  | String | Indicates what database the tail tracking mechanism will persist to. If not specified the current database will be picked by default. Dynamicity will not be taken into account even if enabled i.e. the tail tracking database will not vary past endpoint initialisation.
 | tailTrackField | tail |  | String | Field where the last tracked value will be placed. If not specified link MongoDbTailTrackingConfigDEFAULT_FIELD will be used by default.
@@ -903,4 +903,4 @@ anything manually.
 current version]
 *
 http://svn.apache.org/viewvc/camel/trunk/components/camel-mongodb/src/test/[Unit
-tests] for more examples of usage
\ No newline at end of file
+tests] for more examples of usage