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 2016/02/29 08:43:49 UTC
[2/4] camel git commit: CAMEL-9648: Polished javadoc
CAMEL-9648: Polished javadoc
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/ca28bf54
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/ca28bf54
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/ca28bf54
Branch: refs/heads/master
Commit: ca28bf54e73d827774be085e3e52bcf14005c9b3
Parents: ea647c7
Author: Preben Asmussen <pr...@gmail.com>
Authored: Sun Feb 28 15:14:05 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Mon Feb 29 08:24:46 2016 +0100
----------------------------------------------------------------------
.../camel-ironmq/src/main/docs/ironmq.adoc | 20 +++++++-------
.../component/ironmq/IronMQConfiguration.java | 28 ++++++++++++--------
2 files changed, 28 insertions(+), 20 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/ca28bf54/components/camel-ironmq/src/main/docs/ironmq.adoc
----------------------------------------------------------------------
diff --git a/components/camel-ironmq/src/main/docs/ironmq.adoc b/components/camel-ironmq/src/main/docs/ironmq.adoc
index b32489c..25893fe 100644
--- a/components/camel-ironmq/src/main/docs/ironmq.adoc
+++ b/components/camel-ironmq/src/main/docs/ironmq.adoc
@@ -40,6 +40,7 @@ Options
^^^^^^^
+
// endpoint options: START
The ironmq component supports 31 endpoint options which are listed below:
@@ -49,19 +50,19 @@ The ironmq component supports 31 endpoint options which are listed below:
| queueName | common | | String | *Required* The name of the IronMQ queue
| client | common | | Client | Reference to a io.iron.ironmq.Client in the Registry.
| ironMQCloud | common | https://mq-aws-us-east-1.iron.io | String | IronMq Cloud url. See http://dev.iron.io/mq/reference/clouds/ for valid options
-| preserveHeaders | common | false | boolean | Should camel message headers be preserved when publishing messages
-| projectId | common | | String | IronMq projectId
-| token | common | | String | IronMq token
-| batchDelete | consumer | false | boolean | Shold messages be deleted in one batch or one at the time
+| preserveHeaders | common | false | boolean | Should message headers be preserved when publishing messages. This will add the Camel headers to the Iron MQ message as a json payload with a header list and a message body. Useful when Camel is both consumer and producer.
+| projectId | common | | String | IronMQ projectId
+| token | common | | String | IronMQ token
+| batchDelete | consumer | false | boolean | Should messages be deleted in one batch. This will limit the number of api requests since messages are deleted in one request instead of one pr. exchange. If enabled care should be taken that the consumer is idempotent when processing exchanges.
| 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/ERROR level and ignored.
-| concurrentConsumers | consumer | 1 | Integer | The number of concurrent consumers.
-| maxMessagesPerPoll | consumer | 1 | int | Number of messages to poll pr. call
+| concurrentConsumers | consumer | 1 | int | The number of concurrent consumers.
+| maxMessagesPerPoll | consumer | 1 | int | Number of messages to poll pr. call. Maximum is 100.
| 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.
-| timeout | consumer | 60 | int | sets the timeout
-| wait | consumer | | int | Sets the wait
+| timeout | consumer | 60 | int | After timeout (in seconds) item will be placed back onto the queue.
+| wait | consumer | | int | Time in seconds to wait for a message to become available. This enables long polling. Default is 0 (does not wait) maximum is 30.
| 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/ERROR level and ignored.
| pollStrategy | consumer (advanced) | | PollingConsumerPollStrategy | A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange have been created and being routed in Camel.
-| visibilityDelay | producer | | int | Set's the visibility delay in seconds.
+| visibilityDelay | producer | | int | The item will not be available on the queue until this many seconds have passed. Default is 0 seconds.
| exchangePattern | advanced | InOnly | ExchangePattern | Sets the default exchange pattern when creating an exchange
| synchronous | advanced | false | boolean | Sets whether synchronous processing should be strictly used or Camel is allowed to use asynchronous processing (if supported).
| backoffErrorThreshold | scheduler | | int | The number of subsequent error polls (failed due some error) that should happen before the backoffMultipler should kick-in.
@@ -80,6 +81,7 @@ The ironmq component supports 31 endpoint options which are listed below:
|=======================================================================
// endpoint options: END
+
[[IronMQ-IronMQComponentOptions]]
IronMQComponent Options
^^^^^^^^^^^^^^^^^^^^^^^
http://git-wip-us.apache.org/repos/asf/camel/blob/ca28bf54/components/camel-ironmq/src/main/java/org/apache/camel/component/ironmq/IronMQConfiguration.java
----------------------------------------------------------------------
diff --git a/components/camel-ironmq/src/main/java/org/apache/camel/component/ironmq/IronMQConfiguration.java b/components/camel-ironmq/src/main/java/org/apache/camel/component/ironmq/IronMQConfiguration.java
index 7bd160b..8dae1b6 100644
--- a/components/camel-ironmq/src/main/java/org/apache/camel/component/ironmq/IronMQConfiguration.java
+++ b/components/camel-ironmq/src/main/java/org/apache/camel/component/ironmq/IronMQConfiguration.java
@@ -51,7 +51,7 @@ public class IronMQConfiguration {
// consumer properties
@UriParam(defaultValue = "1", label = "consumer")
- private Integer concurrentConsumers = 1;
+ private int concurrentConsumers = 1;
@UriParam(label = "consumer")
private boolean batchDelete;
@@ -76,14 +76,14 @@ public class IronMQConfiguration {
this.client = client;
}
- public Integer getConcurrentConsumers() {
+ public int getConcurrentConsumers() {
return concurrentConsumers;
}
/**
* The number of concurrent consumers.
*/
- public void setConcurrentConsumers(Integer concurrentConsumers) {
+ public void setConcurrentConsumers(int concurrentConsumers) {
this.concurrentConsumers = concurrentConsumers;
}
@@ -92,7 +92,7 @@ public class IronMQConfiguration {
}
/**
- * IronMq projectId
+ * IronMQ projectId
*/
public void setProjectId(String projectId) {
this.projectId = projectId;
@@ -103,7 +103,7 @@ public class IronMQConfiguration {
}
/**
- * IronMq token
+ * IronMQ token
*/
public void setToken(String token) {
this.token = token;
@@ -136,7 +136,7 @@ public class IronMQConfiguration {
}
/**
- * sets the timeout
+ * After timeout (in seconds), item will be placed back onto the queue.
*/
public void setTimeout(int timeout) {
this.timeout = timeout;
@@ -147,7 +147,7 @@ public class IronMQConfiguration {
}
/**
- * Number of messages to poll pr. call
+ * Number of messages to poll pr. call. Maximum is 100.
*/
public void setMaxMessagesPerPoll(int maxMessagesPerPoll) {
this.maxMessagesPerPoll = maxMessagesPerPoll;
@@ -158,7 +158,8 @@ public class IronMQConfiguration {
}
/**
- * Set's the visibility delay in seconds.
+ * The item will not be available on the queue until this many seconds have passed.
+ * Default is 0 seconds.
*/
public void setVisibilityDelay(int visibilityDelay) {
this.visibilityDelay = visibilityDelay;
@@ -169,7 +170,9 @@ public class IronMQConfiguration {
}
/**
- * Should camel message headers be preserved when publishing messages
+ * Should message headers be preserved when publishing messages.
+ * This will add the Camel headers to the Iron MQ message as a json payload with a header list, and a message body.
+ * Useful when Camel is both consumer and producer.
*/
public void setPreserveHeaders(boolean preserveHeaders) {
this.preserveHeaders = preserveHeaders;
@@ -180,7 +183,9 @@ public class IronMQConfiguration {
}
/**
- * Shold messages be deleted in one batch or one at the time
+ * Should messages be deleted in one batch.
+ * This will limit the number of api requests since messages are deleted in one request, instead of one pr. exchange.
+ * If enabled care should be taken that the consumer is idempotent when processing exchanges.
*/
public void setBatchDelete(boolean batchDelete) {
this.batchDelete = batchDelete;
@@ -191,7 +196,8 @@ public class IronMQConfiguration {
}
/**
- * Sets the wait
+ * Time in seconds to wait for a message to become available.
+ * This enables long polling. Default is 0 (does not wait), maximum is 30.
*/
public void setWait(int wait) {
this.wait = wait;