Class AbstractDatabaseConnectionDecorator

java.lang.Object
com.atlassian.crowd.config.AbstractDatabaseConnectionDecorator
All Implemented Interfaces:
DatabaseConnectionDecorator
Direct Known Subclasses:
MySQLConnectionDecorator, NoOpConnectionDecorator, OracleConnectionDecorator, PostgreSQLConnectionDecorator

public abstract class AbstractDatabaseConnectionDecorator extends Object implements DatabaseConnectionDecorator
  • Constructor Details

    • AbstractDatabaseConnectionDecorator

      public AbstractDatabaseConnectionDecorator(Map<String,String> decoratingParameters)
  • Method Details

    • getConnectionParameters

      public Map<String,String> getConnectionParameters()
      This method returns the parameters which are to be used for decorating the connection
    • decorateConnectionProperties

      public void decorateConnectionProperties(com.atlassian.config.ApplicationConfiguration applicationConfig)
      It updates the application config, by decorating the connection url or hibernate connection properties whichever supported by underlying implementation
      Specified by:
      decorateConnectionProperties in interface DatabaseConnectionDecorator
    • decorateConnectionURL

      public String decorateConnectionURL(String connectionURL)
      This method decorates the given connection URL with the parameters supplied by getConnectionParameters(), to note it will not override the parameters already present in the connection url
      Specified by:
      decorateConnectionURL in interface DatabaseConnectionDecorator
      Returns:
      the decorated connection URL
    • prepareMessageWithParams

      protected String prepareMessageWithParams(Map<String,String> params)