public class DefaultJpaConnectionProviderFactory extends Object implements JpaConnectionProviderFactory, ServerInfoAwareProviderFactory
Constructor and Description |
---|
DefaultJpaConnectionProviderFactory() |
Modifier and Type | Method and Description |
---|---|
void |
close()
This is called when the server shuts down.
|
JpaConnectionProvider |
create(KeycloakSession session) |
protected String |
detectDialect(Connection connection) |
Connection |
getConnection() |
String |
getId() |
Map<String,String> |
getOperationalInfo()
Return actual info about the provider.
|
String |
getSchema() |
void |
init(Config.Scope config)
Only called once when the factory is first created.
|
void |
postInit(KeycloakSessionFactory factory)
Called after all provider factories have been initialized
|
protected void |
prepareOperationalInfo(Connection connection) |
protected void |
startGlobalStats(KeycloakSession session,
int globalStatsIntervalSecs) |
protected void |
updateOrValidateDB(String databaseSchema,
Connection connection,
JpaUpdaterProvider updater,
String schema) |
public JpaConnectionProvider create(KeycloakSession session)
create
in interface ProviderFactory<JpaConnectionProvider>
public void close()
ProviderFactory
close
in interface ProviderFactory<JpaConnectionProvider>
public String getId()
getId
in interface ProviderFactory<JpaConnectionProvider>
public void init(Config.Scope config)
ProviderFactory
init
in interface ProviderFactory<JpaConnectionProvider>
public void postInit(KeycloakSessionFactory factory)
ProviderFactory
postInit
in interface ProviderFactory<JpaConnectionProvider>
protected void prepareOperationalInfo(Connection connection)
protected String detectDialect(Connection connection)
protected void startGlobalStats(KeycloakSession session, int globalStatsIntervalSecs)
protected void updateOrValidateDB(String databaseSchema, Connection connection, JpaUpdaterProvider updater, String schema)
public Connection getConnection()
getConnection
in interface JpaConnectionProviderFactory
public String getSchema()
getSchema
in interface JpaConnectionProviderFactory
public Map<String,String> getOperationalInfo()
ServerInfoAwareProviderFactory
getOperationalInfo
in interface ServerInfoAwareProviderFactory
Copyright © 2016 JBoss by Red Hat. All rights reserved.