Skip to content

Commit

Permalink
chore(bump): bump java version to 21
Browse files Browse the repository at this point in the history
- kafka client: 3.3.1 -> 3.8.0
- aspectj: 1.9.9.1 -> 1.9.21

Maven Plugins:
- clean: 3.2.0 -> 3.4.0
- compile: 3.10.1 -> 3.13.0
- resources: 3.2.0 -> 3.3.1
- surefire: 3.1.2 -> 3.5.1
- openapi generator : 6.6.0 -> 7.9.0
- springdoc openapi webflux: 1.2.32 -> 1.8.0
- surefire: 3.2.3 -> 3.5.1 (for e2e tests)
- surefire-ng: 3.2.5 -> 3.5.1 (for e2e tests)
  • Loading branch information
sixdouglas committed Oct 20, 2024
1 parent 2b9f0c3 commit 407899c
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions api/src/main/java/io/kafbat/ui/service/KafkaConnectService.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package io.kafbat.ui.service;

import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.ObjectMapper;
import io.kafbat.ui.connect.api.KafkaConnectClientApi;
import io.kafbat.ui.connect.model.ConnectorStatus;
Expand Down Expand Up @@ -31,7 +30,6 @@
import java.util.stream.Stream;
import javax.annotation.Nullable;
import lombok.RequiredArgsConstructor;
import lombok.SneakyThrows;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
Expand Down Expand Up @@ -107,9 +105,6 @@ public Mono<ConnectorTopics> getConnectorTopics(KafkaCluster cluster, String con
public Flux<String> getConnectorNames(KafkaCluster cluster, String connectName) {
return api(cluster, connectName)
.mono(client -> client.getConnectors(null))
// for some reason `getConnectors` method returns the response as a single string
.map(List::getFirst)
.map(this::parseConnectorsNamesStringToList)
.flatMapMany(Flux::fromIterable);
}

Expand All @@ -118,12 +113,6 @@ public Flux<String> getConnectorNamesWithErrorsSuppress(KafkaCluster cluster, St
return getConnectorNames(cluster, connectName).onErrorComplete();
}

@SneakyThrows
private List<String> parseConnectorsNamesStringToList(String json) {
return objectMapper.readValue(json, new TypeReference<>() {
});
}

public Mono<ConnectorDTO> createConnector(KafkaCluster cluster, String connectName,
Mono<NewConnectorDTO> connector) {
return api(cluster, connectName)
Expand Down

0 comments on commit 407899c

Please sign in to comment.