public class MySqlSshDriver extends AbstractSoftwareProcessSshDriver implements MySqlDriver
MySqlDriver
.Modifier and Type | Field and Description |
---|---|
static org.slf4j.Logger |
log |
CHECK_RUNNING, CUSTOMIZING, DEBUG, IGNORE_ENTITY_SSH_FLAGS, INSTALL_INCOMPLETE, INSTALLING, KILLING, LAUNCHING, logSsh, NON_STANDARD_LAYOUT, PID_FILENAME, PROCESS_OWNER, RESTARTING, STOPPING, USE_PID_FILE, VALID_FLAGS
Constructor and Description |
---|
MySqlSshDriver(MySqlNodeImpl entity,
SshMachineLocation machine) |
Modifier and Type | Method and Description |
---|---|
void |
changePassword(java.lang.String oldPass,
java.lang.String newPass)
Updates the password, tries both the old and new password in-case the password has already been changed
|
void |
customize()
Implementations should fail if the return code is non-zero, by throwing some appropriate exception.
|
ProcessTaskWrapper<java.lang.Integer> |
dumpDatabase(java.lang.String additionalOptions,
java.lang.String dumpDestination) |
ProcessTaskWrapper<java.lang.Integer> |
executeScriptAsync(java.lang.String commands) |
ProcessTaskWrapper<java.lang.Integer> |
executeScriptFromInstalledFileAsync(java.lang.String filenameAlreadyInstalledAtServer) |
java.lang.String |
getBaseDir() |
java.lang.String |
getConfigFile() |
java.lang.String |
getDataDir() |
java.lang.String |
getDefaultUnpackedDirectoryName() |
MySqlNodeImpl |
getEntity()
The entity whose components we are controlling.
|
java.lang.String |
getLogFile() |
java.lang.String |
getMajorVersion() |
java.lang.String |
getMySqlServerOptionsString() |
java.lang.String |
getOsTag() |
java.lang.String |
getPassword() |
int |
getPort() |
java.lang.String |
getSocketUid() |
java.lang.String |
getStatusCmd() |
void |
install()
Implementations should fail if the return code is non-zero, by throwing some appropriate exception.
|
boolean |
isRunning()
Whether the entity components have started.
|
void |
kill()
Kills the process, ungracefully and immediately where possible (e.g.
|
void |
launch()
Implementations should fail if the return code is non-zero, by throwing some appropriate exception.
|
void |
prepare()
Prepare the entity instance before running any commands.
|
void |
stop()
Performs software stop (or queues tasks to do this)
|
checkNoHostnameBug, copyCustomizeResources, copyInstallResources, copyPreInstallResources, copyResource, copyResource, execute, execute, execute, getAddress, getHostname, getLocation, getMachine, getPortsUsed, getSubnetAddress, getSubnetHostname, runPostCustomizeCommand, runPostInstallCommand, runPostLaunchCommand, runPreCustomizeCommand, runPreInstallCommand, runPreLaunchCommand, setup
copyResource, copyResource, copyResource, copyResource, copyResource, copyResource, copyResource, copyRuntimeResources, copyTemplate, copyTemplate, copyTemplate, getArchiveNameFormat, getExpandedInstallDir, getInstallDir, getResource, getResourceAsString, getRunDir, getShellEnvironment, getVersion, postLaunch, preInstall, processTemplate, processTemplate, processTemplate, processTemplate, processTemplateContents, processTemplateContents, rebind, restart, setExpandedInstallDir, start
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
rebind, restart, start
getLocation
public MySqlSshDriver(MySqlNodeImpl entity, SshMachineLocation machine)
public java.lang.String getOsTag()
public java.lang.String getBaseDir()
public java.lang.String getDataDir()
public java.lang.String getLogFile()
public java.lang.String getConfigFile()
public java.lang.String getMajorVersion()
public java.lang.String getDefaultUnpackedDirectoryName()
public void prepare()
AbstractSoftwareProcessDriver
AbstractSoftwareProcessDriver.start()
.prepare
in class AbstractSoftwareProcessSshDriver
public void install()
AbstractSoftwareProcessDriver
install
in class AbstractSoftwareProcessDriver
public MySqlNodeImpl getEntity()
SoftwareProcessDriver
getEntity
in interface EntityDriver
getEntity
in interface SoftwareProcessDriver
getEntity
in class AbstractSoftwareProcessDriver
public int getPort()
public java.lang.String getSocketUid()
public java.lang.String getPassword()
public void customize()
AbstractSoftwareProcessDriver
customize
in class AbstractSoftwareProcessDriver
public void changePassword(java.lang.String oldPass, java.lang.String newPass)
changePassword
in interface MySqlDriver
oldPass
- newPass
- public java.lang.String getMySqlServerOptionsString()
public void launch()
AbstractSoftwareProcessDriver
launch
in class AbstractSoftwareProcessDriver
public boolean isRunning()
SoftwareProcessDriver
isRunning
in interface SoftwareProcessDriver
public void stop()
SoftwareProcessDriver
stop
in interface SoftwareProcessDriver
stop
in class AbstractSoftwareProcessDriver
Startable.stop()
public void kill()
SoftwareProcessDriver
kill
in interface SoftwareProcessDriver
kill
in class AbstractSoftwareProcessDriver
public java.lang.String getStatusCmd()
getStatusCmd
in interface MySqlDriver
public ProcessTaskWrapper<java.lang.Integer> executeScriptAsync(java.lang.String commands)
executeScriptAsync
in interface MySqlDriver
public ProcessTaskWrapper<java.lang.Integer> executeScriptFromInstalledFileAsync(java.lang.String filenameAlreadyInstalledAtServer)
executeScriptFromInstalledFileAsync
in interface MySqlDriver
public ProcessTaskWrapper<java.lang.Integer> dumpDatabase(java.lang.String additionalOptions, java.lang.String dumpDestination)
dumpDatabase
in interface MySqlDriver