If you want to configure the queue manager so that updates to multiple databases can be included within global units of work, add a set of resource manager configuration information for each database.
If the databases are all managed by the same database manager, each set of configuration information defines a separate database belonging to that database manager. Each set must specify the same SwitchFile, but the contents of the XAOpenString will be different because it specifies the name of the database being updated. For example, the stanzas shown in Figure 23 configure the queue manager with the DB2 databases MQBankDB and MQFeeDB on UNIX platforms.
Figure 23. Sample XAResourceManager entries for multiple DB2 databases
XAResourceManager: Name=DB2 MQBankDB SwitchFile=/usr/bin/db2swit XAOpenString=MQBankDB XAResourceManager: Name=DB2 MQFeeDB SwitchFile=/usr/bin/db2swit XAOpenString=MQFeeDB |
If the databases to be updated are managed by different database managers, add a set of resource manager configuration information for each. In this case, each set specifies a different SwitchFile. For example, if MQFeeDB is managed by Oracle instead of DB2, use the following configuration information:
Figure 24. Sample XAResourceManager entries for a DB2 and Oracle database
XAResourceManager:
Name=DB2 MQBankDB
SwitchFile=/usr/bin/db2swit
XAOpenString=MQBankDB
XAResourceManager:
Name=Oracle MQFeeDB
SwitchFile=/usr/bin/oraswit
XAOpenString=Oracle_XA+Acc=P/scott/tiger+SesTm=35
+LogDir=/tmp/ora.log+DB=MQFeeDB
|
In principle, there is no limit to the number of database instances that can be configured with a single queue manager.