diff --git a/src-java/base-topology/base-storm-topology/build.gradle b/src-java/base-topology/base-storm-topology/build.gradle index c0e9905d94d..8d29c10317f 100644 --- a/src-java/base-topology/base-storm-topology/build.gradle +++ b/src-java/base-topology/base-storm-topology/build.gradle @@ -81,10 +81,7 @@ dependencies { exclude group: 'org.slf4j', module: 'slf4j-log4j12' exclude group: 'log4j', module: 'log4j' } - api('org.apache.kafka:kafka_2.11') { - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' - } + testImplementation 'org.apache.kafka:kafka_2.13' api 'io.micrometer:micrometer-core:1.8.2' diff --git a/src-java/base-topology/base-storm-topology/src/test/java/org/openkilda/wfm/TestUtils.java b/src-java/base-topology/base-storm-topology/src/test/java/org/openkilda/wfm/TestUtils.java index bf540d43498..b5f93babe90 100644 --- a/src-java/base-topology/base-storm-topology/src/test/java/org/openkilda/wfm/TestUtils.java +++ b/src-java/base-topology/base-storm-topology/src/test/java/org/openkilda/wfm/TestUtils.java @@ -19,8 +19,10 @@ import org.openkilda.wfm.config.ZookeeperConfig; import com.google.common.io.Files; -import kafka.server.KafkaServerStartable; +import kafka.server.KafkaServer; import org.apache.curator.test.TestingServer; +import org.apache.kafka.common.utils.Time; +import scala.Option; import java.io.File; import java.io.IOException; @@ -48,7 +50,7 @@ private static Properties serverProperties(ZookeeperConfig zookeeperConfig, Kafk public static class KafkaTestFixture { public TestingServer zk; - public KafkaServerStartable kafka; + public KafkaServer kafka; public File tempDir = Files.createTempDir(); private ZookeeperConfig zooKeeperConfig; private KafkaConfig kafkaConfig; @@ -72,7 +74,7 @@ private void start(Properties props) throws Exception { props.put("log.dirs", tempDir.getAbsolutePath()); kafka.server.KafkaConfig kafkaConfig = new kafka.server.KafkaConfig(props); - kafka = new KafkaServerStartable(kafkaConfig); + kafka = new KafkaServer(kafkaConfig, Time.SYSTEM, Option.empty(), false); kafka.startup(); System.out.println("Started KAFKA: "); } diff --git a/src-java/build.gradle b/src-java/build.gradle index 5ec2b54d823..2b124c273f8 100644 --- a/src-java/build.gradle +++ b/src-java/build.gradle @@ -58,12 +58,12 @@ subprojects { implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } } - implementation('org.apache.kafka:kafka_2.11') { + testImplementation('org.apache.kafka:kafka_2.13') { version { - strictly '2.3.1' + strictly '2.8.1' } } @@ -129,7 +129,8 @@ subprojects { testImplementation 'org.hamcrest:hamcrest-library:2.2' testImplementation 'org.mockito:mockito-junit-jupiter:4.2.0' testImplementation 'org.apache.curator:curator-test:2.8.0' - testImplementation 'io.netty:netty-all:4.1.72.Final' + implementation 'io.netty:netty-all:4.1.79.Final' + testImplementation 'io.netty:netty-all:4.1.79.Final' testRuntimeOnly 'javax.servlet:javax.servlet-api:3.1.0' implementation 'javax.validation:validation-api:2.0.1.Final' diff --git a/src-java/floodlight-service/floodlight-modules/build.gradle b/src-java/floodlight-service/floodlight-modules/build.gradle index 4e2454cb668..2841c0007a6 100644 --- a/src-java/floodlight-service/floodlight-modules/build.gradle +++ b/src-java/floodlight-service/floodlight-modules/build.gradle @@ -20,10 +20,6 @@ dependencies { testImplementation('org.projectfloodlight:floodlight') testImplementation 'org.mockito:mockito-junit-jupiter' - implementation('org.apache.kafka:kafka_2.11') { - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' - } implementation 'commons-codec:commons-codec' implementation 'org.apache.commons:commons-collections4' implementation 'com.auth0:java-jwt:3.2.0' diff --git a/src-java/floodlight-service/floodlight-modules/src/main/java/org/openkilda/floodlight/command/rulemanager/OfSpeakerService.java b/src-java/floodlight-service/floodlight-modules/src/main/java/org/openkilda/floodlight/command/rulemanager/OfSpeakerService.java index 83156802bf8..d35a45c680d 100644 --- a/src-java/floodlight-service/floodlight-modules/src/main/java/org/openkilda/floodlight/command/rulemanager/OfSpeakerService.java +++ b/src-java/floodlight-service/floodlight-modules/src/main/java/org/openkilda/floodlight/command/rulemanager/OfSpeakerService.java @@ -32,7 +32,7 @@ import org.openkilda.model.SwitchId; import com.google.common.collect.ImmutableMap; -import edu.umd.cs.findbugs.annotations.NonNull; +import lombok.NonNull; import lombok.extern.slf4j.Slf4j; import net.floodlightcontroller.core.IOFSwitch; import net.floodlightcontroller.core.internal.IOFSwitchService; diff --git a/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/FloodlightRouterTopology.java b/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/FloodlightRouterTopology.java index 9aec333ec20..375761f8654 100644 --- a/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/FloodlightRouterTopology.java +++ b/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/FloodlightRouterTopology.java @@ -34,7 +34,7 @@ import org.openkilda.wfm.topology.floodlightrouter.bolts.SpeakerToNetworkProxyBolt; import org.openkilda.wfm.topology.floodlightrouter.bolts.SwitchMonitorBolt; -import joptsimple.internal.Strings; +import com.google.common.base.Strings; import lombok.Value; import org.apache.storm.generated.StormTopology; import org.apache.storm.kafka.bolt.mapper.FieldNameBasedTupleToKafkaMapper; diff --git a/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/RegionAwareKafkaTopicSelector.java b/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/RegionAwareKafkaTopicSelector.java index e9e95aa007c..ec200833da6 100644 --- a/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/RegionAwareKafkaTopicSelector.java +++ b/src-java/floodlightrouter-topology/floodlightrouter-storm-topology/src/main/java/org/openkilda/wfm/topology/floodlightrouter/RegionAwareKafkaTopicSelector.java @@ -15,7 +15,7 @@ package org.openkilda.wfm.topology.floodlightrouter; -import joptsimple.internal.Strings; +import com.google.common.base.Strings; import lombok.extern.slf4j.Slf4j; import org.apache.storm.kafka.bolt.selector.KafkaTopicSelector; import org.apache.storm.tuple.Tuple; diff --git a/src-java/grpc-speaker/grpc-service/build.gradle b/src-java/grpc-speaker/grpc-service/build.gradle index af3834b6af4..42e90214742 100644 --- a/src-java/grpc-speaker/grpc-service/build.gradle +++ b/src-java/grpc-speaker/grpc-service/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -9,8 +9,8 @@ configurations { description = 'GRPC service' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':grpc-api') implementation project(':kilda-configuration') @@ -23,24 +23,14 @@ dependencies { implementation 'org.springframework.security:spring-security-web' implementation ('org.springframework.kafka:spring-kafka') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' - exclude group: 'org.apache.kafka', module: 'kafka-clients' } implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } } - implementation('org.apache.kafka:kafka_2.11') { - version { - strictly '2.3.1' - } - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' - } implementation 'org.slf4j:slf4j-api' implementation 'io.grpc:grpc-protobuf' diff --git a/src-java/grpc-speaker/grpc-service/src/main/java/org/openkilda/grpc/speaker/config/MessageConsumerConfig.java b/src-java/grpc-speaker/grpc-service/src/main/java/org/openkilda/grpc/speaker/config/MessageConsumerConfig.java index a5cd696a4b5..dd2ecffff88 100644 --- a/src-java/grpc-speaker/grpc-service/src/main/java/org/openkilda/grpc/speaker/config/MessageConsumerConfig.java +++ b/src-java/grpc-speaker/grpc-service/src/main/java/org/openkilda/grpc/speaker/config/MessageConsumerConfig.java @@ -35,7 +35,7 @@ import org.springframework.kafka.config.ConcurrentKafkaListenerContainerFactory; import org.springframework.kafka.core.ConsumerFactory; import org.springframework.kafka.core.DefaultKafkaConsumerFactory; -import org.springframework.kafka.support.serializer.ErrorHandlingDeserializer2; +import org.springframework.kafka.support.serializer.ErrorHandlingDeserializer; import org.springframework.kafka.support.serializer.JsonDeserializer; import java.util.Map; @@ -128,7 +128,7 @@ public Map consumerConfigs() { @Bean public ConsumerFactory consumerFactory() { return new DefaultKafkaConsumerFactory<>(consumerConfigs(), - new StringDeserializer(), new ErrorHandlingDeserializer2( + new StringDeserializer(), new ErrorHandlingDeserializer( new JsonDeserializer<>(CommandMessage.class))); } diff --git a/src-java/isllatency-topology/isllatency-storm-topology/build.gradle b/src-java/isllatency-topology/isllatency-storm-topology/build.gradle index 580742c0166..292729c76d6 100644 --- a/src-java/isllatency-topology/isllatency-storm-topology/build.gradle +++ b/src-java/isllatency-topology/isllatency-storm-topology/build.gradle @@ -31,6 +31,7 @@ dependencies { testRuntimeOnly 'org.glassfish:javax.el' testRuntimeOnly 'org.apache.curator:curator-test' testRuntimeOnly 'org.apache.logging.log4j:log4j-slf4j-impl' + testImplementation 'org.apache.kafka:kafka_2.13' compileOnly 'org.projectlombok:lombok' testCompileOnly 'org.projectlombok:lombok' diff --git a/src-java/northbound-service/northbound/build.gradle b/src-java/northbound-service/northbound/build.gradle index 9be0ba0854a..5b50c331a86 100644 --- a/src-java/northbound-service/northbound/build.gradle +++ b/src-java/northbound-service/northbound/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -9,8 +9,8 @@ configurations { description = 'Northbound Service' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':northbound-api') implementation project(':flowhs-messaging') @@ -34,25 +34,15 @@ dependencies { implementation 'org.springframework.boot:spring-boot-starter-tomcat' implementation ('org.springframework.kafka:spring-kafka') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' - exclude group: 'org.apache.kafka', module: 'kafka-clients' } implementation 'org.springframework:spring-webmvc' implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } } - implementation('org.apache.kafka:kafka_2.11') { - version { - strictly '2.3.1' - } - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' - } implementation 'org.apache.logging.log4j:log4j-api' implementation 'org.apache.logging.log4j:log4j-core' implementation 'org.apache.commons:commons-lang3' diff --git a/src-java/northbound-service/northbound/src/main/java/org/openkilda/northbound/config/MessageConsumerConfig.java b/src-java/northbound-service/northbound/src/main/java/org/openkilda/northbound/config/MessageConsumerConfig.java index fd00691fe72..a3f315d79b3 100644 --- a/src-java/northbound-service/northbound/src/main/java/org/openkilda/northbound/config/MessageConsumerConfig.java +++ b/src-java/northbound-service/northbound/src/main/java/org/openkilda/northbound/config/MessageConsumerConfig.java @@ -39,7 +39,7 @@ import org.springframework.kafka.config.ConcurrentKafkaListenerContainerFactory; import org.springframework.kafka.core.ConsumerFactory; import org.springframework.kafka.core.DefaultKafkaConsumerFactory; -import org.springframework.kafka.support.serializer.ErrorHandlingDeserializer2; +import org.springframework.kafka.support.serializer.ErrorHandlingDeserializer; import org.springframework.kafka.support.serializer.JsonDeserializer; import java.util.Map; @@ -128,7 +128,7 @@ private Map consumerConfigs() { @Bean public ConsumerFactory consumerFactory(ObjectMapper objectMapper) { return new DefaultKafkaConsumerFactory<>(consumerConfigs(), - new StringDeserializer(), new ErrorHandlingDeserializer2( + new StringDeserializer(), new ErrorHandlingDeserializer( new JsonDeserializer<>(Message.class, objectMapper))); } diff --git a/src-java/server42/server42-control-server-stub/build.gradle b/src-java/server42/server42-control-server-stub/build.gradle index b964377db4e..eb6741e45cc 100644 --- a/src-java/server42/server42-control-server-stub/build.gradle +++ b/src-java/server42/server42-control-server-stub/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -8,8 +8,8 @@ configurations { } dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':server42-control-messaging') implementation project(':server42-stats-messaging') diff --git a/src-java/server42/server42-control-storm-stub/build.gradle b/src-java/server42/server42-control-storm-stub/build.gradle index 314707b473f..93da80ca38e 100644 --- a/src-java/server42/server42-control-storm-stub/build.gradle +++ b/src-java/server42/server42-control-storm-stub/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -10,8 +10,8 @@ configurations { description = 'server42-control-storm-stub' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':server42-control-messaging') implementation project(':server42-messaging') @@ -34,25 +34,18 @@ dependencies { implementation ('org.springframework.kafka:spring-kafka') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } testImplementation ('org.springframework.kafka:spring-kafka-test') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } - implementation 'org.apache.kafka:kafka-clients' - implementation('org.apache.kafka:kafka_2.11') { + implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' } implementation 'org.mapstruct:mapstruct' diff --git a/src-java/server42/server42-control/build.gradle b/src-java/server42/server42-control/build.gradle index fe11d6761fe..5761d5747f4 100644 --- a/src-java/server42/server42-control/build.gradle +++ b/src-java/server42/server42-control/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -9,8 +9,8 @@ configurations { description = 'server42-control' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':kilda-model') implementation project(':blue-green') @@ -37,25 +37,18 @@ dependencies { implementation('org.springframework.kafka:spring-kafka') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } testImplementation('org.springframework.kafka:spring-kafka-test') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } - implementation 'org.apache.kafka:kafka-clients' - implementation('org.apache.kafka:kafka_2.11') { + implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' } compileOnly 'org.projectlombok:lombok' diff --git a/src-java/server42/server42-stats/build.gradle b/src-java/server42/server42-stats/build.gradle index e3fdb0385dc..9e80dd0ec21 100644 --- a/src-java/server42/server42-stats/build.gradle +++ b/src-java/server42/server42-stats/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'org.springframework.boot' version '2.2.13.RELEASE' + id 'org.springframework.boot' version '2.3.12.RELEASE' } configurations { @@ -9,8 +9,8 @@ configurations { description = 'server42-stats' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation(platform('org.springframework.boot:spring-boot-dependencies:2.2.13.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation(platform('org.springframework.boot:spring-boot-dependencies:2.3.12.RELEASE')) implementation project(':server42-stats-messaging') implementation project(':server42-messaging') @@ -40,25 +40,18 @@ dependencies { implementation('org.springframework.kafka:spring-kafka') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } testImplementation('org.springframework.kafka:spring-kafka-test') { version { - strictly '2.3.13.RELEASE' + strictly '2.6.13' } - // This conflicts with kafka_2.11 - exclude module:'kafka_2.12' } - implementation 'org.apache.kafka:kafka-clients' - implementation('org.apache.kafka:kafka_2.11') { + implementation('org.apache.kafka:kafka-clients') { version { - strictly '2.3.1' + strictly '2.8.1' } - exclude group: 'org.slf4j', module: 'slf4j-log4j12' - exclude group: 'log4j', module: 'log4j' } compileOnly 'org.projectlombok:lombok' diff --git a/src-java/stats-topology/stats-storm-topology/build.gradle b/src-java/stats-topology/stats-storm-topology/build.gradle index 08ac74df2b6..2f26bee1354 100644 --- a/src-java/stats-topology/stats-storm-topology/build.gradle +++ b/src-java/stats-topology/stats-storm-topology/build.gradle @@ -33,6 +33,7 @@ dependencies { testRuntimeOnly 'org.apache.logging.log4j:log4j-slf4j-impl' testRuntimeOnly 'org.glassfish:javax.el' testRuntimeOnly 'org.apache.curator:curator-test' + testImplementation 'org.apache.kafka:kafka_2.13' compileOnly 'org.projectlombok:lombok' testCompileOnly 'org.projectlombok:lombok' diff --git a/src-java/testing/functional-tests/build.gradle b/src-java/testing/functional-tests/build.gradle index 2855a216b6b..e85baf33cec 100644 --- a/src-java/testing/functional-tests/build.gradle +++ b/src-java/testing/functional-tests/build.gradle @@ -10,7 +10,7 @@ repositories { } dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) implementation project(':test-library') diff --git a/src-java/testing/performance-tests/build.gradle b/src-java/testing/performance-tests/build.gradle index 0bed9943b98..d8ba326bd0a 100644 --- a/src-java/testing/performance-tests/build.gradle +++ b/src-java/testing/performance-tests/build.gradle @@ -9,7 +9,7 @@ repositories { } dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) implementation project(':test-library') implementation project(':functional-tests') diff --git a/src-java/testing/test-library/build.gradle b/src-java/testing/test-library/build.gradle index 4298a1aac89..02f2fe1c205 100644 --- a/src-java/testing/test-library/build.gradle +++ b/src-java/testing/test-library/build.gradle @@ -4,8 +4,8 @@ plugins { description = 'Test-Library' dependencies { - implementation(platform('org.springframework:spring-framework-bom:5.2.19.RELEASE')) - implementation 'org.springframework.boot:spring-boot-autoconfigure:2.2.13.RELEASE' + implementation(platform('org.springframework:spring-framework-bom:5.2.22.RELEASE')) + implementation 'org.springframework.boot:spring-boot-autoconfigure:2.3.12.RELEASE' api project(':base-messaging') api project(':flowhs-messaging') @@ -34,7 +34,7 @@ dependencies { api 'org.springframework:spring-context' api 'org.springframework:spring-test' api 'org.springframework:spring-web' - api 'org.springframework.retry:spring-retry:1.3.1' + api 'org.springframework.retry:spring-retry:1.3.3' implementation 'org.springframework:spring-aspects' implementation('com.fasterxml.jackson.core:jackson-databind')