public class MySqlJdbcContext extends Object implements AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
protected Configuration |
config |
protected static JdbcConnection.ConnectionFactory |
FACTORY |
protected JdbcConnection |
jdbc |
protected static String |
JDBC_PROPERTY_LEGACY_DATETIME |
protected org.slf4j.Logger |
logger |
protected static String |
MYSQL_CONNECTION_URL |
private Map<String,String> |
originalSystemProperties |
private static String |
SQL_SHOW_SYSTEM_VARIABLES |
private static String |
SQL_SHOW_SYSTEM_VARIABLES_CHARACTER_SET |
| Constructor and Description |
|---|
MySqlJdbcContext(Configuration config) |
protected static final String MYSQL_CONNECTION_URL
protected static final String JDBC_PROPERTY_LEGACY_DATETIME
private static final String SQL_SHOW_SYSTEM_VARIABLES
private static final String SQL_SHOW_SYSTEM_VARIABLES_CHARACTER_SET
protected static JdbcConnection.ConnectionFactory FACTORY
protected final org.slf4j.Logger logger
protected final Configuration config
protected final JdbcConnection jdbc
public MySqlJdbcContext(Configuration config)
public Configuration config()
public JdbcConnection jdbc()
public org.slf4j.Logger logger()
public String username()
public String password()
public String hostname()
public int port()
public MySqlConnectorConfig.SecureConnectionMode sslMode()
public boolean sslModeEnabled()
public MySqlConnectorConfig.EventProcessingFailureHandlingMode eventDeserializationFailureHandlingMode()
public MySqlConnectorConfig.EventProcessingFailureHandlingMode inconsistentSchemaHandlingMode()
public void start()
public void shutdown()
public void close()
close in interface AutoCloseablepublic boolean isGtidModeEnabled()
false if the server's gtid_mode is set and is OFF, or true otherwisepublic String knownGtidSet()
public GtidSet purgedGtidSet()
public boolean userHasPrivileges(String grantName)
true.grantName - the name of the MySQL privilege; may not be nulltrue if the user has the named privilege, or false otherwiseprotected String connectionString()
protected Map<String,String> readMySqlCharsetSystemVariables()
protected Map<String,String> readMySqlSystemVariables()
Copyright © 2018 JBoss by Red Hat. All rights reserved.