Repository: camel Updated Branches: refs/heads/master 0434eb809 -> 47ff272f3
http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-netty4/src/main/java/org/apache/camel/component/netty4/springboot/NettyComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-netty4/src/main/java/org/apache/camel/component/netty4/springboot/NettyComponentConfiguration.java b/components/camel-netty4/src/main/java/org/apache/camel/component/netty4/springboot/NettyComponentConfiguration.java index 0c1b3fc..6325701 100644 --- a/components/camel-netty4/src/main/java/org/apache/camel/component/netty4/springboot/NettyComponentConfiguration.java +++ b/components/camel-netty4/src/main/java/org/apache/camel/component/netty4/springboot/NettyComponentConfiguration.java @@ -70,7 +70,7 @@ public class NettyComponentConfiguration { /** * Setting to choose Multicast over UDP */ - private Boolean broadcast = false; + private Boolean broadcast; /** * The TCP/UDP buffer sizes to be used during outbound communication. Size * is bytes. @@ -101,15 +101,15 @@ public class NettyComponentConfiguration { /** * Setting to ensure socket is not closed due to inactivity */ - private Boolean keepAlive = false; + private Boolean keepAlive; /** * Setting to improve TCP protocol performance */ - private Boolean tcpNoDelay = false; + private Boolean tcpNoDelay; /** * Setting to facilitate socket multiplexing */ - private Boolean reuseAddress = false; + private Boolean reuseAddress; /** * Time to wait for a socket connection to be available. Value is in millis. */ @@ -125,14 +125,14 @@ public class NettyComponentConfiguration { /** * Setting to specify whether SSL encryption is applied to this endpoint */ - private Boolean ssl = false; + private Boolean ssl; /** * When enabled and in SSL mode then the Netty consumer will enrich the * Camel Message with headers having information about the client * certificate such as subject name issuer name serial number and the valid * date range. */ - private Boolean sslClientCertHeaders = false; + private Boolean sslClientCertHeaders; /** * Reference to a class that could be used to return an SSL Handler */ @@ -144,7 +144,7 @@ public class NettyComponentConfiguration { /** * Configures whether the server needs client authentication when using SSL. */ - private Boolean needClientAuth = false; + private Boolean needClientAuth; /** * Client side certificate keystore to be used for encryption. Is loaded by * default from classpath but you can prefix with classpath: file: or http: @@ -190,7 +190,7 @@ public class NettyComponentConfiguration { /** * Setting to set endpoint as one-way or request-response */ - private Boolean sync = false; + private Boolean sync; /** * Allows to configure additional netty options using option. as prefix. For * example option.child.keepAlive=false to set the netty option @@ -203,7 +203,7 @@ public class NettyComponentConfiguration { * indicate a text line based codec; if not specified or the value is false * then Object Serialization is assumed over TCP. */ - private Boolean textline = false; + private Boolean textline; /** * Whether to use native transport instead of NIO. Native transport takes * advantage of the host operating system and is only supported on some @@ -211,7 +211,7 @@ public class NettyComponentConfiguration { * you are using. See more details at: * http://netty.io/wiki/native-transports.html */ - private Boolean nativeTransport = false; + private Boolean nativeTransport; /** * The max line length to use for the textline codec. */ @@ -230,7 +230,7 @@ public class NettyComponentConfiguration { * Whether or not to auto append missing end delimiter when sending using * the textline codec. */ - private Boolean autoAppendDelimiter = false; + private Boolean autoAppendDelimiter; /** * To use a explicit EventLoopGroup as the boss thread pool. For example to * share a thread pool with multiple consumers. By default each consumer has @@ -271,7 +271,7 @@ public class NettyComponentConfiguration { * Used only in clientMode in consumer the consumer will attempt to * reconnect on disconnection if this is enabled */ - private Boolean reconnect = false; + private Boolean reconnect; /** * A custom ChannelHandler class that can be used to perform special * marshalling of outbound payloads. @@ -291,12 +291,12 @@ public class NettyComponentConfiguration { * Whether or not to disconnect(close) from Netty Channel right after use. * Can be used for both consumer and producer. */ - private Boolean disconnect = false; + private Boolean disconnect; /** * Channels can be lazily created to avoid exceptions if the remote server * is not up and running when the Camel producer is started. */ - private Boolean lazyChannelCreation = false; + private Boolean lazyChannelCreation; /** * Only used for TCP. You can transfer the exchange over the wire instead of * just the body. The following fields are transferred: In body Out body @@ -304,12 +304,12 @@ public class NettyComponentConfiguration { * exchange exception. This requires that the objects are serializable. * Camel will exclude any non-serializable objects and log it at WARN level. */ - private Boolean transferExchange = false; + private Boolean transferExchange; /** * If sync is enabled then this option dictates NettyConsumer if it should * disconnect where there is no reply to send back. */ - private Boolean disconnectOnNoReply = false; + private Boolean disconnectOnNoReply; /** * If sync is enabled this option dictates NettyConsumer which logging level * to use when logging a there is no reply to send back. @@ -334,7 +334,7 @@ public class NettyComponentConfiguration { * the netty component from installing a default codec as the first element * in the filter chain. */ - private Boolean allowDefaultCodec = false; + private Boolean allowDefaultCodec; /** * To use a custom ClientInitializerFactory */ @@ -343,7 +343,7 @@ public class NettyComponentConfiguration { * Whether to use ordered thread pool to ensure events are processed orderly * on the same channel. */ - private Boolean usingExecutorService = false; + private Boolean usingExecutorService; /** * 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 @@ -370,28 +370,28 @@ public class NettyComponentConfiguration { * as the pooling is needed for handling concurrency and reliable * request/reply. */ - private Boolean producerPoolEnabled = false; + private Boolean producerPoolEnabled; /** * This option supports connection less udp sending which is a real fire and * forget. A connected udp send receive the PortUnreachableException if no * one is listen on the receiving port. */ - private Boolean udpConnectionlessSending = false; + private Boolean udpConnectionlessSending; /** * If the clientMode is true netty consumer will connect the address as a * TCP client. */ - private Boolean clientMode = false; + private Boolean clientMode; /** * If the useByteBuf is true netty producer will turn the message body into * ByteBuf before sending it out. */ - private Boolean useByteBuf = false; + private Boolean useByteBuf; /** * For UDP only. If enabled the using byte array codec instead of Java * serialization protocol. */ - private Boolean udpByteArrayCodec = false; + private Boolean udpByteArrayCodec; /** * This option allows producers to reuse the same Netty Channel for the * lifecycle of processing the Exchange. This is useable if you need to call @@ -402,7 +402,7 @@ public class NettyComponentConfiguration { * exchange property with the key link NettyConstantsNETTY_CHANNEL which * allows you to obtain the channel during routing and use it as well. */ - private Boolean reuseChannel = false; + private Boolean reuseChannel; public Integer getMaximumPoolSize() { return maximumPoolSize; http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/springboot/QuartzComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/springboot/QuartzComponentConfiguration.java b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/springboot/QuartzComponentConfiguration.java index bc94ab5..8a200be 100644 --- a/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/springboot/QuartzComponentConfiguration.java +++ b/components/camel-quartz/src/main/java/org/apache/camel/component/quartz/springboot/QuartzComponentConfiguration.java @@ -54,12 +54,12 @@ public class QuartzComponentConfiguration { * Whether or not the scheduler should be auto started. This options is * default true */ - private Boolean autoStartScheduler = false; + private Boolean autoStartScheduler; /** * Whether to enable Quartz JMX which allows to manage the Quartz scheduler * from JMX. This options is default true */ - private Boolean enableJmx = false; + private Boolean enableJmx; public SchedulerFactory getFactory() { return factory; http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-quartz2/src/main/java/org/apache/camel/component/quartz2/springboot/QuartzComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-quartz2/src/main/java/org/apache/camel/component/quartz2/springboot/QuartzComponentConfiguration.java b/components/camel-quartz2/src/main/java/org/apache/camel/component/quartz2/springboot/QuartzComponentConfiguration.java index 1b0eea6..a3f9824 100644 --- a/components/camel-quartz2/src/main/java/org/apache/camel/component/quartz2/springboot/QuartzComponentConfiguration.java +++ b/components/camel-quartz2/src/main/java/org/apache/camel/component/quartz2/springboot/QuartzComponentConfiguration.java @@ -33,7 +33,7 @@ public class QuartzComponentConfiguration { * Whether or not the scheduler should be auto started. This options is * default true */ - private Boolean autoStartScheduler = false; + private Boolean autoStartScheduler; /** * Seconds to wait before starting the quartz scheduler. */ @@ -42,12 +42,12 @@ public class QuartzComponentConfiguration { * Whether to prefix the quartz job with the endpoint id. This option is * default false. */ - private Boolean prefixJobNameWithEndpointId = false; + private Boolean prefixJobNameWithEndpointId; /** * Whether to enable Quartz JMX which allows to manage the Quartz scheduler * from JMX. This options is default true */ - private Boolean enableJmx = false; + private Boolean enableJmx; /** * Properties to configure the Quartz scheduler. */ @@ -63,7 +63,7 @@ public class QuartzComponentConfiguration { * to false to reuse Quartz scheduler instances between multiple * CamelContext's. */ - private Boolean prefixInstanceName = false; + private Boolean prefixInstanceName; /** * To use the custom SchedulerFactory which is used to create the Scheduler. */ http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/springboot/QuickfixjComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/springboot/QuickfixjComponentConfiguration.java b/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/springboot/QuickfixjComponentConfiguration.java index 6440310..c4b186d 100644 --- a/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/springboot/QuickfixjComponentConfiguration.java +++ b/components/camel-quickfix/src/main/java/org/apache/camel/component/quickfixj/springboot/QuickfixjComponentConfiguration.java @@ -53,7 +53,7 @@ public class QuickfixjComponentConfiguration { * If set to true the engines will be created and started when needed (when * first message is send) */ - private Boolean lazyCreateEngines = false; + private Boolean lazyCreateEngines; public MessageFactory getMessageFactory() { return messageFactory; http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/springboot/RestletComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/springboot/RestletComponentConfiguration.java b/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/springboot/RestletComponentConfiguration.java index 8824e48..612d6af 100644 --- a/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/springboot/RestletComponentConfiguration.java +++ b/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/springboot/RestletComponentConfiguration.java @@ -110,7 +110,7 @@ public class RestletComponentConfiguration { * request input stream into a stream cache and put it into message body if * this option is false to support reading the stream multiple times. */ - private Boolean disableStreamCache = false; + private Boolean disableStreamCache; /** * To configure the port number for the restlet consumer routes. This allows * to configure this once to reuse the same port for these consumers. http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/springboot/SalesforceComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/springboot/SalesforceComponentConfiguration.java b/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/springboot/SalesforceComponentConfiguration.java index 18894b7..a971286 100644 --- a/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/springboot/SalesforceComponentConfiguration.java +++ b/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/springboot/SalesforceComponentConfiguration.java @@ -76,11 +76,11 @@ public class SalesforceComponentConfiguration { /** * Enable for Socks4 proxy false by default */ - private Boolean isHttpProxySocks4 = false; + private Boolean isHttpProxySocks4; /** * Enable for TLS connections true by default */ - private Boolean isHttpProxySecure = false; + private Boolean isHttpProxySecure; /** * HTTP proxy included addresses */ @@ -100,7 +100,7 @@ public class SalesforceComponentConfiguration { /** * Use HTTP proxy Digest authentication false by default */ - private Boolean httpProxyUseDigestAuth = false; + private Boolean httpProxyUseDigestAuth; /** * Package names to scan for DTO classes (multiple packages can be separated * by comma). @@ -130,7 +130,7 @@ public class SalesforceComponentConfiguration { * Flag to enable/disable lazy OAuth default is false. When enabled OAuth * token retrieval or generation is not done until the first API call */ - private Boolean lazyLogin = false; + private Boolean lazyLogin; /** * Payload format to use for Salesforce API calls either JSON or XML * defaults to JSON @@ -210,7 +210,7 @@ public class SalesforceComponentConfiguration { * Whether to update an existing Push Topic when using the Streaming API * defaults to false */ - private Boolean updateTopic = false; + private Boolean updateTopic; /** * Notify for fields options are ALL REFERENCED SELECT WHERE */ http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-servlet/src/main/java/org/apache/camel/component/servlet/springboot/ServletComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-servlet/src/main/java/org/apache/camel/component/servlet/springboot/ServletComponentConfiguration.java b/components/camel-servlet/src/main/java/org/apache/camel/component/servlet/springboot/ServletComponentConfiguration.java index be38061..24fcebe 100644 --- a/components/camel-servlet/src/main/java/org/apache/camel/component/servlet/springboot/ServletComponentConfiguration.java +++ b/components/camel-servlet/src/main/java/org/apache/camel/component/servlet/springboot/ServletComponentConfiguration.java @@ -44,7 +44,7 @@ public class ServletComponentConfiguration { * Exchange. This is turn off by default as this may require servet specific * configuration to enable this when using Servlet's. */ - private Boolean attachmentMultipartBinding = false; + private Boolean attachmentMultipartBinding; /** * To use a custom HttpBinding to control the mapping between Camel message * and HttpClient. @@ -61,7 +61,7 @@ public class ServletComponentConfiguration { * the incoming data from the request to Java and that can be a potential * security risk. */ - private Boolean allowJavaSerializedObject = false; + private Boolean allowJavaSerializedObject; /** * To use a custom HeaderFilterStrategy to filter header to and from Camel * message. http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-smpp/src/main/java/org/apache/camel/component/smpp/springboot/SmppComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-smpp/src/main/java/org/apache/camel/component/smpp/springboot/SmppComponentConfiguration.java b/components/camel-smpp/src/main/java/org/apache/camel/component/smpp/springboot/SmppComponentConfiguration.java index e74b26a..f7d9cc8 100644 --- a/components/camel-smpp/src/main/java/org/apache/camel/component/smpp/springboot/SmppComponentConfiguration.java +++ b/components/camel-smpp/src/main/java/org/apache/camel/component/smpp/springboot/SmppComponentConfiguration.java @@ -180,7 +180,7 @@ public class SmppComponentConfiguration { /** * Whether using SSL with the smpps protocol */ - private Boolean usingSSL = false; + private Boolean usingSSL; /** * Defines the initial delay in milliseconds after the consumer/producer * tries to reconnect to the SMSC after the connection was lost. @@ -198,7 +198,7 @@ public class SmppComponentConfiguration { * exchange. If they are present Camel will use these data to connect to the * SMSC. */ - private Boolean lazySessionCreation = false; + private Boolean lazySessionCreation; /** * If you need to tunnel SMPP through a HTTP proxy set this attribute to the * hostname or ip address of your HTTP proxy. http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-websocket/src/main/java/org/apache/camel/component/websocket/springboot/WebsocketComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-websocket/src/main/java/org/apache/camel/component/websocket/springboot/WebsocketComponentConfiguration.java b/components/camel-websocket/src/main/java/org/apache/camel/component/websocket/springboot/WebsocketComponentConfiguration.java index 61c5034..4797773 100644 --- a/components/camel-websocket/src/main/java/org/apache/camel/component/websocket/springboot/WebsocketComponentConfiguration.java +++ b/components/camel-websocket/src/main/java/org/apache/camel/component/websocket/springboot/WebsocketComponentConfiguration.java @@ -64,7 +64,7 @@ public class WebsocketComponentConfiguration { * If this option is true Jetty JMX support will be enabled for this * endpoint. See Jetty JMX support for more details. */ - private Boolean enableJmx = false; + private Boolean enableJmx; /** * To set a value for minimum number of threads in server thread pool. * MaxThreads/minThreads or threadPool fields are required due to switch to http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/springboot/ZooKeeperComponentConfiguration.java ---------------------------------------------------------------------- diff --git a/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/springboot/ZooKeeperComponentConfiguration.java b/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/springboot/ZooKeeperComponentConfiguration.java index e28b42f..41906c0 100644 --- a/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/springboot/ZooKeeperComponentConfiguration.java +++ b/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/springboot/ZooKeeperComponentConfiguration.java @@ -44,7 +44,7 @@ public class ZooKeeperComponentConfiguration { /** * Whether the children of the node should be listed */ - private Boolean listChildren = false; + private Boolean listChildren; /** * The node in the ZooKeeper server (aka znode) */ @@ -52,7 +52,7 @@ public class ZooKeeperComponentConfiguration { /** * Should changes to the znode be 'watched' and repeatedly processed. */ - private Boolean repeat = false; + private Boolean repeat; /** * The time interval to backoff for after an error before retrying. */ @@ -60,7 +60,7 @@ public class ZooKeeperComponentConfiguration { /** * Should the endpoint create the node if it does not currently exist. */ - private Boolean create = false; + private Boolean create; /** * The create mode that should be used for the newly created node */ @@ -69,7 +69,7 @@ public class ZooKeeperComponentConfiguration { * Upon the delete of a znode should an empty message be send to the * consumer */ - private Boolean sendEmptyMessageOnDelete = false; + private Boolean sendEmptyMessageOnDelete; public ZooKeeperConfiguration getConfiguration() { return configuration; http://git-wip-us.apache.org/repos/asf/camel/blob/47ff272f/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 ad81072..8f38906 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 @@ -264,10 +264,7 @@ public class EndpointAnnotationProcessor extends AbstractAnnotationProcessor { doc = sanitizeDescription(doc, false); Boolean required = entry.getRequired() != null ? Boolean.valueOf(entry.getRequired()) : null; String defaultValue = entry.getDefaultValue(); - if (Strings.isNullOrEmpty(defaultValue) && "boolean".equals(entry.getType())) { - // fallback as false for boolean types - defaultValue = "false"; - } + // component option do not have default value for boolean (as we dont really known if its true or false) // component options do not have prefix String optionalPrefix = "";