CMS Database Configuration

Database configuration is stored in two files

{installation root}\jetty\base\etc\perc-ds.xml

{installation root}\jetty\base\etc\perc-ds.properties

The XML contains the main configuration that CM1 uses to connect to databases called a datasource, this is equivalent to the AppServer\server\rx\deploy\rx-ds.xml file in previous versions.  This contains multiple blocks of xml that start with the following where {x} is an index starting from 1.  There should always be one such block for the main repository, but others may have been created when configuring a Database Delivery server.  Each block uses a number of properties that are prefixed with perc.ds.{x}  these refer to values that can be set in the perc-ds.properties file.  Normally the xml file should not be modified unless requested by support  to manually remove or add a database connection, or to modify a setting not available in the properties file.  Each block can usually be the same other than the index value used.

<New class="org.eclipse.jetty.plus.jndi.Resource" id="perc.ds.{x}">
 
perc-ds.properties
 
This file contains the configuration for datasources and connections.
 
A datasource represents connection to a database server and a driver
 
 
perc.ds.1.connections.min=5
perc.ds.1.driver.class=org.apache.derby.jdbc.EmbeddedDriver
perc.ds.1.driver.name=derby
perc.ds.1.idle.ms=900000
perc.ds.1.name=jdbc/RhythmyxData
perc.ds.1.pwd=7cf3be70d83a6948
perc.ds.1.pwd.encrypted=Y
perc.ds.1.server=CMDB
perc.ds.1.uid=CMDB
If a password is specified as plain text and and the perc.ds.{x}.pwd.encrypted does not equal Y or does not exist then the password will be encrypted on first startup and the encrypted flag will be set.
datasource min and max values define how many database connections will be available in the pool.  The database server must have enough resources to handle the number of connections along with any other services that are accessing it.  idle.ms defines how long a connection in the pool should wait before being released.
A connection is what CM1 uses to provide all the details it needs to find the tables it requires.  A connection points to a specific datasource, and also defines the database schema to use.  This way it is possible to have multiple connections pointing to a single datasource.  One connection is labled the default which will point to the core CM1 tables.  Other connections could be used for database publishing or accessing other external custom data. The connection specifies the datasource by name e.g. perc.conn.1.ds.  This information used be be stored in AppServer/server/rx/deploy/rxapp.ear\rxapp.war\WEB-INF\config\spring\server-beans.xml in a bean with id sys_datasourceResolver, now the datasources and connection configuration are stored in the same file.
 
perc.conn.1.db=
perc.conn.1.default=Y
perc.conn.1.ds=jdbc/RhythmyxData
perc.conn.1.name=RhythmyxData
perc.conn.1.schema=CMDB