Universal Cache User Guide : Setting up caching : Setting up caching with Management Console
  
Setting up caching with Management Console
The IBM InfoSphere CDC Management Console is an interactive GUI tool that you can use to configure and monitor replication (caching) subscriptions between the cache and backend databases. This section provides a high-level overview of how you can create replication subscriptions for Universal Cache purposes. The steps contain references to more detailed instructions in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
Before you begin
Check that the tables you intend to replicate exist at least in the backend database. It is also possible to create tables during the replication if the tables do not contain foreign keys.
Check that your solidDB® and backend databases are running.
Check that your IBM InfoSphere CDC instances for solidDB® and backend data servers are running.
Check that you have sufficient access privileges to your databases.
Check that you have defined your desired replication principles in accordance with your business rules. For details, see Deciding on the replication model.
If you intend to use bidirectional replication and your backend data server is DB2 for Linux, UNIX, and Windows, set the IBM InfoSphere CDC for DB2 system parameter ddl_awareness to false.
Procedure
1 Log in to Management Console by connecting to Access Server.
For more details, see “Logging into Management Console (Connecting to Access Server)” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
To be able to work in the Access Manager perspective of the Management Console, you must be a System Administrator that has the privilege to manage datastores and user accounts. The System Administrator account was created during the installation of the Management Console.
2 Set up datastores for the solidDB® and backend databases.
Add new datastore for the solidDB® database.
Click Access Manager > Datastore Management.
Click File > Access Server > New Datastore.
Type the name of the datastore in the Name box.
Type a description in the Description box.
In the Host Name box, type the host name or the full IP address of the server where you have installed IBM InfoSphere CDC for solidDB®.
In the Port box, type the port number which IBM InfoSphere CDC uses for communication with the other components. For example, IBM InfoSphere CDC for solidDB® uses by default port number 11101.
Ping the server. If successful, this returns the datastore properties including the type of server where you have installed IBM InfoSphere CDC and the version number of the product.
Add new datastore for the backend database.
Click Access Manager > Datastore Management.
Click File > Access Server > New Datastore.
Type the name of the datastore in the Name box.
Type a description in the Description box.
In the Host Name box, type the host name or the full IP address of the server where you have installed IBM InfoSphere CDC.
In the Port box, type the port number which IBM InfoSphere CDC uses for communication with the other components. For example, IBM InfoSphere CDC for Informix uses by default port number 10901.
Ping the server. If successful, this returns the datastore properties including the type of server where you have installed IBM InfoSphere CDC and the version number of the product.
Assign users to the datastores. You need to assign the same users to both the solidDB® datastore and the backend datastore.
Click Access Manager > Datastore Management.
Select a datastore.
Right-click and select Assign User.
Select a user or hold Ctrl to select multiple users.
Review the connection parameters. Click OK to accept the default connection parameters on the datastore or modify the parameters for the selected users.
For detailed instructions, see “Setting up datastores in the IBM InfoSphere Change Data Capture Management Console” in the Administration Guide.
3 Optional: Set system parameters on the solidDB® and backend datastores.
For a summary of Universal Cache specific system parameters, seeImportant IBM InfoSphere CDC system parameter settings for Universal Cache.
For detailed instructions on how to set system parameters, see “Setting system parameters on source and target datastores” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
4 Set up subscriptions.
For detailed instructions on how to set up subscriptions using Management Console, see “Setting up subscriptions” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
As an example, the following steps describe how to create subscriptions for bidirectional replication environment.
Create a new backend-to-solidDB® subscription.
Click Configuration > Subscriptions.
Right-click anywhere in the Subscriptions field and select New Subscription.
Type the name of the new backend-to-solidDB® subscription in the Name box.
Type the description of the new subscription in the Description box.
Select the backend datastore from the Source list.
Select the solidDB® datastore from the Target list.
Click OK.
Create a new solidDB®-to-backend subscription.
Click Configuration > Subscriptions.
Right-click anywhere in the Subscriptions field and select New Subscription.
Type the name of the new solidDB®-to-backend subscription in the Name box.
Type the description of the new subscription in the Description box.
Select the solidDB® datastore from the Source list.
Select the backend datastore from the Target list.
Click OK.
5 Map tables for replication in all subscriptions. This procedure assumes the
backend data server contains the tables you want to cache into the solidDB® database.
Click Configuration > Subscriptions.
Select the backend-to-solidDB® subscription, right-click and select Map Tables.
Select Multiple One-to-One Mappings and click Next.
Expand the database, schema, or table from the Source Tables list to view
tables from your database that are available for mapping. Right-click the database user or schema and click Refresh if you do not see your table listed.
Enable one or more tables to map from the Source Tables list, and then click Next.
Click Create new target tables, and then click Next.
Specify a target owner for each source owner.
Specify how the new target table names relate to their corresponding source table names, and then click Next.
Set the replication method to Mirror (Change Data Capture).
Verify the mappings in the Complete Mappings dialog, and click Next.
Review the mapping summary and click Finish.
For detailed instructions, see “Mapping tables” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
6 Optional: For each table mapping, set conflict detection and resolution in accordance with your business rules.
Click Configuration > Subscriptions.
Select the subscription.
Click the Table Mappings view and select the table mapping from the Source Table column.
Right-click and select Open Details....
Click the Conflicts tab.
Select the columns on which you want to detect conflicts.
Select the conflict resolution from the Conflict Resolution Method list.
Click Save.
For detailed instructions, see “Setting conflict detection and resolution” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
7 Optional: Set character set conversions for source columns.
If your solidDB® database mode is Unicode (General.InternalCharEncoding=UTF8), set the encoding of character data type columns (CHAR, VARCHAR, and so on) to UTF-8.
8 Start replication on subscriptions. To start caching, start continuous mirroring on the subscriptions you have created.
Click Monitoring > Subscriptions.
Right-click on the two subscriptions and select Start Mirroring.
Select Continuous and click OK to start mirroring.
For detailed instructions, see “Starting and ending replication on subscriptions” in the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
Results
You have set up, for example, bidirectional replication subscriptions between the backend and solidDB® databases. As you make changes in either database, IBM InfoSphere CDC replication mechanism takes care of replicating the changes to the other database.
For example, you can use solidDB® SQL Editor (solsql) to issue SQL statements in the solidDB® server. The IBM InfoSphere CDC components will then take care of replicating the changes to the backend database.
What to do next
For general instructions on how to administer the datastores and subscriptions, see the IBM InfoSphere Change Data Capture Management Console, Administration Guide.
For instructions on Universal Cache specific settings and administration tasks, see Universal-Cache-specific settings and tasks for IBM InfoSphere CDC.
For solidDB®-specific instructions on how to optimize and monitor the performance of solidDB® Universal Cache, see Performance tuning and monitoring.
See also
Key concepts for setting up caching with Management Console
Setting up caching