Skip to content

Commit

Permalink
[SDCISA-16147, swisspost#583] Fix the fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
hiddenalpha committed Jun 4, 2024
1 parent 721a69a commit 2bc60b9
Showing 1 changed file with 38 additions and 35 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,14 @@
import org.swisspush.gateleen.core.validation.ValidationStatus;
import org.swisspush.gateleen.validation.ValidationException;

import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Optional;
import java.util.regex.Pattern;

import static org.swisspush.gateleen.core.exception.GateleenExceptionFactory.newGateleenThriftyExceptionFactory;

/**
* Handler class for all Kafka related requests.
*
Expand Down Expand Up @@ -53,41 +56,41 @@ public class KafkaHandler extends ConfigurationResourceConsumer {

private boolean initialized = false;

// /** @deprecated Use {@link #builder()} */
// @Deprecated
// public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaProducerRepository repository,
// KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath) {
// this(configurationResourceManager, null, repository, kafkaMessageSender,
// configResourceUri, streamingPath);
// }
//
// /** @deprecated Use {@link #builder()} */
// @Deprecated
// public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaMessageValidator kafkaMessageValidator,
// KafkaProducerRepository repository, KafkaMessageSender kafkaMessageSender, String configResourceUri,
// String streamingPath) {
// this(configurationResourceManager, kafkaMessageValidator, repository, kafkaMessageSender,
// configResourceUri, streamingPath, new HashMap<>());
// }
//
// /** @deprecated Use {@link #builder()} */
// @Deprecated
// public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaProducerRepository repository,
// KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath, Map<String, Object> properties) {
//
// this(configurationResourceManager, null, repository, kafkaMessageSender,
// configResourceUri, streamingPath, properties);
// }
//
// /** @deprecated Use {@link #builder()} */
// @Deprecated
// public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaMessageValidator kafkaMessageValidator, KafkaProducerRepository repository,
// KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath, Map<String, Object> properties) {
// this(Vertx.vertx(), newGateleenThriftyExceptionFactory(), configurationResourceManager,
// kafkaMessageValidator, repository, kafkaMessageSender, configResourceUri, streamingPath,
// properties);
// log.warn("TODO: Do NOT use this DEPRECATED constructor! It creates instances that it should not create!");
// }
/** @deprecated Use {@link #builder()} */
@Deprecated
public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaProducerRepository repository,
KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath) {
this(configurationResourceManager, null, repository, kafkaMessageSender,
configResourceUri, streamingPath);
}

/** @deprecated Use {@link #builder()} */
@Deprecated
public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaMessageValidator kafkaMessageValidator,
KafkaProducerRepository repository, KafkaMessageSender kafkaMessageSender, String configResourceUri,
String streamingPath) {
this(configurationResourceManager, kafkaMessageValidator, repository, kafkaMessageSender,
configResourceUri, streamingPath, new HashMap<>());
}

/** @deprecated Use {@link #builder()} */
@Deprecated
public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaProducerRepository repository,
KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath, Map<String, Object> properties) {

this(configurationResourceManager, null, repository, kafkaMessageSender,
configResourceUri, streamingPath, properties);
}

/** @deprecated Use {@link #builder()} */
@Deprecated
public KafkaHandler(ConfigurationResourceManager configurationResourceManager, KafkaMessageValidator kafkaMessageValidator, KafkaProducerRepository repository,
KafkaMessageSender kafkaMessageSender, String configResourceUri, String streamingPath, Map<String, Object> properties) {
this(Vertx.vertx(), newGateleenThriftyExceptionFactory(), configurationResourceManager,
kafkaMessageValidator, repository, kafkaMessageSender, configResourceUri, streamingPath,
properties);
log.warn("TODO: Do NOT use this DEPRECATED constructor! It creates instances that it should not create!");
}

/** Use {@link #builder()} to get an instance. */
KafkaHandler(
Expand Down

0 comments on commit 2bc60b9

Please sign in to comment.