public class FlinkContainersBuilder extends Object
FlinkContainers
.Modifier and Type | Field and Description |
---|---|
static Path |
CHECKPOINT_PATH |
static Path |
HA_STORAGE_PATH |
static String |
JOB_MANAGER_HOSTNAME |
static String |
TASK_MANAGER_HOSTNAME_PREFIX |
static String |
ZOOKEEPER_HOSTNAME |
Constructor and Description |
---|
FlinkContainersBuilder() |
Modifier and Type | Method and Description |
---|---|
FlinkContainers |
build()
Builds
FlinkContainers . |
FlinkContainersBuilder |
dependsOn(org.testcontainers.containers.GenericContainer<?> container)
Lets Flink cluster depending on another container, and bind the network of Flink cluster to
the dependent one.
|
FlinkContainersBuilder |
enableZookeeperHA()
Enables high availability service.
|
<T> FlinkContainersBuilder |
setConfiguration(ConfigOption<T> option,
T value)
Sets a single configuration of the cluster.
|
FlinkContainersBuilder |
setConfiguration(Configuration conf)
Sets configurations of the cluster.
|
FlinkContainersBuilder |
setEnvironmentVariable(String key,
String value)
Sets environment variable to containers.
|
FlinkContainersBuilder |
setLogger(org.slf4j.Logger logger)
Sets a logger to the cluster in order to consume STDOUT of containers to the logger.
|
FlinkContainersBuilder |
setLogProperties(Properties logProperties)
Sets log4j properties.
|
FlinkContainersBuilder |
setLogProperty(String key,
String value)
Sets log4j property.
|
FlinkContainersBuilder |
setNetwork(org.testcontainers.containers.Network network)
Sets network of the Flink cluster.
|
FlinkContainersBuilder |
setNumTaskManagers(int numTaskManagers)
Sets number of TaskManagers.
|
public static final String JOB_MANAGER_HOSTNAME
public static final String TASK_MANAGER_HOSTNAME_PREFIX
public static final String ZOOKEEPER_HOSTNAME
public static final Path CHECKPOINT_PATH
public static final Path HA_STORAGE_PATH
public FlinkContainersBuilder setNumTaskManagers(int numTaskManagers)
public <T> FlinkContainersBuilder setConfiguration(ConfigOption<T> option, T value)
public FlinkContainersBuilder setConfiguration(Configuration conf)
public FlinkContainersBuilder dependsOn(org.testcontainers.containers.GenericContainer<?> container)
public FlinkContainersBuilder setEnvironmentVariable(String key, String value)
public FlinkContainersBuilder setNetwork(org.testcontainers.containers.Network network)
public FlinkContainersBuilder setLogger(org.slf4j.Logger logger)
public FlinkContainersBuilder setLogProperty(String key, String value)
Containers will use "log4j-console.properties" under flink-dist as the base configuration of loggers. Properties specified by this method will be appended to the config file, or overwrite the property if already exists in the base config file.
public FlinkContainersBuilder setLogProperties(Properties logProperties)
Containers will use "log4j-console.properties" under flink-dist as the base configuration of loggers. Properties specified by this method will be appended to the config file, or overwrite the property if already exists in the base config file.
public FlinkContainersBuilder enableZookeeperHA()
public FlinkContainers build()
FlinkContainers
.Copyright © 2014–2022 The Apache Software Foundation. All rights reserved.