Class DBSubsystem

java.lang.Object
com.netscape.cmscore.dbs.DBSubsystem

public class DBSubsystem extends Object
A class represents the database subsystem that manages the backend data storage. This subsystem maintains multiple sessions that allows operations to be performed, and provide a registry where all the schema information is stored.
Author:
thomask
  • Field Details

  • Constructor Details

    • DBSubsystem

      public DBSubsystem()
      Constructs database subsystem.
  • Method Details

    • getEngineConfig

      public EngineConfig getEngineConfig()
    • setEngineConfig

      public void setEngineConfig(EngineConfig engineConfig)
    • getId

      public String getId()
      Retrieves subsystem identifier.
    • setId

      public void setId(String id) throws EBaseException
      Sets subsystem identifier.
      Throws:
      EBaseException
    • getSocketFactory

      public netscape.ldap.LDAPSocketFactory getSocketFactory()
    • setSocketFactory

      public void setSocketFactory(netscape.ldap.LDAPSocketFactory socketFactory)
    • enableSerialNumberRecovery

      public boolean enableSerialNumberRecovery()
    • getEnableSerialMgmt

      public boolean getEnableSerialMgmt()
    • setEnableSerialMgmt

      public void setEnableSerialMgmt(boolean v) throws EBaseException
      Throws:
      EBaseException
    • setNextSerialConfig

      public void setNextSerialConfig(BigInteger serial) throws EBaseException
      Throws:
      EBaseException
    • getExcludedLdapAttr

      public Set<String> getExcludedLdapAttr()
    • configureExcludedLdapAttrs

      public void configureExcludedLdapAttrs() throws EBaseException
      Configure LDAP attributes that need to be excluded from enrollment records. Default config: excludedLdapAttrs.enabled=false; (excludedLdapAttrs.attrs unspecified to take default)
      Throws:
      EBaseException
    • init

      public void init(DatabaseConfig dbConfig, LDAPConfig ldapConfig, PasswordStore passwordStore) throws EBaseException
      Initializes the internal registry. Connects to the data source, and create a pool of connection of which applications can use. Optionally, check the integrity of the database.
      Throws:
      EBaseException
    • getEntryAttribute

      public String getEntryAttribute(String dn, String attrName, String defaultValue, String errorValue)
    • getDBConfigStore

      public DatabaseConfig getDBConfigStore()
      Retrieves DB subsystem configuration store.
    • getBaseDN

      public String getBaseDN()
      Retrieves base DN of backend database.
    • getLdapConnInfo

      public LdapConnInfo getLdapConnInfo()
      Retrieves LDAP connection info (host, port, secure)
    • getLdapAuthInfo

      public LdapAuthInfo getLdapAuthInfo()
    • shutdown

      public void shutdown()
      Shutdowns this subsystem gracefully.
    • getRegistry

      public DBRegistry getRegistry()
      Retrieves the registry.
    • createSession

      public DBSSession createSession() throws DBException
      Creates a database session.
      Throws:
      DBException
    • returnConn

      public void returnConn(netscape.ldap.LDAPConnection conn)