public class KafkaContainer extends org.testcontainers.containers.GenericContainer<KafkaContainer>
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
externalZookeeperConnect |
static int |
KAFKA_PORT |
protected org.testcontainers.containers.SocatContainer |
proxy |
static int |
ZOOKEEPER_PORT |
| Constructor and Description |
|---|
KafkaContainer() |
KafkaContainer(java.lang.String confluentPlatformVersion) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getBootstrapServers() |
void |
start() |
void |
stop() |
KafkaContainer |
withEmbeddedZookeeper() |
KafkaContainer |
withExternalZookeeper(java.lang.String connectString) |
addEnv, addExposedPort, addExposedPorts, addFileSystemBind, addFixedExposedPort, addFixedExposedPort, addLink, canEqual, close, configure, containerIsStarted, containerIsStarting, copyFileFromContainer, copyFileToContainer, createVolumeDirectory, equals, execInContainer, execInContainer, fetchDockerDaemonInfo, finished, getBinds, getCommandParts, getContainerId, getContainerInfo, getContainerName, getCreateContainerCmdModifiers, getDockerClient, getDockerDaemonInfo, getDockerImageName, getEnv, getEnvMap, getExposedPorts, getExtraHosts, getImage, getIpAddress, getLinkedContainers, getLivenessCheckPort, getLivenessCheckPortNumbers, getLivenessCheckPorts, getLogConsumers, getNetwork, getNetworkAliases, getNetworkMode, getPortBindings, getStartupAttempts, getStartupCheckStrategy, getTestHostIpAddress, getVolumesFroms, getWaitStrategy, getWorkingDirectory, hashCode, isPrivilegedMode, logger, setBinds, setCommand, setCommand, setCommandParts, setDockerImageName, setEnv, setExposedPorts, setExtraHosts, setImage, setLinkedContainers, setLogConsumers, setNetwork, setNetworkAliases, setNetworkMode, setPortBindings, setPrivilegedMode, setStartupAttempts, setStartupCheckStrategy, setVolumesFroms, setWaitStrategy, setWorkingDirectory, starting, toString, waitingFor, waitUntilContainerStarted, withClasspathResourceMapping, withClasspathResourceMapping, withCommand, withCommand, withCreateContainerCmdModifier, withEnv, withEnv, withExposedPorts, withExtraHost, withFileSystemBind, withLogConsumer, withMinimumRunningDuration, withNetwork, withNetworkAliases, withNetworkMode, withPrivilegedMode, withStartupAttempts, withStartupCheckStrategy, withStartupTimeout, withVolumesFrom, withWorkingDirectoryapply, failed, succeededclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int KAFKA_PORT
public static final int ZOOKEEPER_PORT
protected java.lang.String externalZookeeperConnect
protected org.testcontainers.containers.SocatContainer proxy
public KafkaContainer()
public KafkaContainer(java.lang.String confluentPlatformVersion)
public KafkaContainer withEmbeddedZookeeper()
public KafkaContainer withExternalZookeeper(java.lang.String connectString)
public java.lang.String getBootstrapServers()
public void start()
start in class org.testcontainers.containers.GenericContainer<KafkaContainer>public void stop()
stop in class org.testcontainers.containers.GenericContainer<KafkaContainer>