@Transactional public class PropertyManagerGeneric extends Object implements PropertyManager
| Constructor and Description |
|---|
PropertyManagerGeneric(PropertyDAO propertyDAO,
com.atlassian.event.api.EventPublisher eventPublisher) |
| Modifier and Type | Method and Description |
|---|---|
void |
generateDesEncryptionKey()
Generates and stores a DES key for DES encoded passwords.
|
AuditLogConfiguration |
getAuditLogConfiguration()
Retrieves the audit log configuration
|
URI |
getBaseUrl() |
boolean |
getBoolean(String property,
boolean defaultValue)
Gets a boolean property.
|
Integer |
getBuildNumber()
This method returns the current build number for Crowd from the datastore.
|
CookieConfiguration |
getCookieConfiguration() |
int |
getCurrentLicenseResourceTotal() |
String |
getDeploymentTitle() |
Key |
getDesEncryptionKey() |
String |
getDomain()
Will return the Domain property from the datastore or null if the domain has
not been set.
|
int |
getInt(String property,
int defaultValue)
Gets an integer property.
|
String |
getNotificationEmail() |
String |
getProperty(String name)
Retrieves an arbitrary property by name.
|
protected Property |
getPropertyObject(String name) |
long |
getSessionTime() |
SMTPServer |
getSMTPServer() |
String |
getSMTPTemplate()
Deprecated.
|
String |
getString(String property,
String defaultValue)
Gets a string property.
|
String |
getTrustedProxyServers()
Retrieves a String that contains a list of proxy servers we trust to correctly set the X-Forwarded-For flag.
|
boolean |
isCacheEnabled() |
boolean |
isGzipEnabled() |
boolean |
isIncludeIpAddressInValidationFactors()
Should the client IP address be included as a validation factor?
|
boolean |
isSecureCookie() |
boolean |
isUseWebAvatars()
Should public services be used for user avatars?
|
boolean |
isUsingDatabaseTokenStorage()
Will return true if the Crowd instance is using database token storage for authentication
Token's
otherwise assume we are using in-memory |
void |
removeProperty(String name)
Will attempt to remove a property from the datastore
|
void |
setAuditLogConfiguration(AuditLogConfiguration newConfiguration)
Persists the audit log configuration
|
void |
setBaseUrl(URI url)
Sets the base URL for this Crowd application instance
|
void |
setBuildNumber(Integer buildNumber)
Will set the buildNumber for the current release of Crowd.
|
void |
setCacheEnabled(boolean enabled) |
void |
setCookieConfiguration(CookieConfiguration cookieConfiguration)
Updates the configuration of Crowd's cookie-based SSO
|
void |
setCurrentLicenseResourceTotal(int total) |
void |
setDeploymentTitle(String title) |
void |
setDomain(String domain) |
void |
setGzipEnabled(boolean gzip) |
void |
setIncludeIpAddressInValidationFactors(boolean includeIpAddressInValidationFactors) |
void |
setNotificationEmail(String notificationEmail) |
void |
setProperty(String name,
String value)
Sets an arbitrary property.
|
void |
setSecureCookie(boolean secure) |
void |
setSessionTime(long time) |
void |
setSMTPServer(SMTPServer server) |
void |
setSMTPTemplate(String template)
Deprecated.
|
void |
setTrustedProxyServers(String proxyServers)
Persists a String containing a list of proxy servers we trust to correctly set the X-Forwarded-For flag.
|
void |
setUseWebAvatars(boolean useWebAvatars) |
void |
setUsingDatabaseTokenStorage(boolean usingMemoryTokenStorage)
Will set a property to state that this crowd instance is using database token storage, otherwise assume we are using in-memory
|
public PropertyManagerGeneric(PropertyDAO propertyDAO, com.atlassian.event.api.EventPublisher eventPublisher)
public String getDeploymentTitle() throws PropertyManagerException
getDeploymentTitle in interface PropertyManagerPropertyManagerException - property does not exist.public void setDeploymentTitle(String title)
setDeploymentTitle in interface PropertyManagertitle - deployment title.public String getDomain()
PropertyManagergetDomain in interface PropertyManagerpublic void setDomain(String domain)
setDomain in interface PropertyManagerdomain - SSO cookie domain.public boolean isSecureCookie()
isSecureCookie in interface PropertyManagertrue if the "secure" flag should be set on the SSO cookie.public void setSecureCookie(boolean secure)
setSecureCookie in interface PropertyManagersecure - true if the "secure" flag should be set on the SSO cookie.public void setCacheEnabled(boolean enabled)
setCacheEnabled in interface PropertyManagerenabled - true if application authorisation caching should be used on the server-side.public boolean isCacheEnabled()
isCacheEnabled in interface PropertyManagertrue if application authorisation caching is used on the server-side.public long getSessionTime()
getSessionTime in interface PropertyManagerpublic void setSessionTime(long time)
setSessionTime in interface PropertyManagertime - number of minutes the session is valid.public SMTPServer getSMTPServer() throws PropertyManagerException
getSMTPServer in interface PropertyManagerPropertyManagerException - property does not exist.public void setSMTPServer(SMTPServer server)
setSMTPServer in interface PropertyManagerserver - SMTP server config.public Key getDesEncryptionKey() throws PropertyManagerException
getDesEncryptionKey in interface PropertyManagerPropertyManagerException - property does not exist.public void generateDesEncryptionKey()
throws PropertyManagerException
PropertyManagergenerateDesEncryptionKey in interface PropertyManagerPropertyManagerException - DES algorithm does not exist.@Deprecated public void setSMTPTemplate(String template)
setSMTPTemplate in interface PropertyManagertemplate - mail template.@Deprecated public String getSMTPTemplate() throws PropertyManagerException
getSMTPTemplate in interface PropertyManagerPropertyManagerException - property does not exist.public void setCurrentLicenseResourceTotal(int total)
setCurrentLicenseResourceTotal in interface PropertyManagertotal - license resource total.public int getCurrentLicenseResourceTotal()
getCurrentLicenseResourceTotal in interface PropertyManagerpublic void setNotificationEmail(String notificationEmail)
setNotificationEmail in interface PropertyManagernotificationEmail - notification email.public String getNotificationEmail() throws PropertyManagerException
getNotificationEmail in interface PropertyManagerPropertyManagerException - property does not exist.public boolean isGzipEnabled()
throws PropertyManagerException
isGzipEnabled in interface PropertyManagertrue if GZip compression should be used.PropertyManagerException - property does not exist.public void setGzipEnabled(boolean gzip)
setGzipEnabled in interface PropertyManagergzip - true if GZip compression should be used.public Integer getBuildNumber() throws PropertyManagerException
PropertyManagerBuildUtils.BUILD_NUMBER since this number is for the
current release of Crowd, while the number in the database may still be set to a previous version if the UpgradeManager
has not been run.getBuildNumber in interface PropertyManagerPropertyManagerException - if we fail to find the buildNumberpublic void setBuildNumber(Integer buildNumber)
PropertyManagersetBuildNumber in interface PropertyManagerbuildNumber - the buildNumber to set in the databasepublic String getTrustedProxyServers() throws PropertyManagerException
TrustedProxyManagerImpl.getTrustedProxyServers in interface PropertyManagerPropertyManagerException - If the list of proxy servers could not be found.public void setTrustedProxyServers(String proxyServers)
TrustedProxyManagerImpl.setTrustedProxyServers in interface PropertyManagerproxyServers - proxy servers.org.springframework.dao.DataAccessException - If the list of proxy servers could not be saved.public void setAuditLogConfiguration(AuditLogConfiguration newConfiguration)
PropertyManagersetAuditLogConfiguration in interface PropertyManagernewConfiguration - new configurationpublic AuditLogConfiguration getAuditLogConfiguration()
PropertyManagergetAuditLogConfiguration in interface PropertyManagerpublic boolean isUsingDatabaseTokenStorage()
PropertyManagerToken's
otherwise assume we are using in-memoryisUsingDatabaseTokenStorage in interface PropertyManagerpublic void setUsingDatabaseTokenStorage(boolean usingMemoryTokenStorage)
PropertyManagersetUsingDatabaseTokenStorage in interface PropertyManagerusingMemoryTokenStorage - true if you are switching to in-memory token storagepublic boolean isIncludeIpAddressInValidationFactors()
PropertyManagerisIncludeIpAddressInValidationFactors in interface PropertyManagerpublic boolean isUseWebAvatars()
PropertyManagerisUseWebAvatars in interface PropertyManagerpublic void setUseWebAvatars(boolean useWebAvatars)
setUseWebAvatars in interface PropertyManagerpublic CookieConfiguration getCookieConfiguration()
getCookieConfiguration in interface PropertyManagerpublic void setCookieConfiguration(CookieConfiguration cookieConfiguration)
PropertyManagersetCookieConfiguration in interface PropertyManagercookieConfiguration - the configuration to set, will replace the existing configurationpublic void setIncludeIpAddressInValidationFactors(boolean includeIpAddressInValidationFactors)
setIncludeIpAddressInValidationFactors in interface PropertyManagerpublic void removeProperty(String name)
PropertyManagerremoveProperty in interface PropertyManagername - the name of the property.protected Property getPropertyObject(String name) throws ObjectNotFoundException
ObjectNotFoundExceptionpublic String getProperty(String name) throws ObjectNotFoundException
PropertyManagergetProperty in interface PropertyManagername - name of property.ObjectNotFoundException - property does not exist.public void setProperty(String name, String value)
PropertyManagersetProperty in interface PropertyManagername - name of property.value - value.public String getString(String property, String defaultValue)
PropertyManagergetString in interface PropertyManagerproperty - a property namedefaultValue - the default value to use if the property does not existpublic boolean getBoolean(String property, boolean defaultValue)
PropertyManagergetBoolean in interface PropertyManagerproperty - a property namedefaultValue - the default value to use if the property does not existpublic int getInt(String property, int defaultValue)
PropertyManagergetInt in interface PropertyManagerproperty - a property namedefaultValue - the default value to use if the property does not exist or is invalidpublic void setBaseUrl(URI url)
PropertyManagersetBaseUrl in interface PropertyManagerurl - the base url to set, should be a proper absolute URLpublic URI getBaseUrl() throws PropertyManagerException
getBaseUrl in interface PropertyManagerPropertyManagerException - if the property is not configured correctlyApplicationProperties.getBaseUrl(com.atlassian.sal.api.UrlMode)Copyright © 2018 Atlassian. All rights reserved.