Interface MySQLConnection
- All Superinterfaces:
AutoCloseable, Connection, Connection, ConnectionProperties, Wrapper
- All Known Subinterfaces:
JDBC4MySQLConnection, LoadBalancedConnection, ReplicationConnection
- All Known Implementing Classes:
ConnectionImpl, JDBC4Connection, JDBC4LoadBalancedMySQLConnection, JDBC4MultiHostMySQLConnection, JDBC4ReplicationMySQLConnection, LoadBalancedMySQLConnection, MultiHostMySQLConnection, ReplicationMySQLConnection
-
Field Summary
Fields inherited from interface Connection
TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateNewIO(boolean isForReconnect) voidvoiddumpTestcaseQuery(String query) execSQL(StatementImpl callingStatement, String sql, int maxRows, Buffer packet, int resultSetType, int resultSetConcurrency, boolean streamResults, String catalog, Field[] cachedMetadata) execSQL(StatementImpl callingStatement, String sql, int maxRows, Buffer packet, int resultSetType, int resultSetConcurrency, boolean streamResults, String catalog, Field[] cachedMetadata, boolean isBatch) extractSqlFromPacket(String possibleSqlQuery, Buffer queryPacket, int endOfQueryPacketPosition) intReturns the number of statements active on this connection, which haven't been .close()d.intReturns the -session- value of 'auto_increment_increment' from the server if it exists, or '1' if not.getCachedMetaData(String sql) getCharsetConverter(String javaEncodingName) getCharsetNameForIndex(int charsetIndex) Deprecated.getEncodingForIndex(int collationIndex) getHost()longgetId()longReports how long this connection has been idle.getIO()Deprecated.replaced bygetMultiHostSafeProxy()com.mysql.jdbc.log.LoggetLog()Returns the log mechanism that should be used to log information from/for this Connection.intgetMaxBytesPerChar(Integer charsetIndex, String javaCharsetName) intgetMaxBytesPerChar(String javaCharsetName) intcom.mysql.jdbc.profiler.ProfilerEventHandlerReturns the parsed and passed in properties for this connection.booleanReturns the server's character setintintintReturns the TimeZone that represents the configured timezone for the server.getServerVariable(String variableName) Returns the comment that will be prepended to all statements sent to the server.getURL()getUser()voidvoidvoidvoidinitializeResultsMetadataFromCache(String sql, CachedResultSetMetaData cachedMetaData, ResultSetInternalMethods resultSet) voidbooleanisAbonormallyLongQuery(long millisOrNanos) Update statistics that allows the driver to determine if a query is slow enough to be logged, and return the estimation result for millisOrNanos value.booleanbooleanbooleanbooleanbooleanbooleanisReadOnly(boolean useSessionStatus) booleanbooleanbooleanbooleanIs the server configured to use lower-case table names only?voidpingInternal(boolean checkForClosedConnection, int timeoutMillis) voidrealClose(boolean calledExplicitly, boolean issueRollback, boolean skipLocalTeardown, Throwable reason) voidvoidregisterQueryExecutionTime(long queryTimeMs) voidregisterStatement(Statement stmt) voidreportNumberOfTablesAccessed(int numTablesAccessed) booleanvoidsetProfilerEventHandlerInstance(com.mysql.jdbc.profiler.ProfilerEventHandler h) voidsetProxy(MySQLConnection proxy) voidsetReadInfoMsgEnabled(boolean flag) voidsetReadOnlyInternal(boolean readOnlyFlag) voidUsed by MiniAdmin to shutdown a MySQL serverbooleanvoidvoidvoidvoidunregisterStatement(Statement stmt) voidbooleanMethods inherited from interface Connection
abort, abortInternal, changeUser, checkClosed, clearHasTriedMaster, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, clientPrepareStatement, getConnectionMutex, getNetworkTimeout, getSchema, getServerCharacterEncoding, getSessionMaxRows, hasSameProperties, hasTriedMaster, initializeExtension, isInGlobalTx, isMasterConnection, isNoBackslashEscapesSet, isSameResource, isServerLocal, parserKnowsUnicode, ping, reportQueryTime, resetServerState, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, serverPrepareStatement, setFailedOver, setInGlobalTx, setNetworkTimeout, setPreferSlaveDuringFailover, setSchema, setSessionMaxRows, setStatementComment, supportsIsolationLevel, supportsQuotedIdentifiers, supportsTransactions, versionMeetsMinimumMethods inherited from interface Connection
beginRequest, clearWarnings, close, commit, createArrayOf, createBlob, createClob, createNClob, createSQLXML, createStatement, createStatement, createStatement, createStruct, endRequest, 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, setReadOnly, setSavepoint, setSavepoint, setShardingKey, setShardingKey, setShardingKeyIfValid, setShardingKeyIfValid, setTransactionIsolation, setTypeMapMethods inherited from interface ConnectionProperties
exposeAsXml, getAllowLoadLocalInfile, getAllowMasterDownConnections, 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, getEnabledTLSProtocols, 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, getLoadBalanceHostRemovalGracePeriod, 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, getReplicationEnableJMX, getReportMetricsIntervalMillis, getRequireSSL, getResourceId, getResultSetSizeThreshold, getRetainStatementAfterResultSetClose, getRetriesAllDown, getRewriteBatchedStatements, getRollbackOnPooledClose, getRoundRobinLoadBalance, getRunningCTS13, getSecondsBeforeRetryMaster, getSelfDestructOnPingMaxOperations, getSelfDestructOnPingSecondsLifetime, getSendFractionalSeconds, getServerAffinityOrder, 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, setAllowMasterDownConnections, 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, setEnabledTLSProtocols, 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, setLoadBalanceHostRemovalGracePeriod, 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, setReplicationEnableJMX, setReportMetricsIntervalMillis, setRequireSSL, setResourceId, setResultSetSizeThreshold, setRetainStatementAfterResultSetClose, setRetriesAllDown, setRewriteBatchedStatements, setRollbackOnPooledClose, setRoundRobinLoadBalance, setRunningCTS13, setSecondsBeforeRetryMaster, setSelfDestructOnPingMaxOperations, setSelfDestructOnPingSecondsLifetime, setSendFractionalSeconds, setServerAffinityOrder, 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, useUnbufferedInputMethods inherited from interface Wrapper
isWrapperFor, unwrap
-
Method Details
-
isProxySet
boolean isProxySet() -
createNewIO
- Throws:
SQLException
-
dumpTestcaseQuery
-
duplicate
- Throws:
SQLException
-
execSQL
ResultSetInternalMethods execSQL(StatementImpl callingStatement, String sql, int maxRows, Buffer packet, int resultSetType, int resultSetConcurrency, boolean streamResults, String catalog, Field[] cachedMetadata) throws SQLException - Throws:
SQLException
-
execSQL
ResultSetInternalMethods execSQL(StatementImpl callingStatement, String sql, int maxRows, Buffer packet, int resultSetType, int resultSetConcurrency, boolean streamResults, String catalog, Field[] cachedMetadata, boolean isBatch) throws SQLException - Throws:
SQLException
-
extractSqlFromPacket
String extractSqlFromPacket(String possibleSqlQuery, Buffer queryPacket, int endOfQueryPacketPosition) throws SQLException - Throws:
SQLException
-
generateConnectionCommentBlock
-
getActiveStatementCount
int getActiveStatementCount()Description copied from interface:ConnectionReturns the number of statements active on this connection, which haven't been .close()d.- Specified by:
getActiveStatementCountin interfaceConnection
-
getAutoIncrementIncrement
int getAutoIncrementIncrement()Description copied from interface:ConnectionReturns the -session- value of 'auto_increment_increment' from the server if it exists, or '1' if not.- Specified by:
getAutoIncrementIncrementin interfaceConnection
-
getCachedMetaData
-
getCalendarInstanceForSessionOrNew
Calendar getCalendarInstanceForSessionOrNew() -
getCancelTimer
Timer getCancelTimer() -
getCharacterSetMetadata
String getCharacterSetMetadata() -
getCharsetConverter
- Throws:
SQLException
-
getCharsetNameForIndex
Deprecated.replaced bygetEncodingForIndex(int collationIndex)- Throws:
SQLException
-
getEncodingForIndex
- Throws:
SQLException
-
getDefaultTimeZone
TimeZone getDefaultTimeZone() -
getErrorMessageEncoding
String getErrorMessageEncoding() -
getExceptionInterceptor
ExceptionInterceptor getExceptionInterceptor()- Specified by:
getExceptionInterceptorin interfaceConnectionProperties
-
getHost
String getHost()- Specified by:
getHostin interfaceConnection
-
getHostPortPair
String getHostPortPair() -
getId
long getId() -
getIdleFor
long getIdleFor()Description copied from interface:ConnectionReports how long this connection has been idle. This time (reported in milliseconds) is updated once a query has completed.- Specified by:
getIdleForin interfaceConnection- Returns:
- number of ms that this connection has been idle, 0 if the driver is busy retrieving results.
-
getIO
- Throws:
SQLException
-
getLog
Description copied from interface:ConnectionReturns the log mechanism that should be used to log information from/for this Connection.- Specified by:
getLogin interfaceConnection- Returns:
- the Log instance to use for logging messages.
- Throws:
SQLException- if an error occurs
-
getMaxBytesPerChar
- Throws:
SQLException
-
getMaxBytesPerChar
- Throws:
SQLException
-
getMetadataSafeStatement
- Throws:
SQLException
-
getNetBufferLength
int getNetBufferLength() -
getProperties
Properties getProperties()Description copied from interface:ConnectionReturns the parsed and passed in properties for this connection.- Specified by:
getPropertiesin interfaceConnection
-
getRequiresEscapingEncoder
boolean getRequiresEscapingEncoder() -
getServerCharset
String getServerCharset()Description copied from interface:ConnectionReturns the server's character set- Specified by:
getServerCharsetin interfaceConnection- Returns:
- the server's character set.
-
getServerMajorVersion
int getServerMajorVersion() -
getServerMinorVersion
int getServerMinorVersion() -
getServerSubMinorVersion
int getServerSubMinorVersion() -
getServerTimezoneTZ
TimeZone getServerTimezoneTZ()Description copied from interface:ConnectionReturns the TimeZone that represents the configured timezone for the server.- Specified by:
getServerTimezoneTZin interfaceConnection
-
getServerVariable
-
getServerVersion
String getServerVersion() -
getSessionLockedCalendar
Calendar getSessionLockedCalendar() -
getStatementComment
String getStatementComment()Description copied from interface:ConnectionReturns the comment that will be prepended to all statements sent to the server.- Specified by:
getStatementCommentin interfaceConnection- Returns:
- the comment that will be prepended to all statements sent to the server.
-
getStatementInterceptorsInstances
List<StatementInterceptorV2> getStatementInterceptorsInstances() -
getURL
String getURL() -
getUser
String getUser() -
getUtcCalendar
Calendar getUtcCalendar() -
incrementNumberOfPreparedExecutes
void incrementNumberOfPreparedExecutes() -
incrementNumberOfPrepares
void incrementNumberOfPrepares() -
incrementNumberOfResultSetsCreated
void incrementNumberOfResultSetsCreated() -
initializeResultsMetadataFromCache
void initializeResultsMetadataFromCache(String sql, CachedResultSetMetaData cachedMetaData, ResultSetInternalMethods resultSet) throws SQLException - Throws:
SQLException
-
initializeSafeStatementInterceptors
- Throws:
SQLException
-
isAbonormallyLongQuery
boolean isAbonormallyLongQuery(long millisOrNanos) Update statistics that allows the driver to determine if a query is slow enough to be logged, and return the estimation result for millisOrNanos value.Used in case autoSlowLog=true.
- Specified by:
isAbonormallyLongQueryin interfaceConnection- Parameters:
millisOrNanos- query execution time- Returns:
- true if millisOrNanos is outside the 99th percentile?
-
isClientTzUTC
boolean isClientTzUTC() -
isCursorFetchEnabled
- Throws:
SQLException
-
isReadInfoMsgEnabled
boolean isReadInfoMsgEnabled() -
isReadOnly
- Specified by:
isReadOnlyin interfaceConnection- Throws:
SQLException
-
isReadOnly
- Throws:
SQLException
-
isRunningOnJDK13
boolean isRunningOnJDK13() -
isServerTzUTC
boolean isServerTzUTC() -
lowerCaseTableNames
boolean lowerCaseTableNames()Description copied from interface:ConnectionIs the server configured to use lower-case table names only?- Specified by:
lowerCaseTableNamesin interfaceConnection- Returns:
- true if lower_case_table_names is 'on'
-
pingInternal
- Throws:
SQLException
-
realClose
void realClose(boolean calledExplicitly, boolean issueRollback, boolean skipLocalTeardown, Throwable reason) throws SQLException - Throws:
SQLException
-
recachePreparedStatement
- Throws:
SQLException
-
decachePreparedStatement
- Throws:
SQLException
-
registerQueryExecutionTime
void registerQueryExecutionTime(long queryTimeMs) -
registerStatement
-
reportNumberOfTablesAccessed
void reportNumberOfTablesAccessed(int numTablesAccessed) -
serverSupportsConvertFn
- Throws:
SQLException
-
setProxy
- Specified by:
setProxyin interfaceConnection
-
setReadInfoMsgEnabled
void setReadInfoMsgEnabled(boolean flag) -
setReadOnlyInternal
- Throws:
SQLException
-
shutdownServer
Description copied from interface:ConnectionUsed by MiniAdmin to shutdown a MySQL server- Specified by:
shutdownServerin interfaceConnection- Throws:
SQLException- if the command can not be issued.
-
storesLowerCaseTableName
boolean storesLowerCaseTableName() -
throwConnectionClosedException
- Throws:
SQLException
-
transactionBegun
- Throws:
SQLException
-
transactionCompleted
- Throws:
SQLException
-
unregisterStatement
-
unSafeStatementInterceptors
- Throws:
SQLException
-
useAnsiQuotedIdentifiers
boolean useAnsiQuotedIdentifiers() -
getConnectionAttributes
- Specified by:
getConnectionAttributesin interfaceConnectionProperties- Throws:
SQLException
-
getLoadBalanceSafeProxy
Deprecated.replaced bygetMultiHostSafeProxy() -
getMultiHostSafeProxy
MySQLConnection getMultiHostSafeProxy() -
getActiveMySQLConnection
MySQLConnection getActiveMySQLConnection() -
getProfilerEventHandlerInstance
com.mysql.jdbc.profiler.ProfilerEventHandler getProfilerEventHandlerInstance() -
setProfilerEventHandlerInstance
void setProfilerEventHandlerInstance(com.mysql.jdbc.profiler.ProfilerEventHandler h) -
isServerTruncatesFracSecs
boolean isServerTruncatesFracSecs() -
getQueryTimingUnits
String getQueryTimingUnits()
-
getEncodingForIndex(int collationIndex)