public class MySQLContainer extends JdbcDatabaseContainer
| Constructor and Description |
|---|
MySQLContainer() |
MySQLContainer(String dockerImageName) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
configure() |
protected String |
constructUrlForConnection(String queryString)
Template method for constructing the JDBC URL to be used for creating
Connections. |
boolean |
equals(Object o) |
String |
getDatabaseName() |
String |
getDriverClassName() |
String |
getJdbcUrl() |
protected Set<Integer> |
getLivenessCheckPorts() |
String |
getNetworkedJdbcUrl() |
String |
getPassword() |
String |
getTestQueryString() |
String |
getUsername() |
int |
hashCode() |
MySQLContainer |
withDatabaseName(String databaseName) |
MySQLContainer |
withNetwork(org.testcontainers.containers.Network network) |
MySQLContainer |
withNetworkAliases(String networkAlias) |
MySQLContainer |
withPassword(String password) |
MySQLContainer |
withUsername(String username) |
createConnection, getDataSource, getJdbcDriverInstance, getStartupTimeoutSeconds, waitUntilContainerStarted, withConnectTimeoutSeconds, withStartupTimeoutSecondsaddEnv, addExposedPort, addExposedPorts, addFileSystemBind, addFixedExposedPort, addFixedExposedPort, addLink, apply, containerIsCreated, containerIsStarted, containerIsStarting, containerIsStopped, containerIsStopping, copyFileFromContainer, copyFileFromContainer, copyFileToContainer, copyFileToContainer, createVolumeDirectory, dependsOn, dependsOn, doStart, execInContainer, execInContainer, failed, fetchDockerDaemonInfo, finished, getBinds, getCommandParts, getContainerId, getContainerInfo, getContainerName, getCopyToFileContainerPathMap, getCreateContainerCmdModifiers, getDependencies, getDockerClient, getDockerDaemonInfo, getDockerImageName, getEnv, getEnvMap, getExposedPorts, getExtraHosts, getImage, getIpAddress, getLabels, getLinkedContainers, getLivenessCheckPort, getLivenessCheckPortNumbers, getLogConsumers, getNetwork, getNetworkAliases, getNetworkMode, getPortBindings, getShmSize, getStartupAttempts, getStartupCheckStrategy, getTestHostIpAddress, getTmpFsMapping, getVolumesFroms, getWaitStrategy, getWorkingDirectory, isPrivilegedMode, logger, setBinds, setCommand, setCommand, setCommandParts, setCopyToFileContainerPathMap, setDockerImageName, setEnv, setExposedPorts, setExtraHosts, setImage, setLabels, setLinkedContainers, setLogConsumers, setNetwork, setNetworkAliases, setNetworkMode, setPortBindings, setPrivilegedMode, setShmSize, setStartupAttempts, setStartupCheckStrategy, setTmpFsMapping, setVolumesFroms, setWaitStrategy, setWorkingDirectory, start, starting, stop, succeeded, toString, waitingFor, withClasspathResourceMapping, withClasspathResourceMapping, withCommand, withCommand, withCopyFileToContainer, withCreateContainerCmdModifier, withEnv, withEnv, withExposedPorts, withExtraHost, withFileSystemBind, withLabel, withLabels, withLogConsumer, withMinimumRunningDuration, withNetworkAliases, withNetworkMode, withPrivilegedMode, withSharedMemorySize, withStartupAttempts, withStartupCheckStrategy, withStartupTimeout, withTmpFs, withVolumesFrom, withWorkingDirectoryclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddFileSystemBind, followOutput, followOutput, self, withEnv, withFileSystemBindpublic MySQLContainer()
public MySQLContainer(String dockerImageName)
protected Set<Integer> getLivenessCheckPorts()
getLivenessCheckPorts in class org.testcontainers.containers.GenericContainerprotected void configure()
configure in class org.testcontainers.containers.GenericContainerpublic String getDriverClassName()
getDriverClassName in class JdbcDatabaseContainerpublic String getJdbcUrl()
getJdbcUrl in class JdbcDatabaseContainerpublic String getNetworkedJdbcUrl()
protected String constructUrlForConnection(String queryString)
JdbcDatabaseContainerConnections.
This should be overridden if the JDBC URL and query string concatenation or URL string
construction needs to be different to normal.constructUrlForConnection in class JdbcDatabaseContainerqueryString - query string parameters that should be appended to the JDBC connection URL.
The '?' character must be includedpublic MySQLContainer withNetwork(org.testcontainers.containers.Network network)
withNetwork in interface org.testcontainers.containers.ContainerwithNetwork in class org.testcontainers.containers.GenericContainerpublic MySQLContainer withNetworkAliases(String networkAlias)
public String getDatabaseName()
getDatabaseName in class JdbcDatabaseContainerpublic String getUsername()
getUsername in class JdbcDatabaseContainerpublic String getPassword()
getPassword in class JdbcDatabaseContainerpublic String getTestQueryString()
getTestQueryString in class JdbcDatabaseContainerpublic MySQLContainer withDatabaseName(String databaseName)
withDatabaseName in class JdbcDatabaseContainerpublic MySQLContainer withUsername(String username)
withUsername in class JdbcDatabaseContainerpublic MySQLContainer withPassword(String password)
withPassword in class JdbcDatabaseContainerpublic boolean equals(Object o)
equals in class org.testcontainers.containers.GenericContainerpublic int hashCode()
hashCode in class org.testcontainers.containers.GenericContainerCopyright © 2019 WSO2. All rights reserved.