Package io.agroal.api.configuration
Interface AgroalConnectionFactoryConfiguration
-
public interface AgroalConnectionFactoryConfiguration
The configuration of the connection factory.- Author:
- Luis Barreiro
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
AgroalConnectionFactoryConfiguration.IsolationLevel
Interface to define the transaction isolation level.static class
AgroalConnectionFactoryConfiguration.TransactionIsolation
The default transaction isolation levels, defined inConnection
.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
autoCommit()
If connections should have the auto-commit mode on by default.Class<?>
connectionProviderClass()
JDBC driver class to use as a supplier of connections.Collection<Object>
credentials()
Collection of evidence used for authentication.String
initialSql()
A SQL command to be executed when a connection is created.Properties
jdbcProperties()
Other unspecified properties to be passed into the JDBC driver when creating new connections.AgroalConnectionFactoryConfiguration.IsolationLevel
jdbcTransactionIsolation()
The isolation level between database transactions.String
jdbcUrl()
The database URL to connect to.Principal
principal()
Entity to be authenticated in the database.Collection<Object>
recoveryCredentials()
Collection of evidence used for authentication for recovery connections.Principal
recoveryPrincipal()
Entity to be authenticated in the database for recovery connections.Collection<AgroalSecurityProvider>
securityProviders()
A collection of providers that are capable of handling principal / credential objectsboolean
trackJdbcResources()
-
-
-
Method Detail
-
autoCommit
boolean autoCommit()
If connections should have the auto-commit mode on by default. The transaction integration may disable auto-commit when a connection in enrolled in a transaction.
-
trackJdbcResources
boolean trackJdbcResources()
-
jdbcUrl
String jdbcUrl()
The database URL to connect to.
-
initialSql
String initialSql()
A SQL command to be executed when a connection is created.
-
connectionProviderClass
Class<?> connectionProviderClass()
JDBC driver class to use as a supplier of connections. Must be an implementation ofDriver
,DataSource
orXADataSource
. Can be null, in which case the driver will be obtained from the URL (using theDriverManager.getDriver(String)
mechanism).
-
jdbcTransactionIsolation
AgroalConnectionFactoryConfiguration.IsolationLevel jdbcTransactionIsolation()
The isolation level between database transactions.
-
securityProviders
Collection<AgroalSecurityProvider> securityProviders()
A collection of providers that are capable of handling principal / credential objects
-
principal
Principal principal()
Entity to be authenticated in the database.
-
credentials
Collection<Object> credentials()
Collection of evidence used for authentication.
-
recoveryPrincipal
Principal recoveryPrincipal()
Entity to be authenticated in the database for recovery connections. If not set, the principal will be used.
-
recoveryCredentials
Collection<Object> recoveryCredentials()
Collection of evidence used for authentication for recovery connections. If not set, the credentials will be used.
-
jdbcProperties
Properties jdbcProperties()
Other unspecified properties to be passed into the JDBC driver when creating new connections. NOTE: username and password properties are not allowed, these have to be set using the principal / credentials mechanism.
-
-