You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by ja...@apache.org on 2020/04/08 01:04:09 UTC
[geode-kafka-connector] branch master updated: Added information
about --max-message-count and increased default queue and batch sizes
This is an automated email from the ASF dual-hosted git repository.
jasonhuynh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/geode-kafka-connector.git
The following commit(s) were added to refs/heads/master by this push:
new 63bc09a Added information about --max-message-count and increased default queue and batch sizes
63bc09a is described below
commit 63bc09a0cb7551472008ecbf27547024838e05ee
Author: Jason Huynh <hu...@gmail.com>
AuthorDate: Tue Apr 7 18:03:23 2020 -0700
Added information about --max-message-count and increased default queue and batch sizes
---
README.md | 2 +-
src/main/java/org/apache/geode/kafka/GeodeContext.java | 3 +++
.../apache/geode/kafka/utils/GeodeSourceConfigurationConstants.java | 4 ++--
3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 8a4a8f7..03b77a6 100644
--- a/README.md
+++ b/README.md
@@ -11,7 +11,7 @@ mvn package
---
#### Prerequisite
* Kafka is installed and is up and running. See the Kafka quickstart for more info: [Kafka Quickstart](https://kafka.apache.org/quickstart)
-* A Geode Cluster with at least one locator and one server and regions to source from and sink to.
+* A Geode Cluster with at least one locator and one server and regions to source from and sink to. Use the --max-message-count parameter in GFSH to set a large queue size so Geode will not throttle put operations.
* Topics created in Kafka to source from and sink to.
---
Installation of the connector is similar in process to other Kafka Connectors. For now, we will follow the guide for [Manual Installation](https://docs.confluent.io/current/connect/managing/install.html#install-connector-manually).
diff --git a/src/main/java/org/apache/geode/kafka/GeodeContext.java b/src/main/java/org/apache/geode/kafka/GeodeContext.java
index f7f8aa0..2fabceb 100644
--- a/src/main/java/org/apache/geode/kafka/GeodeContext.java
+++ b/src/main/java/org/apache/geode/kafka/GeodeContext.java
@@ -30,10 +30,13 @@ import org.apache.geode.cache.query.CqExistsException;
import org.apache.geode.cache.query.CqQuery;
import org.apache.geode.cache.query.CqResults;
import org.apache.geode.cache.query.RegionNotFoundException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
public class GeodeContext {
private ClientCache clientCache;
+ private static final Logger logger = LoggerFactory.getLogger(GeodeContext.class);
public GeodeContext() {}
diff --git a/src/main/java/org/apache/geode/kafka/utils/GeodeSourceConfigurationConstants.java b/src/main/java/org/apache/geode/kafka/utils/GeodeSourceConfigurationConstants.java
index a43ecf6..8d52b25 100644
--- a/src/main/java/org/apache/geode/kafka/utils/GeodeSourceConfigurationConstants.java
+++ b/src/main/java/org/apache/geode/kafka/utils/GeodeSourceConfigurationConstants.java
@@ -32,9 +32,9 @@ public class GeodeSourceConfigurationConstants {
public static final String CQS_TO_REGISTER = "cqsToRegister"; // used internally so that only 1
// task will register a cq
public static final String BATCH_SIZE = "geode-connector-batch-size";
- public static final String DEFAULT_BATCH_SIZE = "100";
+ public static final String DEFAULT_BATCH_SIZE = "50000";
public static final String QUEUE_SIZE = "geode-connector-queue-size";
- public static final String DEFAULT_QUEUE_SIZE = "10000";
+ public static final String DEFAULT_QUEUE_SIZE = "500000";
public static final String LOAD_ENTIRE_REGION = "load-entire-region";
public static final String DEFAULT_LOAD_ENTIRE_REGION = "false";
public static final String CQS_TO_REGISTER_DOCUMENTATION =