From ac1bcb555ee0d43f13cb54c858ca800bfaf2e435 Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Sat, 14 Oct 2023 07:47:57 +0000 Subject: [PATCH 1/5] [Gradle Release Plugin] - new version commit: 'v1.2.46-SNAPSHOT'. --- gradle.properties | 2 +- .../modules/testerina-core/src/main/ballerina/Ballerina.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gradle.properties b/gradle.properties index f9fd87e1a4ba..6c38857f3771 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,6 +2,6 @@ org.gradle.caching=true org.gradle.parallel=true org.gradle.jvmargs='-Dfile.encoding=UTF-8' org.gradle.workers.max=3 -version=1.2.45 +version=1.2.46-SNAPSHOT group=org.ballerinalang bootstrappedOn=1.1.0-alpha diff --git a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml index 567dbb9d85ce..6e122b6e2bc2 100644 --- a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml +++ b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml @@ -8,5 +8,5 @@ target = "java8" [[platform.libraries]] artifactId = "mock" version = "0.0.0" - path = "./lib/testerina-core-1.2.44.jar" + path = "./lib/testerina-core-1.2.45.jar" groupId = "ballerina" From e410703d5c1cca2d0334dd3ca7b5fe248beadde1 Mon Sep 17 00:00:00 2001 From: RDPerera Date: Mon, 30 Oct 2023 15:06:23 +0530 Subject: [PATCH 2/5] Upgrade kafka/kafka-clients to V2.8.2 --- distribution/zip/jballerina-tools/LICENSE | 2 +- distribution/zip/jballerina/LICENSE | 2 +- gradle/javaLibsProject.gradle | 4 ++-- gradle/javaProject.gradle | 4 ++-- .../testerina-core/src/main/ballerina/Ballerina.toml | 2 +- stdlib/messaging/kafka/build.gradle | 2 +- .../messaging/kafka/src/main/ballerina/Ballerina.toml | 10 +++++----- .../messaging/kafka/utils/KafkaLocal.java | 6 ++---- tests/jballerina-integration-test/build.gradle | 2 +- 9 files changed, 16 insertions(+), 18 deletions(-) diff --git a/distribution/zip/jballerina-tools/LICENSE b/distribution/zip/jballerina-tools/LICENSE index 17df447fb889..c45eb3dec304 100644 --- a/distribution/zip/jballerina-tools/LICENSE +++ b/distribution/zip/jballerina-tools/LICENSE @@ -165,7 +165,7 @@ netty-common-4.1.39.Final.jar ballerina-formatter-1.1.0.jar jar apache2 quartz-jobs-2.3.0.jar jar apache2 ballerina-kafka-1.1.0.jar jar apache2 -kafka_2.11-2.0.1.jar jar apache2 +kafka_2.13-2.8.2.jar jar apache2 broker-coordination-0.970.0.jar bundle apache2 org.wso2.carbon.messaging-2.3.7.jar bundle apache2 bir.jar jar apache2 diff --git a/distribution/zip/jballerina/LICENSE b/distribution/zip/jballerina/LICENSE index c3c39e5094e9..90ed2e4446ba 100644 --- a/distribution/zip/jballerina/LICENSE +++ b/distribution/zip/jballerina/LICENSE @@ -165,7 +165,7 @@ netty-common-4.1.39.Final.jar ballerina-formatter-1.1.0.jar jar apache2 quartz-jobs-2.3.0.jar jar apache2 ballerina-kafka-1.1.0.jar jar apache2 -kafka_2.11-2.0.1.jar jar apache2 +kafka_2.13-2.8.2.jar jar apache2 broker-coordination-0.970.0.jar bundle apache2 org.wso2.carbon.messaging-2.3.7.jar bundle apache2 bir.jar jar apache2 diff --git a/gradle/javaLibsProject.gradle b/gradle/javaLibsProject.gradle index b9281a166b40..97eaaf23caae 100644 --- a/gradle/javaLibsProject.gradle +++ b/gradle/javaLibsProject.gradle @@ -44,8 +44,8 @@ dependencies { dist 'org.bouncycastle:bcpkix-jdk15on:1.61' dist 'info.picocli:picocli:4.0.1' - dist 'org.apache.kafka:kafka-clients:2.3.1' - dist 'org.apache.kafka:kafka_2.11:2.3.1' + dist 'org.apache.kafka:kafka-clients:2.8.2' + dist 'org.apache.kafka:kafka_2.13:2.8.2' dist 'io.ballerina.messaging:broker-auth:0.970.0' dist 'io.ballerina.messaging:broker-common:0.970.0' dist 'io.ballerina.messaging:broker-coordination:0.970.0' diff --git a/gradle/javaProject.gradle b/gradle/javaProject.gradle index c999eac5b5b8..3e2b671c14bd 100644 --- a/gradle/javaProject.gradle +++ b/gradle/javaProject.gradle @@ -59,8 +59,8 @@ dependencies { implementation 'org.apache.commons:commons-text:1.10.0' implementation 'org.apache.directory.server:apacheds-all:2.0.0-M24' implementation 'org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:1.0.1' - implementation 'org.apache.kafka:kafka-clients:2.3.1' - implementation 'org.apache.kafka:kafka_2.11:2.3.1' + implementation 'org.apache.kafka:kafka-clients:2.8.2' + implementation 'org.apache.kafka:kafka_2.13:2.8.2' implementation 'org.apache.avro:avro:1.9.2' implementation 'org.apache.james:apache-mime4j-core:0.8.9' implementation 'org.apache.mina:mina-core:2.0.16' diff --git a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml index 6e122b6e2bc2..6b3fb5f646e6 100644 --- a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml +++ b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml @@ -8,5 +8,5 @@ target = "java8" [[platform.libraries]] artifactId = "mock" version = "0.0.0" - path = "./lib/testerina-core-1.2.45.jar" + path = "./lib/testerina-core-1.2.46-SNAPSHOT.jar" groupId = "ballerina" diff --git a/stdlib/messaging/kafka/build.gradle b/stdlib/messaging/kafka/build.gradle index 968b4433e178..bc679a0d31ac 100644 --- a/stdlib/messaging/kafka/build.gradle +++ b/stdlib/messaging/kafka/build.gradle @@ -37,7 +37,7 @@ dependencies { implementation project(':ballerina-time') implementation project(':ballerina-lang:internal') implementation 'org.apache.kafka:kafka-clients' - implementation 'org.apache.kafka:kafka_2.11' + implementation 'org.apache.kafka:kafka_2.13' implementation 'org.apache.avro:avro' baloImplementation project(path: ':ballerina-filepath', configuration: 'baloImplementation') diff --git a/stdlib/messaging/kafka/src/main/ballerina/Ballerina.toml b/stdlib/messaging/kafka/src/main/ballerina/Ballerina.toml index 16f6840b5f7e..a0a93e253866 100644 --- a/stdlib/messaging/kafka/src/main/ballerina/Ballerina.toml +++ b/stdlib/messaging/kafka/src/main/ballerina/Ballerina.toml @@ -14,14 +14,14 @@ target = "java8" [[platform.libraries]] artifactId = "kafka-clients" - version = "2.3.1" - path = "./lib/kafka-clients-2.3.1.jar" + version = "2.8.2" + path = "./lib/kafka-clients-2.8.2.jar" groupId = "org.apache.kafka" modules = ["kafka"] [[platform.libraries]] - artifactId = "kafka_2.11" - version = "2.3.1" - path = "./lib/kafka_2.11-2.3.1.jar" + artifactId = "kafka_2.13" + version = "2.8.2" + path = "./lib/kafka_2.13-2.8.2.jar" groupId = "org.apache.kafka" modules = ["kafka"] diff --git a/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java b/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java index 5f64742f9732..36b9dbd3d807 100644 --- a/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java +++ b/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java @@ -34,13 +34,11 @@ */ public class KafkaLocal { private static final String prefix = "kafka-thread"; - private KafkaServer kafkaServer; - private Seq reporters; + private final KafkaServer kafkaServer; public KafkaLocal(Properties properties) { KafkaConfig kafkaConfig = KafkaConfig.fromProps(properties); - reporters = KafkaMetricsReporter$.MODULE$.startReporters(new VerifiableProperties(properties)); - this.kafkaServer = new KafkaServer(kafkaConfig, Time.SYSTEM, Option.apply(prefix), reporters); + this.kafkaServer = new KafkaServer(kafkaConfig, Time.SYSTEM, Option.apply(prefix),false); } public void start() { diff --git a/tests/jballerina-integration-test/build.gradle b/tests/jballerina-integration-test/build.gradle index dec306fbdfde..2c5239db9325 100644 --- a/tests/jballerina-integration-test/build.gradle +++ b/tests/jballerina-integration-test/build.gradle @@ -86,7 +86,7 @@ dependencies { implementation project(':observability-test-utils') implementation project(path: ':ballerina-test-utils', configuration: 'shadow') implementation 'org.apache.kafka:kafka-clients' - implementation 'org.apache.kafka:kafka_2.11' + implementation 'org.apache.kafka:kafka_2.13' implementation 'io.netty:netty-tcnative-classes' implementation 'io.netty:netty-tcnative-boringssl-static' implementation 'io.netty:netty-tcnative-boringssl-static::windows-x86_64' From 83395439811d94f928ff6d8432d9a4ca74fe93e6 Mon Sep 17 00:00:00 2001 From: RDPerera Date: Mon, 30 Oct 2023 16:06:49 +0530 Subject: [PATCH 3/5] Fix formatting issues --- .../testerina-core/src/main/ballerina/Ballerina.toml | 2 +- .../org/ballerinalang/messaging/kafka/utils/KafkaLocal.java | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml index 6b3fb5f646e6..6e122b6e2bc2 100644 --- a/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml +++ b/misc/testerina/modules/testerina-core/src/main/ballerina/Ballerina.toml @@ -8,5 +8,5 @@ target = "java8" [[platform.libraries]] artifactId = "mock" version = "0.0.0" - path = "./lib/testerina-core-1.2.46-SNAPSHOT.jar" + path = "./lib/testerina-core-1.2.45.jar" groupId = "ballerina" diff --git a/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java b/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java index 36b9dbd3d807..cc7e66ce3302 100644 --- a/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java +++ b/stdlib/messaging/kafka/src/test/java/org/ballerinalang/messaging/kafka/utils/KafkaLocal.java @@ -18,14 +18,10 @@ package org.ballerinalang.messaging.kafka.utils; -import kafka.metrics.KafkaMetricsReporter; -import kafka.metrics.KafkaMetricsReporter$; import kafka.server.KafkaConfig; import kafka.server.KafkaServer; -import kafka.utils.VerifiableProperties; import org.apache.kafka.common.utils.Time; import scala.Option; -import scala.collection.Seq; import java.util.Properties; @@ -38,7 +34,7 @@ public class KafkaLocal { public KafkaLocal(Properties properties) { KafkaConfig kafkaConfig = KafkaConfig.fromProps(properties); - this.kafkaServer = new KafkaServer(kafkaConfig, Time.SYSTEM, Option.apply(prefix),false); + this.kafkaServer = new KafkaServer(kafkaConfig, Time.SYSTEM, Option.apply(prefix), false); } public void start() { From c322c2ea48e35a1bc622288fea7613091b74caf7 Mon Sep 17 00:00:00 2001 From: Dilan Perera <39415471+RDPerera@users.noreply.github.com> Date: Tue, 31 Oct 2023 08:06:57 +0530 Subject: [PATCH 4/5] Update gradle.properties --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 6c38857f3771..f9fd87e1a4ba 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,6 +2,6 @@ org.gradle.caching=true org.gradle.parallel=true org.gradle.jvmargs='-Dfile.encoding=UTF-8' org.gradle.workers.max=3 -version=1.2.46-SNAPSHOT +version=1.2.45 group=org.ballerinalang bootstrappedOn=1.1.0-alpha From 82b7042188b4172bed13078838d9fc1934882c71 Mon Sep 17 00:00:00 2001 From: Dilan Perera <39415471+RDPerera@users.noreply.github.com> Date: Tue, 31 Oct 2023 09:14:00 +0530 Subject: [PATCH 5/5] Update gradle.properties --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index f9fd87e1a4ba..6c38857f3771 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,6 +2,6 @@ org.gradle.caching=true org.gradle.parallel=true org.gradle.jvmargs='-Dfile.encoding=UTF-8' org.gradle.workers.max=3 -version=1.2.45 +version=1.2.46-SNAPSHOT group=org.ballerinalang bootstrappedOn=1.1.0-alpha