You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@solr.apache.org by an...@apache.org on 2022/05/13 06:37:21 UTC

[solr-sandbox] branch crossdc-wip updated: Fix a compile error, add solr-core as a dependency as the URP requires it (#10)

This is an automated email from the ASF dual-hosted git repository.

anshum pushed a commit to branch crossdc-wip
in repository https://gitbox.apache.org/repos/asf/solr-sandbox.git


The following commit(s) were added to refs/heads/crossdc-wip by this push:
     new 3e321d8  Fix a compile error, add solr-core as a dependency as the URP requires it (#10)
3e321d8 is described below

commit 3e321d868ffe5f4d70969dafd975be5a74520b6c
Author: Anshum Gupta <an...@apache.org>
AuthorDate: Thu May 12 23:37:16 2022 -0700

    Fix a compile error, add solr-core as a dependency as the URP requires it (#10)
---
 crossdc-consumer/build.gradle                                         | 3 ++-
 .../apache/solr/update/processor/KafkaRequestMirroringHandler.java    | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/crossdc-consumer/build.gradle b/crossdc-consumer/build.gradle
index ab162f7..b6ec92e 100644
--- a/crossdc-consumer/build.gradle
+++ b/crossdc-consumer/build.gradle
@@ -32,7 +32,8 @@ application {
 }
 
 dependencies {
-    implementation group: 'org.apache.solr', name: 'solr-solrj', version: '8.11.1'
+    compile group: 'org.apache.solr', name: 'solr-solrj', version: '8.11.1'
+    compile group: 'org.apache.solr', name: 'solr-core', version: '8.11.1'
     implementation 'org.slf4j:slf4j-api'
     compile 'org.eclipse.jetty:jetty-http:9.4.41.v20210516'
     compile 'org.eclipse.jetty:jetty-server:9.4.41.v20210516'
diff --git a/crossdc-consumer/src/main/java/org/apache/solr/update/processor/KafkaRequestMirroringHandler.java b/crossdc-consumer/src/main/java/org/apache/solr/update/processor/KafkaRequestMirroringHandler.java
index 9d27bd9..5c4c23d 100644
--- a/crossdc-consumer/src/main/java/org/apache/solr/update/processor/KafkaRequestMirroringHandler.java
+++ b/crossdc-consumer/src/main/java/org/apache/solr/update/processor/KafkaRequestMirroringHandler.java
@@ -31,7 +31,8 @@ public class KafkaRequestMirroringHandler implements RequestMirroringHandler {
     public KafkaRequestMirroringHandler() {
         // TODO: Setup Kafka properly
         final String topicName = System.getProperty("topicname");
-        conf = new KafkaCrossDcConf(topicName, false, null);
+        final String boostrapServers = System.getProperty("bootstrapservers");
+        conf = new KafkaCrossDcConf(boostrapServers, topicName, false, null);
         sink = new KafkaMirroringSink(conf);
     }
 
@@ -45,6 +46,5 @@ public class KafkaRequestMirroringHandler implements RequestMirroringHandler {
             // TODO: Enforce external version constraint for consistent update replication (cross-cluster)
             sink.submit(new MirroredSolrRequest(1, request, TimeUnit.MILLISECONDS.toNanos(
                     System.currentTimeMillis())));
-        }
     }
 }