Class DatabaseConnectionFactory
- java.lang.Object
-
- com.redwood.scheduler.api.database.DatabaseConnectionFactory
-
public class DatabaseConnectionFactory extends Object
Factory for database connections.
-
-
Field Summary
Fields Modifier and Type Field Description static String
OPTION_LOGGER
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
andDatabaseConnectionBuilder.setPreLogger(DatabaseLogger)
,DatabaseConnectionBuilder.setPostLogger(DatabaseLogger)
and/orDatabaseConnectionBuilder.setErrorLogger(DatabaseErrorLogger)
instead.
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static DatabaseConnection
connect(com.redwood.scheduler.api.model.Credential c)
Deprecated.UseDatabase.connect(com.redwood.scheduler.api.model.Credential)
instead.static DatabaseConnection
connect(com.redwood.scheduler.api.model.Credential c, boolean setPLSQLJobContext)
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.static DatabaseConnection
connect(com.redwood.scheduler.api.model.Credential c, Map<String,?> options)
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.static DatabaseConnection
connect(com.redwood.scheduler.api.model.Credential c, Map<String,?> options, boolean setPLSQLJobContext)
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.
-
-
-
Field Detail
-
OPTION_LOGGER
@Deprecated public static final String OPTION_LOGGER
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
andDatabaseConnectionBuilder.setPreLogger(DatabaseLogger)
,DatabaseConnectionBuilder.setPostLogger(DatabaseLogger)
and/orDatabaseConnectionBuilder.setErrorLogger(DatabaseErrorLogger)
instead.Not used anymore.- See Also:
- Constant Field Values
-
-
Method Detail
-
connect
@Deprecated public static DatabaseConnection connect(com.redwood.scheduler.api.model.Credential c) throws SQLException
Deprecated.UseDatabase.connect(com.redwood.scheduler.api.model.Credential)
instead.Connect to a database using aCredential
.The endpoint and the partition of the credential must match name and partition of the
Database
, you want to connect to.- Parameters:
c
- the credential to use.- Returns:
- a connection.
- Throws:
SQLException
- if a connection cannot be made.
-
connect
@Deprecated public static DatabaseConnection connect(com.redwood.scheduler.api.model.Credential c, boolean setPLSQLJobContext) throws SQLException
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.Connect to a database using aCredential
.The endpoint and the partition of the credential must match name and partition of the
Database
, you want to connect to.- Parameters:
c
- the credential to use.setPLSQLJobContext
- should the job ID of the current context be passed to the PL/SQL API?- Returns:
- a connection.
- Throws:
SQLException
- if a connection cannot be made.
-
connect
@Deprecated public static DatabaseConnection connect(com.redwood.scheduler.api.model.Credential c, Map<String,?> options) throws SQLException
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.Connect to a database using aCredential
.The endpoint and the partition of the credential must match name and partition of the
Database
, you want to connect to.- Parameters:
c
- the credential to use.options
- ignored, seeOPTION_LOGGER
- Returns:
- a connection.
- Throws:
SQLException
- if a connection cannot be made.
-
connect
@Deprecated public static DatabaseConnection connect(com.redwood.scheduler.api.model.Credential c, Map<String,?> options, boolean setPLSQLJobContext) throws SQLException
Deprecated.UseDatabase.createDatabaseConnectionBuilder()
instead.Connect to a database using aCredential
.The endpoint and the partition of the credential must match name and partition of the
Database
, you want to connect to.- Parameters:
c
- the credential to use.options
- ignored, seeOPTION_LOGGER
setPLSQLJobContext
- should the job ID of the current context be passed to the PL/SQL API?- Returns:
- a connection.
- Throws:
SQLException
- if a connection cannot be made.
-
-