Class PostgreSQLConnection
java.lang.Object
migratedb.v1.core.internal.database.base.BaseConnection<PostgreSQLDatabase>
migratedb.v1.core.internal.database.postgresql.PostgreSQLConnection
- All Implemented Interfaces:
AutoCloseable,Connection<PostgreSQLDatabase>
- Direct Known Subclasses:
YugabyteDBConnection
PostgreSQL connection.
-
Field Summary
Fields inherited from class migratedb.v1.core.internal.database.base.BaseConnection
database, jdbcTemplate, originalSchemaNameOrSearchPath -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedPostgreSQLConnection(Configuration configuration, PostgreSQLDatabase database, Connection connection) -
Method Summary
Modifier and TypeMethodDescriptionvoidchangeCurrentSchemaTo(Schema<?, ?> schema) voidSchema<?,?> protected voidprotected StringSchema<?,?> Retrieves the schema with this name in the database.<T> TLocks this table and executes this callable.Methods inherited from class migratedb.v1.core.internal.database.base.BaseConnection
close, getCurrentSchema, getJdbcConnection, getJdbcTemplate, restoreOriginalState
-
Constructor Details
-
PostgreSQLConnection
protected PostgreSQLConnection(Configuration configuration, PostgreSQLDatabase database, Connection connection)
-
-
Method Details
-
doRestoreOriginalState
- Overrides:
doRestoreOriginalStatein classBaseConnection<PostgreSQLDatabase>- Throws:
SQLException
-
doGetCurrentSchema
- Overrides:
doGetCurrentSchemain classBaseConnection<PostgreSQLDatabase>- Throws:
SQLException
-
getCurrentSchemaNameOrSearchPath
- Specified by:
getCurrentSchemaNameOrSearchPathin classBaseConnection<PostgreSQLDatabase>- Throws:
SQLException- when the current schema name or search path could not be retrieved.
-
changeCurrentSchemaTo
- Specified by:
changeCurrentSchemaToin interfaceConnection<PostgreSQLDatabase>- Overrides:
changeCurrentSchemaToin classBaseConnection<PostgreSQLDatabase>
-
doChangeCurrentSchemaOrSearchPathTo
- Overrides:
doChangeCurrentSchemaOrSearchPathToin classBaseConnection<PostgreSQLDatabase>- Parameters:
schema- The new current schema for this connection.- Throws:
SQLException- when the current schema could not be set.
-
getSchema
Description copied from interface:ConnectionRetrieves the schema with this name in the database. -
lock
Description copied from interface:ConnectionLocks this table and executes this callable.- Specified by:
lockin interfaceConnection<PostgreSQLDatabase>- Overrides:
lockin classBaseConnection<PostgreSQLDatabase>- Returns:
- The result of the callable.
-