Package io.debezium.server
Class DebeziumServer
- java.lang.Object
-
- io.debezium.server.DebeziumServer
-
@ApplicationScoped public class DebeziumServer extends Object
The entry point of the Quarkus-based standalone server. The server is configured via Quarkus/Microprofile Configuration sources and provides few out-of-the-box target implementations.
The implementation uses CDI to find all classes that implements
DebeziumEngine.ChangeConsumerinterface. The candidate classes should be annotated with@Namedannotation and should beDependent.The configuration option
debezium.consumerprovides a name of the consumer that should be used and the value must match to exactly one of the implementation classes.- Author:
- Jiri Pechanec
-
-
Field Summary
-
Constructor Summary
Constructors Constructor Description DebeziumServer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private voidconfigToProperties(org.eclipse.microprofile.config.Config config, Properties props, String oldPrefix, String newPrefix)(package private) DebeziumEngine.ChangeConsumer<?>getConsumer()For test purposes onlyprivate Class<?>getFormat(org.eclipse.microprofile.config.Config config, String property)PropertiesgetProps()voidstart()voidstop(io.quarkus.runtime.ShutdownEvent event)
-
-
-
Field Detail
-
LOGGER
private static final org.slf4j.Logger LOGGER
-
PROP_PREFIX
private static final String PROP_PREFIX
- See Also:
- Constant Field Values
-
PROP_SOURCE_PREFIX
private static final String PROP_SOURCE_PREFIX
- See Also:
- Constant Field Values
-
PROP_SINK_PREFIX
private static final String PROP_SINK_PREFIX
- See Also:
- Constant Field Values
-
PROP_FORMAT_PREFIX
private static final String PROP_FORMAT_PREFIX
- See Also:
- Constant Field Values
-
PROP_TRANSFORMS_PREFIX
private static final String PROP_TRANSFORMS_PREFIX
- See Also:
- Constant Field Values
-
PROP_KEY_FORMAT_PREFIX
private static final String PROP_KEY_FORMAT_PREFIX
- See Also:
- Constant Field Values
-
PROP_VALUE_FORMAT_PREFIX
private static final String PROP_VALUE_FORMAT_PREFIX
- See Also:
- Constant Field Values
-
PROP_TRANSFORMS
private static final String PROP_TRANSFORMS
- See Also:
- Constant Field Values
-
PROP_SINK_TYPE
private static final String PROP_SINK_TYPE
- See Also:
- Constant Field Values
-
PROP_KEY_FORMAT
private static final String PROP_KEY_FORMAT
- See Also:
- Constant Field Values
-
PROP_VALUE_FORMAT
private static final String PROP_VALUE_FORMAT
- See Also:
- Constant Field Values
-
PROP_TERMINATION_WAIT
private static final String PROP_TERMINATION_WAIT
- See Also:
- Constant Field Values
-
FORMAT_JSON
private static final String FORMAT_JSON
-
FORMAT_AVRO
private static final String FORMAT_AVRO
-
FORMAT_PROTOBUF
private static final String FORMAT_PROTOBUF
-
SHELL_PROPERTY_NAME_PATTERN
private static final Pattern SHELL_PROPERTY_NAME_PATTERN
-
executor
private ExecutorService executor
-
beanManager
@Inject javax.enterprise.inject.spi.BeanManager beanManager
-
health
@Inject @Liveness ConnectorLifecycle health
-
consumerBean
private javax.enterprise.inject.spi.Bean<DebeziumEngine.ChangeConsumer<ChangeEvent<Object,Object>>> consumerBean
-
consumerBeanCreationalContext
private javax.enterprise.context.spi.CreationalContext<DebeziumEngine.ChangeConsumer<ChangeEvent<Object,Object>>> consumerBeanCreationalContext
-
consumer
private DebeziumEngine.ChangeConsumer<ChangeEvent<Object,Object>> consumer
-
engine
private DebeziumEngine<?> engine
-
props
private final Properties props
-
-
Method Detail
-
start
@PostConstruct public void start()
-
configToProperties
private void configToProperties(org.eclipse.microprofile.config.Config config, Properties props, String oldPrefix, String newPrefix)
-
getFormat
private Class<?> getFormat(org.eclipse.microprofile.config.Config config, String property)
-
stop
public void stop(@Observes io.quarkus.runtime.ShutdownEvent event)
-
getConsumer
DebeziumEngine.ChangeConsumer<?> getConsumer()
For test purposes only
-
getProps
public Properties getProps()
-
-