<?xml version="1.0"?>
<instances>

        <!-- This instance maintains connections to an Oracle database. -->
        <instance id="oracle" socket="/tmp/oracle.socket" dbase="oracle">
                <users>
                        <user user="oracleuser" password="oraclepassword"/>
                </users>
                <connections>
                        <connection string="user=scott;password=tiger;oracle_sid=orcl"/>
                </connections>
        </instance>


        <!-- This instance maintains connections to an SAP database. -->
        <instance id="sap" socket="/tmp/sap.socket" dbase="sap">
                <users>
                        <user user="sapuser" password="sappassword"/>
                </users>
                <connections>
                        <connection string="sybase=/opt/sap;lang=en_US;server=TESTDB;user=testuser;password=testpassword;db=testdb;"/>
                </connections>
        </instance>


        <!-- This instance sends one set of users to the Oracle database and
                all other users to the sap database. -->
        <instance id="router" dbase="router">
                <users>
                        <user user="oracleuser1" password="oraclepassword"/>
                        <user user="oracleuser2" password="oraclepassword"/>
                        <user user="oracleuser3" password="oraclepassword"/>
                        <user user="oracleuser4" password="oraclepassword"/>
                        <user user="sapuser1" password="sappassword"/>
                        <user user="sapuser2" password="sappassword"/>
                        <user user="sapuser3" password="sappassword"/>
                        <user user="sapuser4" password="sappassword"/>
                </users>
		<routers>
			<router module="userlist" connectionid="oracle">
				<user user="oracleuser1"/>
				<user user="oracleuser2"/>
				<user user="oracleuser3"/>
				<user user="oracleuser4"/>
			</router>
			<router module="userlist" connectionid="sap">
				<user user="*"/>
			</router>
		</routers>
		<connections>
			<connection connectionid="oracle" string="socket=/tmp/oracle.socket;user=oracleuser;password=oraclepassword"/>
			<connection connectionid="sap" string="socket=/tmp/sap.socket;user=sapuser;password=sappassword"/>
		</connections>
		<notifications>
			<notification module="events">
				<events>
					<event event="integrity_violation"/>
				</events>
				<recipients>
					<recipient address="dba@firstworks.com"/>
				</recipients>
			</notification>
		</notifications>
        </instance>

</instances>
