blob: 696851016129c2bb7a96c83b9fe28655d644e76c [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE descriptor-repository PUBLIC "-//Apache Software Foundation//DTD OJB Repository//EN" "repository.dtd">
<descriptor-repository version="1.0" isolation-level="read-uncommitted">
<!--
Define here all used connections.
One defined connection should be defined as the default one,
by set default-connection="true" - this could be done at runtime too.
It is possible to set user/password at
runtime or let login different users at runtime using the same
database. Use different PBKey with same jcdAlias name but
different user/password.
Ditto it is possible to add jdbc-connection-descriptor at runtime
using the MetadataManager.
-->
<jdbc-connection-descriptor
jcd-alias="default"
platform="Hsqldb"
jdbc-level="3.0"
driver="org.hsqldb.jdbcDriver"
protocol="jdbc"
subprotocol="hsqldb"
dbalias="hsql://localhost:9002"
username="sa"
password=""
batch-mode="false"
useAutoCommit="1"
ignoreAutoCommitExceptions="false"
>
<connection-pool
maxActive="2"
maxIdle="2"
whenExhaustedAction="2"
validationQuery="select count(*) from Department"
/>
<sequence-manager className="org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl">
<attribute attribute-name="grabSize" attribute-value="5"/>
</sequence-manager>
</jdbc-connection-descriptor>
<jdbc-connection-descriptor jcd-alias="personnel" default-connection="true">
<sequence-manager className="org.apache.ojb.broker.util.sequence.SequenceManagerHighLowImpl">
<attribute attribute-name="grabSize" attribute-value="5"/>
</sequence-manager>
</jdbc-connection-descriptor>
<class-descriptor class="org.apache.cocoon.ojb.samples.bean.Department" table="DEPARTMENT">
<field-descriptor name="id" column="ID" jdbc-type="INTEGER" primarykey="true"/>
<field-descriptor name="name" column="NAME" jdbc-type="VARCHAR"/>
</class-descriptor>
<class-descriptor class="org.apache.cocoon.ojb.samples.bean.Employee" table="EMPLOYEE">
<field-descriptor name="id" column="ID" jdbc-type="INTEGER" primarykey="true"/>
<field-descriptor name="departmentId" column="DEPARTMENT_ID" jdbc-type="INTEGER"/>
<field-descriptor name="name" column="NAME" jdbc-type="VARCHAR"/>
</class-descriptor>
</descriptor-repository>