public class ReplicationMySQLConnection extends MultiHostMySQLConnection implements ReplicationConnection
thisAsProxy| Constructor and Description |
|---|
ReplicationMySQLConnection(MultiHostConnectionProxy proxy) |
| Modifier and Type | Method and Description |
|---|---|
void |
abort(java.util.concurrent.Executor executor) |
void |
abortInternal() |
void |
addSlaveHost(java.lang.String host) |
void |
changeUser(java.lang.String userName,
java.lang.String newPassword)
Changes the user on this connection by performing a re-authentication.
|
boolean |
getAllowMasterDownConnections() |
long |
getConnectionGroupId() |
Connection |
getCurrentConnection() |
Connection |
getMasterConnection() |
java.util.Properties |
getProperties()
Returns the parsed and passed in properties for this connection.
|
boolean |
getReplicationEnableJMX() |
Connection |
getSlavesConnection() |
protected ReplicationConnectionProxy |
getThisAsProxy() |
boolean |
hasSameProperties(Connection c)
Does this connection have the same properties as another?
|
boolean |
isHostMaster(java.lang.String host) |
boolean |
isHostSlave(java.lang.String host) |
boolean |
isReadOnly() |
void |
ping()
Detect if the connection is still good by sending a ping command
to the server.
|
void |
promoteSlaveToMaster(java.lang.String host) |
void |
removeMasterHost(java.lang.String host) |
void |
removeMasterHost(java.lang.String host,
boolean waitUntilNotInUse) |
void |
removeSlave(java.lang.String host) |
void |
removeSlave(java.lang.String host,
boolean closeGently) |
void |
setAllowMasterDownConnections(boolean connectIfMasterDown) |
void |
setProxy(MySQLConnection proxy) |
void |
setReadOnly(boolean readOnlyFlag) |
void |
setReplicationEnableJMX(boolean replicationEnableJMX) |
void |
setStatementComment(java.lang.String comment)
Sets the comment that will be prepended to all statements
sent to the server.
|
checkClosed, clearHasTriedMaster, clearWarnings, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, close, commit, createNewIO, createStatement, createStatement, createStatement, decachePreparedStatement, dumpTestcaseQuery, duplicate, execSQL, execSQL, exposeAsXml, extractSqlFromPacket, generateConnectionCommentBlock, getActiveMySQLConnection, getActiveStatementCount, getAllowLoadLocalInfile, getAllowMultiQueries, getAllowNanAndInf, getAllowPublicKeyRetrieval, getAllowSlaveDownConnections, getAllowUrlInLocalInfile, getAlwaysSendSetIsolation, getAuthenticationPlugins, getAutoClosePStmtStreams, getAutoCommit, getAutoDeserialize, getAutoGenerateTestcaseScript, getAutoIncrementIncrement, getAutoReconnectForPools, getAutoSlowLog, getBlobsAreStrings, getBlobSendChunkSize, getCacheCallableStatements, getCacheCallableStmts, getCacheDefaultTimezone, getCachedMetaData, getCachePreparedStatements, getCachePrepStmts, getCacheResultSetMetadata, getCacheServerConfiguration, getCalendarInstanceForSessionOrNew, getCallableStatementCacheSize, getCallableStmtCacheSize, getCancelTimer, getCapitalizeTypeNames, getCatalog, getCharacterSetMetadata, getCharacterSetResults, getCharsetConverter, getCharsetNameForIndex, getClientCertificateKeyStorePassword, getClientCertificateKeyStoreType, getClientCertificateKeyStoreUrl, getClientInfoProvider, getClobberStreamingResults, getClobCharacterEncoding, getCompensateOnDuplicateKeyUpdateCounts, getConnectionAttributes, getConnectionCollation, getConnectionLifecycleInterceptors, getConnectionMutex, getConnectTimeout, getContinueBatchOnError, getCreateDatabaseIfNotExist, getDefaultAuthenticationPlugin, getDefaultFetchSize, getDefaultTimeZone, getDetectCustomCollations, getDisabledAuthenticationPlugins, getDisconnectOnExpiredPasswords, getDontCheckOnDuplicateKeyUpdateInSQL, getDontTrackOpenResources, getDumpMetadataOnColumnNotFound, getDumpQueriesOnException, getDynamicCalendars, getElideSetAutoCommits, getEmptyStringsConvertToZero, getEmulateLocators, getEmulateUnsupportedPstmts, getEnabledSSLCipherSuites, getEnableEscapeProcessing, getEnablePacketDebug, getEnableQueryTimeouts, getEncoding, getEncodingForIndex, getErrorMessageEncoding, getExceptionInterceptor, getExceptionInterceptors, getExplainSlowQueries, getFailOverReadOnly, getFunctionsNeverReturnBlobs, getGatherPerfMetrics, getGatherPerformanceMetrics, getGenerateSimpleParameterMetadata, getGetProceduresReturnsFunctions, getHoldability, getHoldResultsOpenOverStatementClose, getHost, getId, getIdleFor, getIgnoreNonTxTables, getIncludeInnodbStatusInDeadlockExceptions, getIncludeThreadDumpInDeadlockExceptions, getIncludeThreadNamesAsStatementComment, getInitialTimeout, getInteractiveClient, getIO, getIsInteractiveClient, getJdbcCompliantTruncation, getJdbcCompliantTruncationForReads, getLargeRowSizeThreshold, getLoadBalanceAutoCommitStatementRegex, getLoadBalanceAutoCommitStatementThreshold, getLoadBalanceBlacklistTimeout, getLoadBalanceConnectionGroup, getLoadBalanceEnableJMX, getLoadBalanceExceptionChecker, getLoadBalancePingTimeout, getLoadBalanceSafeProxy, getLoadBalanceSQLExceptionSubclassFailover, getLoadBalanceSQLStateFailover, getLoadBalanceStrategy, getLoadBalanceValidateConnectionOnSwapServer, getLocalSocketAddress, getLocatorFetchBufferSize, getLog, getLogger, getLoggerClassName, getLogSlowQueries, getLogXaCommands, getMaintainTimeStats, getMaxAllowedPacket, getMaxBytesPerChar, getMaxBytesPerChar, getMaxQuerySizeToLog, getMaxReconnects, getMaxRows, getMetaData, getMetadataCacheSize, getMetadataSafeStatement, getMultiHostSafeProxy, getNetBufferLength, getNetTimeoutForStreamingResults, getNetworkTimeout, getNoAccessToProcedureBodies, getNoDatetimeStringSync, getNoTimezoneConversionForDateType, getNoTimezoneConversionForTimeType, getNullCatalogMeansCurrent, getNullNamePatternMatchesAll, getOverrideSupportsIntegrityEnhancementFacility, getPacketDebugBufferSize, getPadCharsWithSpace, getParanoid, getParseInfoCacheFactory, getPasswordCharacterEncoding, getPedantic, getPinGlobalTxToPhysicalConnection, getPopulateInsertRowWithDefaultValues, getPreparedStatementCacheSize, getPreparedStatementCacheSqlLimit, getPrepStmtCacheSize, getPrepStmtCacheSqlLimit, getProcessEscapeCodesForPrepStmts, getProfilerEventHandler, getProfilerEventHandlerInstance, getProfileSql, getProfileSQL, getPropertiesTransform, getQueriesBeforeRetryMaster, getQueryTimeoutKillsConnection, getReadFromMasterWhenNoSlaves, getReadOnlyPropagatesToServer, getReconnectAtTxEnd, getRelaxAutoCommit, getReportMetricsIntervalMillis, getRequiresEscapingEncoder, getRequireSSL, getResourceId, getResultSetSizeThreshold, getRetainStatementAfterResultSetClose, getRetriesAllDown, getRewriteBatchedStatements, getRollbackOnPooledClose, getRoundRobinLoadBalance, getRunningCTS13, getSchema, getSecondsBeforeRetryMaster, getSelfDestructOnPingMaxOperations, getSelfDestructOnPingSecondsLifetime, getSendFractionalSeconds, getServerCharacterEncoding, getServerCharset, getServerConfigCacheFactory, getServerMajorVersion, getServerMinorVersion, getServerRSAPublicKeyFile, getServerSubMinorVersion, getServerTimezone, getServerTimezoneTZ, getServerVariable, getServerVersion, getSessionLockedCalendar, getSessionMaxRows, getSessionVariables, getSlowQueryThresholdMillis, getSlowQueryThresholdNanos, getSocketFactory, getSocketFactoryClassName, getSocketTimeout, getSocksProxyHost, getSocksProxyPort, getStatementComment, getStatementInterceptors, getStatementInterceptorsInstances, getStrictFloatingPoint, getStrictUpdates, getTcpKeepAlive, getTcpNoDelay, getTcpRcvBuf, getTcpSndBuf, getTcpTrafficClass, getTinyInt1isBit, getTraceProtocol, getTransactionIsolation, getTransformedBitIsBoolean, getTreatUtilDateAsTimestamp, getTrustCertificateKeyStorePassword, getTrustCertificateKeyStoreType, getTrustCertificateKeyStoreUrl, getTypeMap, getUltraDevHack, getURL, getUseAffectedRows, getUseBlobToStoreUTF8OutsideBMP, getUseColumnNamesInFindColumn, getUseCompression, getUseConfigs, getUseCursorFetch, getUseDirectRowUnpack, getUseDynamicCharsetInfo, getUseFastDateParsing, getUseFastIntParsing, getUseGmtMillisForDatetimes, getUseHostsInPrivileges, getUseInformationSchema, getUseJDBCCompliantTimezoneShift, getUseJvmCharsetConverters, getUseLegacyDatetimeCode, getUseLocalSessionState, getUseLocalTransactionState, getUseNanosForElapsedTime, getUseOldAliasMetadataBehavior, getUseOldUTF8Behavior, getUseOnlyServerErrorMessages, getUser, getUseReadAheadInput, getUseServerPreparedStmts, getUseServerPrepStmts, getUseSqlStateCodes, getUseSSL, getUseSSPSCompatibleTimezoneShift, getUseStreamLengthsInPrepStmts, getUseTimezone, getUseUltraDevWorkAround, getUseUnbufferedInput, getUseUnicode, getUseUsageAdvisor, getUtcCalendar, getUtf8OutsideBmpExcludedColumnNamePattern, getUtf8OutsideBmpIncludedColumnNamePattern, getVerifyServerCertificate, getWarnings, getYearIsDateType, getZeroDateTimeBehavior, hasTriedMaster, incrementNumberOfPreparedExecutes, incrementNumberOfPrepares, incrementNumberOfResultSetsCreated, initializeExtension, initializeResultsMetadataFromCache, initializeSafeStatementInterceptors, isAbonormallyLongQuery, isClientTzUTC, isClosed, isCursorFetchEnabled, isInGlobalTx, isMasterConnection, isNoBackslashEscapesSet, isProxySet, isReadInfoMsgEnabled, isReadOnly, isRunningOnJDK13, isSameResource, isServerLocal, isServerTzUTC, isUseSSLExplicit, lowerCaseTableNames, nativeSQL, parserKnowsUnicode, pingInternal, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, realClose, recachePreparedStatement, registerQueryExecutionTime, registerStatement, releaseSavepoint, reportNumberOfTablesAccessed, reportQueryTime, resetServerState, rollback, rollback, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverSupportsConvertFn, setAllowLoadLocalInfile, setAllowMultiQueries, setAllowNanAndInf, setAllowPublicKeyRetrieval, setAllowSlaveDownConnections, setAllowUrlInLocalInfile, setAlwaysSendSetIsolation, setAuthenticationPlugins, setAutoClosePStmtStreams, setAutoCommit, setAutoDeserialize, setAutoGenerateTestcaseScript, setAutoReconnect, setAutoReconnectForConnectionPools, setAutoReconnectForPools, setAutoSlowLog, setBlobsAreStrings, setBlobSendChunkSize, setCacheCallableStatements, setCacheCallableStmts, setCacheDefaultTimezone, setCachePreparedStatements, setCachePrepStmts, setCacheResultSetMetadata, setCacheServerConfiguration, setCallableStatementCacheSize, setCallableStmtCacheSize, setCapitalizeDBMDTypes, setCapitalizeTypeNames, setCatalog, setCharacterEncoding, setCharacterSetResults, setClientCertificateKeyStorePassword, setClientCertificateKeyStoreType, setClientCertificateKeyStoreUrl, setClientInfoProvider, setClobberStreamingResults, setClobCharacterEncoding, setCompensateOnDuplicateKeyUpdateCounts, setConnectionCollation, setConnectionLifecycleInterceptors, setConnectTimeout, setContinueBatchOnError, setCreateDatabaseIfNotExist, setDefaultAuthenticationPlugin, setDefaultFetchSize, setDetectCustomCollations, setDetectServerPreparedStmts, setDisabledAuthenticationPlugins, setDisconnectOnExpiredPasswords, setDontCheckOnDuplicateKeyUpdateInSQL, setDontTrackOpenResources, setDumpMetadataOnColumnNotFound, setDumpQueriesOnException, setDynamicCalendars, setElideSetAutoCommits, setEmptyStringsConvertToZero, setEmulateLocators, setEmulateUnsupportedPstmts, setEnabledSSLCipherSuites, setEnableEscapeProcessing, setEnablePacketDebug, setEnableQueryTimeouts, setEncoding, setExceptionInterceptors, setExplainSlowQueries, setFailedOver, setFailOverReadOnly, setFunctionsNeverReturnBlobs, setGatherPerfMetrics, setGatherPerformanceMetrics, setGenerateSimpleParameterMetadata, setGetProceduresReturnsFunctions, setHoldability, setHoldResultsOpenOverStatementClose, setIgnoreNonTxTables, setIncludeInnodbStatusInDeadlockExceptions, setIncludeThreadDumpInDeadlockExceptions, setIncludeThreadNamesAsStatementComment, setInGlobalTx, setInitialTimeout, setInteractiveClient, setIsInteractiveClient, setJdbcCompliantTruncation, setJdbcCompliantTruncationForReads, setLargeRowSizeThreshold, setLoadBalanceAutoCommitStatementRegex, setLoadBalanceAutoCommitStatementThreshold, setLoadBalanceBlacklistTimeout, setLoadBalanceConnectionGroup, setLoadBalanceEnableJMX, setLoadBalanceExceptionChecker, setLoadBalancePingTimeout, setLoadBalanceSQLExceptionSubclassFailover, setLoadBalanceSQLStateFailover, setLoadBalanceStrategy, setLoadBalanceValidateConnectionOnSwapServer, setLocalSocketAddress, setLocatorFetchBufferSize, setLogger, setLoggerClassName, setLogSlowQueries, setLogXaCommands, setMaintainTimeStats, setMaxQuerySizeToLog, setMaxReconnects, setMaxRows, setMetadataCacheSize, setNetTimeoutForStreamingResults, setNetworkTimeout, setNoAccessToProcedureBodies, setNoDatetimeStringSync, setNoTimezoneConversionForDateType, setNoTimezoneConversionForTimeType, setNullCatalogMeansCurrent, setNullNamePatternMatchesAll, setOverrideSupportsIntegrityEnhancementFacility, setPacketDebugBufferSize, setPadCharsWithSpace, setParanoid, setParseInfoCacheFactory, setPasswordCharacterEncoding, setPedantic, setPinGlobalTxToPhysicalConnection, setPopulateInsertRowWithDefaultValues, setPreferSlaveDuringFailover, setPreparedStatementCacheSize, setPreparedStatementCacheSqlLimit, setPrepStmtCacheSize, setPrepStmtCacheSqlLimit, setProcessEscapeCodesForPrepStmts, setProfilerEventHandler, setProfilerEventHandlerInstance, setProfileSql, setProfileSQL, setPropertiesTransform, setQueriesBeforeRetryMaster, setQueryTimeoutKillsConnection, setReadFromMasterWhenNoSlaves, setReadInfoMsgEnabled, setReadOnlyInternal, setReadOnlyPropagatesToServer, setReconnectAtTxEnd, setRelaxAutoCommit, setReportMetricsIntervalMillis, setRequireSSL, setResourceId, setResultSetSizeThreshold, setRetainStatementAfterResultSetClose, setRetriesAllDown, setRewriteBatchedStatements, setRollbackOnPooledClose, setRoundRobinLoadBalance, setRunningCTS13, setSavepoint, setSavepoint, setSchema, setSecondsBeforeRetryMaster, setSelfDestructOnPingMaxOperations, setSelfDestructOnPingSecondsLifetime, setSendFractionalSeconds, setServerConfigCacheFactory, setServerRSAPublicKeyFile, setServerTimezone, setSessionMaxRows, setSessionVariables, setSlowQueryThresholdMillis, setSlowQueryThresholdNanos, setSocketFactory, setSocketFactoryClassName, setSocketTimeout, setSocksProxyHost, setSocksProxyPort, setStatementInterceptors, setStrictFloatingPoint, setStrictUpdates, setTcpKeepAlive, setTcpNoDelay, setTcpRcvBuf, setTcpSndBuf, setTcpTrafficClass, setTinyInt1isBit, setTraceProtocol, setTransactionIsolation, setTransformedBitIsBoolean, setTreatUtilDateAsTimestamp, setTrustCertificateKeyStorePassword, setTrustCertificateKeyStoreType, setTrustCertificateKeyStoreUrl, setTypeMap, setUltraDevHack, setUseAffectedRows, setUseBlobToStoreUTF8OutsideBMP, setUseColumnNamesInFindColumn, setUseCompression, setUseConfigs, setUseCursorFetch, setUseDirectRowUnpack, setUseDynamicCharsetInfo, setUseFastDateParsing, setUseFastIntParsing, setUseGmtMillisForDatetimes, setUseHostsInPrivileges, setUseInformationSchema, setUseJDBCCompliantTimezoneShift, setUseJvmCharsetConverters, setUseLegacyDatetimeCode, setUseLocalSessionState, setUseLocalTransactionState, setUseNanosForElapsedTime, setUseOldAliasMetadataBehavior, setUseOldUTF8Behavior, setUseOnlyServerErrorMessages, setUseReadAheadInput, setUseServerPreparedStmts, setUseServerPrepStmts, setUseSqlStateCodes, setUseSSL, setUseSSPSCompatibleTimezoneShift, setUseStreamLengthsInPrepStmts, setUseTimezone, setUseUltraDevWorkAround, setUseUnbufferedInput, setUseUnicode, setUseUsageAdvisor, setUtf8OutsideBmpExcludedColumnNamePattern, setUtf8OutsideBmpIncludedColumnNamePattern, setVerifyServerCertificate, setYearIsDateType, setZeroDateTimeBehavior, shutdownServer, storesLowerCaseTableName, supportsIsolationLevel, supportsQuotedIdentifiers, supportsTransactions, throwConnectionClosedException, transactionBegun, transactionCompleted, unregisterStatement, unSafeStatementInterceptors, useAnsiQuotedIdentifiers, useUnbufferedInput, versionMeetsMinimumclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreateNewIO, decachePreparedStatement, dumpTestcaseQuery, duplicate, execSQL, execSQL, extractSqlFromPacket, generateConnectionCommentBlock, getActiveStatementCount, getAutoIncrementIncrement, getCachedMetaData, getCalendarInstanceForSessionOrNew, getCancelTimer, getCharacterSetMetadata, getCharsetConverter, getCharsetNameForIndex, getConnectionAttributes, getDefaultTimeZone, getEncodingForIndex, getErrorMessageEncoding, getExceptionInterceptor, getHost, getId, getIdleFor, getIO, getLoadBalanceSafeProxy, getLog, getMaxBytesPerChar, getMaxBytesPerChar, getMetadataSafeStatement, getMultiHostSafeProxy, getNetBufferLength, getProfilerEventHandlerInstance, getRequiresEscapingEncoder, getServerCharset, getServerMajorVersion, getServerMinorVersion, getServerSubMinorVersion, getServerTimezoneTZ, getServerVariable, getServerVersion, getSessionLockedCalendar, getStatementComment, getStatementInterceptorsInstances, getURL, getUser, getUtcCalendar, incrementNumberOfPreparedExecutes, incrementNumberOfPrepares, incrementNumberOfResultSetsCreated, initializeResultsMetadataFromCache, initializeSafeStatementInterceptors, isAbonormallyLongQuery, isClientTzUTC, isCursorFetchEnabled, isProxySet, isReadInfoMsgEnabled, isReadOnly, isRunningOnJDK13, isServerTzUTC, lowerCaseTableNames, pingInternal, realClose, recachePreparedStatement, registerQueryExecutionTime, registerStatement, reportNumberOfTablesAccessed, serverSupportsConvertFn, setProfilerEventHandlerInstance, setReadInfoMsgEnabled, setReadOnlyInternal, shutdownServer, storesLowerCaseTableName, throwConnectionClosedException, transactionBegun, transactionCompleted, unregisterStatement, unSafeStatementInterceptors, useAnsiQuotedIdentifierscheckClosed, clearHasTriedMaster, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, getConnectionMutex, getNetworkTimeout, getSchema, getServerCharacterEncoding, getSessionMaxRows, hasTriedMaster, initializeExtension, isInGlobalTx, isMasterConnection, isNoBackslashEscapesSet, isSameResource, isServerLocal, parserKnowsUnicode, reportQueryTime, resetServerState, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, setFailedOver, setInGlobalTx, setNetworkTimeout, setPreferSlaveDuringFailover, setSchema, setSessionMaxRows, supportsIsolationLevel, supportsQuotedIdentifiers, supportsTransactions, versionMeetsMinimumclearWarnings, close, commit, createArrayOf, createBlob, createClob, createNClob, createSQLXML, createStatement, createStatement, createStatement, createStruct, getAutoCommit, getCatalog, getClientInfo, getClientInfo, getHoldability, getMetaData, getTransactionIsolation, getTypeMap, getWarnings, isClosed, isValid, nativeSQL, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, releaseSavepoint, rollback, rollback, setAutoCommit, setCatalog, setClientInfo, setClientInfo, setHoldability, setSavepoint, setSavepoint, setTransactionIsolation, setTypeMapexposeAsXml, getAllowLoadLocalInfile, getAllowMultiQueries, getAllowNanAndInf, getAllowPublicKeyRetrieval, getAllowSlaveDownConnections, getAllowUrlInLocalInfile, getAlwaysSendSetIsolation, getAuthenticationPlugins, getAutoClosePStmtStreams, getAutoDeserialize, getAutoGenerateTestcaseScript, getAutoReconnectForPools, getAutoSlowLog, getBlobsAreStrings, getBlobSendChunkSize, getCacheCallableStatements, getCacheCallableStmts, getCacheDefaultTimezone, getCachePreparedStatements, getCachePrepStmts, getCacheResultSetMetadata, getCacheServerConfiguration, getCallableStatementCacheSize, getCallableStmtCacheSize, getCapitalizeTypeNames, getCharacterSetResults, getClientCertificateKeyStorePassword, getClientCertificateKeyStoreType, getClientCertificateKeyStoreUrl, getClientInfoProvider, getClobberStreamingResults, getClobCharacterEncoding, getCompensateOnDuplicateKeyUpdateCounts, getConnectionCollation, getConnectionLifecycleInterceptors, getConnectTimeout, getContinueBatchOnError, getCreateDatabaseIfNotExist, getDefaultAuthenticationPlugin, getDefaultFetchSize, getDetectCustomCollations, getDisabledAuthenticationPlugins, getDisconnectOnExpiredPasswords, getDontCheckOnDuplicateKeyUpdateInSQL, getDontTrackOpenResources, getDumpMetadataOnColumnNotFound, getDumpQueriesOnException, getDynamicCalendars, getElideSetAutoCommits, getEmptyStringsConvertToZero, getEmulateLocators, getEmulateUnsupportedPstmts, getEnabledSSLCipherSuites, getEnableEscapeProcessing, getEnablePacketDebug, getEnableQueryTimeouts, getEncoding, getExceptionInterceptors, getExplainSlowQueries, getFailOverReadOnly, getFunctionsNeverReturnBlobs, getGatherPerfMetrics, getGatherPerformanceMetrics, getGenerateSimpleParameterMetadata, getGetProceduresReturnsFunctions, getHoldResultsOpenOverStatementClose, getIgnoreNonTxTables, getIncludeInnodbStatusInDeadlockExceptions, getIncludeThreadDumpInDeadlockExceptions, getIncludeThreadNamesAsStatementComment, getInitialTimeout, getInteractiveClient, getIsInteractiveClient, getJdbcCompliantTruncation, getJdbcCompliantTruncationForReads, getLargeRowSizeThreshold, getLoadBalanceAutoCommitStatementRegex, getLoadBalanceAutoCommitStatementThreshold, getLoadBalanceBlacklistTimeout, getLoadBalanceConnectionGroup, getLoadBalanceEnableJMX, getLoadBalanceExceptionChecker, getLoadBalancePingTimeout, getLoadBalanceSQLExceptionSubclassFailover, getLoadBalanceSQLStateFailover, getLoadBalanceStrategy, getLoadBalanceValidateConnectionOnSwapServer, getLocalSocketAddress, getLocatorFetchBufferSize, getLogger, getLoggerClassName, getLogSlowQueries, getLogXaCommands, getMaintainTimeStats, getMaxAllowedPacket, getMaxQuerySizeToLog, getMaxReconnects, getMaxRows, getMetadataCacheSize, getNetTimeoutForStreamingResults, getNoAccessToProcedureBodies, getNoDatetimeStringSync, getNoTimezoneConversionForDateType, getNoTimezoneConversionForTimeType, getNullCatalogMeansCurrent, getNullNamePatternMatchesAll, getOverrideSupportsIntegrityEnhancementFacility, getPacketDebugBufferSize, getPadCharsWithSpace, getParanoid, getParseInfoCacheFactory, getPasswordCharacterEncoding, getPedantic, getPinGlobalTxToPhysicalConnection, getPopulateInsertRowWithDefaultValues, getPreparedStatementCacheSize, getPreparedStatementCacheSqlLimit, getPrepStmtCacheSize, getPrepStmtCacheSqlLimit, getProcessEscapeCodesForPrepStmts, getProfilerEventHandler, getProfileSql, getProfileSQL, getPropertiesTransform, getQueriesBeforeRetryMaster, getQueryTimeoutKillsConnection, getReadFromMasterWhenNoSlaves, getReadOnlyPropagatesToServer, getReconnectAtTxEnd, getRelaxAutoCommit, getReportMetricsIntervalMillis, getRequireSSL, getResourceId, getResultSetSizeThreshold, getRetainStatementAfterResultSetClose, getRetriesAllDown, getRewriteBatchedStatements, getRollbackOnPooledClose, getRoundRobinLoadBalance, getRunningCTS13, getSecondsBeforeRetryMaster, getSelfDestructOnPingMaxOperations, getSelfDestructOnPingSecondsLifetime, getSendFractionalSeconds, getServerConfigCacheFactory, getServerRSAPublicKeyFile, getServerTimezone, getSessionVariables, getSlowQueryThresholdMillis, getSlowQueryThresholdNanos, getSocketFactory, getSocketFactoryClassName, getSocketTimeout, getSocksProxyHost, getSocksProxyPort, getStatementInterceptors, getStrictFloatingPoint, getStrictUpdates, getTcpKeepAlive, getTcpNoDelay, getTcpRcvBuf, getTcpSndBuf, getTcpTrafficClass, getTinyInt1isBit, getTraceProtocol, getTransformedBitIsBoolean, getTreatUtilDateAsTimestamp, getTrustCertificateKeyStorePassword, getTrustCertificateKeyStoreType, getTrustCertificateKeyStoreUrl, getUltraDevHack, getUseAffectedRows, getUseBlobToStoreUTF8OutsideBMP, getUseColumnNamesInFindColumn, getUseCompression, getUseConfigs, getUseCursorFetch, getUseDirectRowUnpack, getUseDynamicCharsetInfo, getUseFastDateParsing, getUseFastIntParsing, getUseGmtMillisForDatetimes, getUseHostsInPrivileges, getUseInformationSchema, getUseJDBCCompliantTimezoneShift, getUseJvmCharsetConverters, getUseLegacyDatetimeCode, getUseLocalSessionState, getUseLocalTransactionState, getUseNanosForElapsedTime, getUseOldAliasMetadataBehavior, getUseOldUTF8Behavior, getUseOnlyServerErrorMessages, getUseReadAheadInput, getUseServerPreparedStmts, getUseServerPrepStmts, getUseSqlStateCodes, getUseSSL, getUseSSPSCompatibleTimezoneShift, getUseStreamLengthsInPrepStmts, getUseTimezone, getUseUltraDevWorkAround, getUseUnbufferedInput, getUseUnicode, getUseUsageAdvisor, getUtf8OutsideBmpExcludedColumnNamePattern, getUtf8OutsideBmpIncludedColumnNamePattern, getVerifyServerCertificate, getYearIsDateType, getZeroDateTimeBehavior, isUseSSLExplicit, setAllowLoadLocalInfile, setAllowMultiQueries, setAllowNanAndInf, setAllowPublicKeyRetrieval, setAllowSlaveDownConnections, setAllowUrlInLocalInfile, setAlwaysSendSetIsolation, setAuthenticationPlugins, setAutoClosePStmtStreams, setAutoDeserialize, setAutoGenerateTestcaseScript, setAutoReconnect, setAutoReconnectForConnectionPools, setAutoReconnectForPools, setAutoSlowLog, setBlobsAreStrings, setBlobSendChunkSize, setCacheCallableStatements, setCacheCallableStmts, setCacheDefaultTimezone, setCachePreparedStatements, setCachePrepStmts, setCacheResultSetMetadata, setCacheServerConfiguration, setCallableStatementCacheSize, setCallableStmtCacheSize, setCapitalizeDBMDTypes, setCapitalizeTypeNames, setCharacterEncoding, setCharacterSetResults, setClientCertificateKeyStorePassword, setClientCertificateKeyStoreType, setClientCertificateKeyStoreUrl, setClientInfoProvider, setClobberStreamingResults, setClobCharacterEncoding, setCompensateOnDuplicateKeyUpdateCounts, setConnectionCollation, setConnectionLifecycleInterceptors, setConnectTimeout, setContinueBatchOnError, setCreateDatabaseIfNotExist, setDefaultAuthenticationPlugin, setDefaultFetchSize, setDetectCustomCollations, setDetectServerPreparedStmts, setDisabledAuthenticationPlugins, setDisconnectOnExpiredPasswords, setDontCheckOnDuplicateKeyUpdateInSQL, setDontTrackOpenResources, setDumpMetadataOnColumnNotFound, setDumpQueriesOnException, setDynamicCalendars, setElideSetAutoCommits, setEmptyStringsConvertToZero, setEmulateLocators, setEmulateUnsupportedPstmts, setEnabledSSLCipherSuites, setEnableEscapeProcessing, setEnablePacketDebug, setEnableQueryTimeouts, setEncoding, setExceptionInterceptors, setExplainSlowQueries, setFailOverReadOnly, setFunctionsNeverReturnBlobs, setGatherPerfMetrics, setGatherPerformanceMetrics, setGenerateSimpleParameterMetadata, setGetProceduresReturnsFunctions, setHoldResultsOpenOverStatementClose, setIgnoreNonTxTables, setIncludeInnodbStatusInDeadlockExceptions, setIncludeThreadDumpInDeadlockExceptions, setIncludeThreadNamesAsStatementComment, setInitialTimeout, setInteractiveClient, setIsInteractiveClient, setJdbcCompliantTruncation, setJdbcCompliantTruncationForReads, setLargeRowSizeThreshold, setLoadBalanceAutoCommitStatementRegex, setLoadBalanceAutoCommitStatementThreshold, setLoadBalanceBlacklistTimeout, setLoadBalanceConnectionGroup, setLoadBalanceEnableJMX, setLoadBalanceExceptionChecker, setLoadBalancePingTimeout, setLoadBalanceSQLExceptionSubclassFailover, setLoadBalanceSQLStateFailover, setLoadBalanceStrategy, setLoadBalanceValidateConnectionOnSwapServer, setLocalSocketAddress, setLocatorFetchBufferSize, setLogger, setLoggerClassName, setLogSlowQueries, setLogXaCommands, setMaintainTimeStats, setMaxQuerySizeToLog, setMaxReconnects, setMaxRows, setMetadataCacheSize, setNetTimeoutForStreamingResults, setNoAccessToProcedureBodies, setNoDatetimeStringSync, setNoTimezoneConversionForDateType, setNoTimezoneConversionForTimeType, setNullCatalogMeansCurrent, setNullNamePatternMatchesAll, setOverrideSupportsIntegrityEnhancementFacility, setPacketDebugBufferSize, setPadCharsWithSpace, setParanoid, setParseInfoCacheFactory, setPasswordCharacterEncoding, setPedantic, setPinGlobalTxToPhysicalConnection, setPopulateInsertRowWithDefaultValues, setPreparedStatementCacheSize, setPreparedStatementCacheSqlLimit, setPrepStmtCacheSize, setPrepStmtCacheSqlLimit, setProcessEscapeCodesForPrepStmts, setProfilerEventHandler, setProfileSql, setProfileSQL, setPropertiesTransform, setQueriesBeforeRetryMaster, setQueryTimeoutKillsConnection, setReadFromMasterWhenNoSlaves, setReadOnlyPropagatesToServer, setReconnectAtTxEnd, setRelaxAutoCommit, setReportMetricsIntervalMillis, setRequireSSL, setResourceId, setResultSetSizeThreshold, setRetainStatementAfterResultSetClose, setRetriesAllDown, setRewriteBatchedStatements, setRollbackOnPooledClose, setRoundRobinLoadBalance, setRunningCTS13, setSecondsBeforeRetryMaster, setSelfDestructOnPingMaxOperations, setSelfDestructOnPingSecondsLifetime, setSendFractionalSeconds, setServerConfigCacheFactory, setServerRSAPublicKeyFile, setServerTimezone, setSessionVariables, setSlowQueryThresholdMillis, setSlowQueryThresholdNanos, setSocketFactory, setSocketFactoryClassName, setSocketTimeout, setSocksProxyHost, setSocksProxyPort, setStatementInterceptors, setStrictFloatingPoint, setStrictUpdates, setTcpKeepAlive, setTcpNoDelay, setTcpRcvBuf, setTcpSndBuf, setTcpTrafficClass, setTinyInt1isBit, setTraceProtocol, setTransformedBitIsBoolean, setTreatUtilDateAsTimestamp, setTrustCertificateKeyStorePassword, setTrustCertificateKeyStoreType, setTrustCertificateKeyStoreUrl, setUltraDevHack, setUseAffectedRows, setUseBlobToStoreUTF8OutsideBMP, setUseColumnNamesInFindColumn, setUseCompression, setUseConfigs, setUseCursorFetch, setUseDirectRowUnpack, setUseDynamicCharsetInfo, setUseFastDateParsing, setUseFastIntParsing, setUseGmtMillisForDatetimes, setUseHostsInPrivileges, setUseInformationSchema, setUseJDBCCompliantTimezoneShift, setUseJvmCharsetConverters, setUseLegacyDatetimeCode, setUseLocalSessionState, setUseLocalTransactionState, setUseNanosForElapsedTime, setUseOldAliasMetadataBehavior, setUseOldUTF8Behavior, setUseOnlyServerErrorMessages, setUseReadAheadInput, setUseServerPreparedStmts, setUseServerPrepStmts, setUseSqlStateCodes, setUseSSL, setUseSSPSCompatibleTimezoneShift, setUseStreamLengthsInPrepStmts, setUseTimezone, setUseUltraDevWorkAround, setUseUnbufferedInput, setUseUnicode, setUseUsageAdvisor, setUtf8OutsideBmpExcludedColumnNamePattern, setUtf8OutsideBmpIncludedColumnNamePattern, setVerifyServerCertificate, setYearIsDateType, setZeroDateTimeBehavior, useUnbufferedInputpublic ReplicationMySQLConnection(MultiHostConnectionProxy proxy)
protected ReplicationConnectionProxy getThisAsProxy()
getThisAsProxy in class MultiHostMySQLConnectionpublic Connection getCurrentConnection()
getCurrentConnection in interface ReplicationConnectionpublic long getConnectionGroupId()
getConnectionGroupId in interface ReplicationConnectionpublic Connection getMasterConnection()
getMasterConnection in interface ReplicationConnectionpublic void promoteSlaveToMaster(java.lang.String host)
throws java.sql.SQLException
promoteSlaveToMaster in interface ReplicationConnectionjava.sql.SQLExceptionpublic void removeMasterHost(java.lang.String host)
throws java.sql.SQLException
removeMasterHost in interface ReplicationConnectionjava.sql.SQLExceptionpublic void removeMasterHost(java.lang.String host,
boolean waitUntilNotInUse)
throws java.sql.SQLException
removeMasterHost in interface ReplicationConnectionjava.sql.SQLExceptionpublic boolean isHostMaster(java.lang.String host)
isHostMaster in interface ReplicationConnectionpublic Connection getSlavesConnection()
getSlavesConnection in interface ReplicationConnectionpublic void addSlaveHost(java.lang.String host)
throws java.sql.SQLException
addSlaveHost in interface ReplicationConnectionjava.sql.SQLExceptionpublic void removeSlave(java.lang.String host)
throws java.sql.SQLException
removeSlave in interface ReplicationConnectionjava.sql.SQLExceptionpublic void removeSlave(java.lang.String host,
boolean closeGently)
throws java.sql.SQLException
removeSlave in interface ReplicationConnectionjava.sql.SQLExceptionpublic boolean isHostSlave(java.lang.String host)
isHostSlave in interface ReplicationConnectionpublic void setReadOnly(boolean readOnlyFlag)
throws java.sql.SQLException
setReadOnly in interface java.sql.ConnectionsetReadOnly in class MultiHostMySQLConnectionjava.sql.SQLExceptionpublic boolean isReadOnly()
throws java.sql.SQLException
isReadOnly in interface MySQLConnectionisReadOnly in interface java.sql.ConnectionisReadOnly in class MultiHostMySQLConnectionjava.sql.SQLExceptionpublic void ping()
throws java.sql.SQLException
Connectionping in class MultiHostMySQLConnectionjava.sql.SQLException - if the ping failspublic void changeUser(java.lang.String userName,
java.lang.String newPassword)
throws java.sql.SQLException
ConnectionchangeUser in class MultiHostMySQLConnectionuserName - the username to authenticate withnewPassword - the password to authenticate withjava.sql.SQLException - if authentication fails, or some other error occurs while
performing the command.public void setStatementComment(java.lang.String comment)
ConnectionsetStatementComment in class MultiHostMySQLConnectioncomment - the comment that will be prepended to all statements
sent to the server.public boolean hasSameProperties(Connection c)
ConnectionhasSameProperties in class MultiHostMySQLConnectionpublic java.util.Properties getProperties()
ConnectiongetProperties in interface MySQLConnectiongetProperties in class MultiHostMySQLConnectionpublic void abort(java.util.concurrent.Executor executor)
throws java.sql.SQLException
abort in interface java.sql.Connectionabort in class MultiHostMySQLConnectionjava.sql.SQLExceptionpublic void abortInternal()
throws java.sql.SQLException
abortInternal in class MultiHostMySQLConnectionjava.sql.SQLExceptionpublic boolean getAllowMasterDownConnections()
getAllowMasterDownConnections in interface ConnectionPropertiesgetAllowMasterDownConnections in class MultiHostMySQLConnectionpublic void setAllowMasterDownConnections(boolean connectIfMasterDown)
setAllowMasterDownConnections in interface ConnectionPropertiessetAllowMasterDownConnections in class MultiHostMySQLConnectionpublic boolean getReplicationEnableJMX()
getReplicationEnableJMX in interface ConnectionPropertiesgetReplicationEnableJMX in class MultiHostMySQLConnectionpublic void setReplicationEnableJMX(boolean replicationEnableJMX)
setReplicationEnableJMX in interface ConnectionPropertiessetReplicationEnableJMX in class MultiHostMySQLConnectionpublic void setProxy(MySQLConnection proxy)
setProxy in interface MySQLConnectionsetProxy in class MultiHostMySQLConnection