Class GrouperLoaderDb
java.lang.Object
edu.internet2.middleware.grouper.app.loader.db.GrouperLoaderDb
db profile from grouper.properties (or possibly grouper.hibernate.properties)
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionempty constructorGrouperLoaderDb
(String connectionName1) construct with all fields NOTE: this constructor is used by grouperClient, if you change it here, change it thereGrouperLoaderDb
(String user1, String pass1, String url1, String driver1) construct with all fields NOTE: this constructor is used by grouperClient, if you change it here, change it there -
Method Summary
Modifier and TypeMethodDescriptionstatic void
configTypeWithDatabaseConnection
(String connectionName) see which config file we are dealing with (as a base)get a connection from the db NOTE: this method is used by grouperClient, if you change it here, change it therestatic boolean
coreConfigOption
(String configItemName) db driver to use to logingetPass()
pass to login to dbthe quote to use or blank if not using quotesgetUrl()
url of the db to login togetUser()
user to login to dbvoid
TODO should this init only if not initted?boolean
void
retrievePoolConfigOrDefaultString
(String configItemName) look in config file for config entry if exists, if not then get the defaultvoid
db driver to use to loginvoid
pass to login to dbvoid
void
url of the db to login tovoid
user to login to dbtoString()
-
Constructor Details
-
GrouperLoaderDb
public GrouperLoaderDb()empty constructor -
GrouperLoaderDb
construct with all fields NOTE: this constructor is used by grouperClient, if you change it here, change it there- Parameters:
connectionName1
- connection name in grouper loader or grouper client config
-
GrouperLoaderDb
construct with all fields NOTE: this constructor is used by grouperClient, if you change it here, change it there- Parameters:
user1
-pass1
-url1
-driver1
-
-
-
Method Details
-
isUseQuotedColumnsInSql
public boolean isUseQuotedColumnsInSql() -
getQuoteForColumnsInSql
the quote to use or blank if not using quotes- Returns:
-
closeAllDataSources
public static void closeAllDataSources() -
connection
get a connection from the db NOTE: this method is used by grouperClient, if you change it here, change it there- Returns:
- the connection
-
initProperties
public void initProperties()TODO should this init only if not initted? -
setPoolProperties
public void setPoolProperties() -
refreshConnectionsIfNeeded
public void refreshConnectionsIfNeeded() -
coreConfigOption
- Parameters:
configItemName
-- Returns:
- true if something that shouldnt inherit from hibernate properties
-
configTypeWithDatabaseConnection
public static GrouperLoaderDb.DatabaseConfigType configTypeWithDatabaseConnection(String connectionName) see which config file we are dealing with (as a base)- Parameters:
connectionName
-configItemName
-- Returns:
- grouper, client, or loader
-
retrievePoolConfigOrDefaultString
look in config file for config entry if exists, if not then get the default- Parameters:
isClient
-configName
-configItemName
-useGrouperHibernateAsDefault
-- Returns:
- the config value
-
toString
-
getUser
user to login to db- Returns:
- the user
-
setUser
user to login to db- Parameters:
user1
- the user to set
-
getPass
pass to login to db- Returns:
- the pass
-
setPass
pass to login to db- Parameters:
pass1
- the pass to set
-
getUrl
url of the db to login to- Returns:
- the url
-
setUrl
url of the db to login to- Parameters:
url1
- the url to set
-
getDriver
db driver to use to login- Returns:
- the driver
-
setDriver
db driver to use to login- Parameters:
driver1
- the driver to set
-