public interface IDBSubsystem extends ISubsystem
This interface separate the database subsystem functionalities from internal implementation.
Modifier and Type | Field and Description |
---|---|
static int |
CERTS |
static int |
NUM_REPOS |
static int |
REPLICA_ID |
static int |
REQUESTS |
static java.lang.String |
SUB_ID |
Modifier and Type | Method and Description |
---|---|
IDBSSession |
createSession()
Creates a database session.
|
boolean |
enableSerialNumberRecovery()
Avoids losing serial number.
|
java.lang.String |
getBaseDN()
Retrieves the base DN.
|
IConfigStore |
getConfigStore()
Gets internal DB configuration store
|
IConfigStore |
getDBConfigStore()
Gets DB subsystem configuration store
|
boolean |
getEnableSerialMgmt()
Determines if serial number management has been enabled
|
java.lang.String |
getEntryAttribute(java.lang.String dn,
java.lang.String attrName,
java.lang.String defaultValue,
java.lang.String errorValue)
Gets attribute value for specified entry
|
java.lang.String |
getIncrementConfig(int repo)
Gets range increment limit for next range in config file
|
java.lang.String |
getLowWaterMarkConfig(int repo)
Gets low water mark limit in config file
|
java.lang.String |
getMaxSerialConfig(int repo)
Gets the maximum serial number limit in config file
|
java.lang.String |
getMinSerialConfig(int repo)
Gets minimum serial number limit in config file
|
java.lang.String |
getNextMaxSerialConfig(int repo)
Gets the maximum serial number limit for next range in config file
|
java.lang.String |
getNextMinSerialConfig(int repo)
Gets minimum serial number limit for next range in config file
|
java.lang.String |
getNextRange(int repo)
Gets number corresponding to start of next range from database
|
java.math.BigInteger |
getNextSerialConfig()
Gets the next serial number in config file
|
IDBRegistry |
getRegistry()
Retrieves the registry.
|
boolean |
hasRangeConflict(int repo)
Determines if a range conflict has been observed in database
|
void |
returnConn(netscape.ldap.LDAPConnection conn)
Returns LDAP connection to connection pool.
|
void |
setEnableSerialMgmt(boolean value)
Sets whether serial number management is enabled for certs
and requests.
|
void |
setMaxSerialConfig(int repo,
java.lang.String serial)
Records maximum serial number limit in config file
|
void |
setMinSerialConfig(int repo,
java.lang.String serial)
Records minimum serial number limit in config file
|
void |
setNextMaxSerialConfig(int repo,
java.lang.String serial)
Records maximum serial number limit for the next range in config file
|
void |
setNextMinSerialConfig(int repo,
java.lang.String serial)
Records minimum serial number limit for the next range in config file
|
void |
setNextSerialConfig(java.math.BigInteger serial)
Records next serial number in config file
|
static final java.lang.String SUB_ID
static final int CERTS
static final int REQUESTS
static final int REPLICA_ID
static final int NUM_REPOS
java.lang.String getBaseDN()
IDBRegistry getRegistry()
IDBSSession createSession() throws EDBException
EDBException
- failed to create sessionboolean enableSerialNumberRecovery()
void setNextSerialConfig(java.math.BigInteger serial) throws EBaseException
serial
- next serial numberEBaseException
- failed to setjava.math.BigInteger getNextSerialConfig()
void setMaxSerialConfig(int repo, java.lang.String serial) throws EBaseException
serial
- max serial numberrepo
- repo identifierEBaseException
- failed to setvoid setMinSerialConfig(int repo, java.lang.String serial) throws EBaseException
serial
- min serial numberrepo
- repo identifierEBaseException
- failed to setvoid setNextMaxSerialConfig(int repo, java.lang.String serial) throws EBaseException
serial
- max serial numberrepo
- repo identifierEBaseException
- failed to setvoid setNextMinSerialConfig(int repo, java.lang.String serial) throws EBaseException
serial
- min serial numberrepo
- repo identifierEBaseException
- failed to setjava.lang.String getMinSerialConfig(int repo)
repo
- repo identifierjava.lang.String getMaxSerialConfig(int repo)
repo
- repo identifierjava.lang.String getNextMaxSerialConfig(int repo)
repo
- repo identifierjava.lang.String getNextMinSerialConfig(int repo)
repo
- repo identifierjava.lang.String getLowWaterMarkConfig(int repo)
repo
- repo identifierjava.lang.String getIncrementConfig(int repo)
repo
- repo identifierjava.lang.String getNextRange(int repo)
repo
- repo identifierboolean hasRangeConflict(int repo)
repo
- repo identifierboolean getEnableSerialMgmt()
void setEnableSerialMgmt(boolean value) throws EBaseException
value
- true/falseEBaseException
- failed to setIConfigStore getConfigStore()
getConfigStore
in interface ISubsystem
IConfigStore getDBConfigStore()
java.lang.String getEntryAttribute(java.lang.String dn, java.lang.String attrName, java.lang.String defaultValue, java.lang.String errorValue)
dn
- entry's distinguished nameattrName
- attribute's namedefaultValue
- attribute's default valueerrorValue
- attribute's error valuevoid returnConn(netscape.ldap.LDAPConnection conn)
conn
- connection to be returned