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/03/03 19:36:32 UTC

[09/14] camel git commit: Cleared up documentation.

Cleared up documentation.


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

Branch: refs/heads/master
Commit: d2b29216d4605b381647bd2ef3f2ab9e52adc1ca
Parents: f1e503d
Author: Jakub Korab <ja...@gmail.com>
Authored: Fri Mar 3 14:58:02 2017 +0000
Committer: Claus Ibsen <da...@apache.org>
Committed: Fri Mar 3 20:03:08 2017 +0100

----------------------------------------------------------------------
 .../kafka/KafkaIdempotentRepository.java           | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/d2b29216/components/camel-kafka/src/main/java/org/apache/camel/processor/idempotent/kafka/KafkaIdempotentRepository.java
----------------------------------------------------------------------
diff --git a/components/camel-kafka/src/main/java/org/apache/camel/processor/idempotent/kafka/KafkaIdempotentRepository.java b/components/camel-kafka/src/main/java/org/apache/camel/processor/idempotent/kafka/KafkaIdempotentRepository.java
index be1740c..5405799 100644
--- a/components/camel-kafka/src/main/java/org/apache/camel/processor/idempotent/kafka/KafkaIdempotentRepository.java
+++ b/components/camel-kafka/src/main/java/org/apache/camel/processor/idempotent/kafka/KafkaIdempotentRepository.java
@@ -58,15 +58,20 @@ import org.slf4j.LoggerFactory;
  * A Kafka topic-based implementation of {@link org.apache.camel.spi.IdempotentRepository}.
  *
  * Uses a local cache of previously seen Message IDs. Mutations that come in via the ({@link #add(String)}), or
- * {@link #remove(String)} method will update the local cache and broadcasting the change in state on a Kafka topic.
+ * {@link #remove(String)} method will update the local cache and broadcast the change in state on a Kafka topic to
+ * other instances. The cache is back-filled from the topic by a Kafka consumer.
  *
- * The topic used must be unique per repository instance. This class makes no
- * assumptions about number of partitions (it is designed to consume from all at the same time), or replication factor.
- * Each repository instance that uses the topic (e.g. on different machines running in parallel) controls its own
- * consumer group.
+ * The topic used must be unique per logical repository (i.e. two routes de-duplicate using different repositories,
+ * and different topics).
+ *
+ * This class makes no assumptions about the number of partitions (it is designed to consume from all at the
+ * same time), or replication factor of the topic.
+ *
+ * Each repository instance that uses the topic (e.g. typically on different machines running in parallel) controls its own
+ * consumer group, so in a cluster of 10 camel processes using the same topic each will control its own offset.
  *
  * On startup, the instance subscribes to the topic and rewinds the offset to the beginning, rebuilding the cache to the
- * latest state. The cache will not be considered to be warmed up until one poll of {@link #pollDurationMs} in length
+ * latest state. The cache will not be considered warmed up until one poll of {@link #pollDurationMs} in length
  * returns 0 records. Startup will not be completed until either the cache has warmed up, or 30 seconds go by; if the
  * latter happens the idempotent repository may be in an inconsistent state until its consumer catches up to the end
  * of the topic.