Class FlinkContainersSettings
- java.lang.Object
-
- org.apache.flink.connector.testframe.container.FlinkContainersSettings
-
public class FlinkContainersSettings extends Object
The central configuration holder for Flink container-based test environments.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFlinkContainersSettings.BuilderFlinkContainersConfigbuilder static inner class.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static FlinkContainersSettingsbasedOn(org.apache.flink.configuration.Configuration config)FlinkContainersConfigbased on provided Flink configuration.static FlinkContainersSettings.Builderbuilder()A new builder forFlinkContainersConfig.static FlinkContainersSettingsdefaultConfig()FlinkContainersConfigbased on defaults.StringgetBaseImage()Gets base image.StringgetCheckpointPath()Gets checkpoint path.static StringgetDefaultCheckpointPath()Gets default checkpoint path.static StringgetDefaultFlinkHome()Gets default flink home.org.apache.flink.configuration.ConfigurationgetFlinkConfig()Gets flink configuration.StringgetFlinkDistLocation()Gets flink dist location.StringgetFlinkHome()Gets flink home.StringgetHaStoragePath()Gets HA storage path.StringgetHaStoragePathUri()Gets ha storage path uri.Collection<String>getJarPaths()Gets jar paths.StringgetJobManagerHostname()Gets job manager hostname.PropertiesgetLogProperties()Gets logging properties.intgetNumSlotsPerTaskManager()Gets number slots per task manager.intgetNumTaskManagers()Gets number of task managers.StringgetTaskManagerHostnamePrefix()Gets task manager hostname prefix.StringgetZookeeperHostname()Gets Zookeeper hostname.BooleanisBuildFromFlinkDist()Returns whether to build from flink-dist or from an existing base container.BooleanisZookeeperHA()Is zookeeper HA boolean.
-
-
-
Method Detail
-
builder
public static FlinkContainersSettings.Builder builder()
A new builder forFlinkContainersConfig.- Returns:
- The builder.
-
defaultConfig
public static FlinkContainersSettings defaultConfig()
FlinkContainersConfigbased on defaults.- Returns:
- The Flink containers config.
-
basedOn
public static FlinkContainersSettings basedOn(org.apache.flink.configuration.Configuration config)
FlinkContainersConfigbased on provided Flink configuration.- Parameters:
config- The config.- Returns:
- The flink containers config.
-
getBaseImage
public String getBaseImage()
Gets base image.- Returns:
- The base image.
-
getNumTaskManagers
public int getNumTaskManagers()
Gets number of task managers.- Returns:
- The number task managers.
-
getNumSlotsPerTaskManager
public int getNumSlotsPerTaskManager()
Gets number slots per task manager.- Returns:
- The number slots per task manager.
-
getJarPaths
public Collection<String> getJarPaths()
Gets jar paths.- Returns:
- The jar paths.
-
getFlinkConfig
public org.apache.flink.configuration.Configuration getFlinkConfig()
Gets flink configuration.- Returns:
- The flink configuration.
-
getTaskManagerHostnamePrefix
public String getTaskManagerHostnamePrefix()
Gets task manager hostname prefix.- Returns:
- The task manager hostname prefix.
-
getJobManagerHostname
public String getJobManagerHostname()
Gets job manager hostname.- Returns:
- The job manager hostname.
-
isBuildFromFlinkDist
public Boolean isBuildFromFlinkDist()
Returns whether to build from flink-dist or from an existing base container. Also see thebaseImageproperty.
-
getFlinkDistLocation
public String getFlinkDistLocation()
Gets flink dist location.- Returns:
- The flink dist location.
-
getFlinkHome
public String getFlinkHome()
Gets flink home.- Returns:
- The flink home path.
-
getCheckpointPath
public String getCheckpointPath()
Gets checkpoint path.- Returns:
- The checkpoint path.
-
getHaStoragePath
public String getHaStoragePath()
Gets HA storage path.- Returns:
- The ha storage path.
-
getHaStoragePathUri
public String getHaStoragePathUri()
Gets ha storage path uri.- Returns:
- The HA storage path as URI (prefixed with file://).
-
getDefaultFlinkHome
public static String getDefaultFlinkHome()
Gets default flink home.- Returns:
- The default flink home path.
-
getDefaultCheckpointPath
public static String getDefaultCheckpointPath()
Gets default checkpoint path.- Returns:
- The default checkpoint path.
-
isZookeeperHA
public Boolean isZookeeperHA()
Is zookeeper HA boolean.
-
getZookeeperHostname
public String getZookeeperHostname()
Gets Zookeeper hostname.- Returns:
- The Zookeeper hostname.
-
getLogProperties
public Properties getLogProperties()
Gets logging properties.- Returns:
- The logging properties.
-
-