Multi data source (MDS) for RAC connectivity has been supported in WebLogic Server since 2005. As the popularity of Oracle RAC has grown, so has the use of MDS. Now with the introduction of Active GridLink (AGL) in early 2011, users of MDS want to migrate to AGL. There is not an automated mechanism to do so but it’s not the difficult.
First, no changes should be required to your applications. A standard application looks up the MDS in JNDI and uses it to get connections. By giving the AGL the same JNDI name as the MDS, the process is exactly the same in the application to use a data source name from JNDI.
The only changes necessary should be to your configuration. AGL is composed of information from the MDS and the member generic data sources, combined into a single AGL descriptor. The only additional information that is needed is the configuration of Oracle Notification Service (ONS) on the RAC cluster. In many cases, the ONS information will consist of the same host names as used in the MDS and the only additional information is the port number, and that can be simplified by the use of a SCAN address.
The MDS descriptor doesn’t have much information in it. It has a list of the member generic datasources, which will help you figure out where to get the remaining information that you need. It has a JNDI name, which must become the name of your new AGL to keep things transparent to the application. If you want to run the MDS in parallel with the AGL, then you will need to give the AGL a new name but the application must also be changed to use a new JNDI name. You don’t need to worry about the algorithm type.
Each of the member generic datasources will have its own URL. As described in Appendix B Using Multi Data Sources with Oracle RAC , it will look like the following.
Each member should have its own host and port pair. They will likely have the same service and often have the same port on different hosts. The URL for the AGL is a combination of the host and port pairs.
It is preferable to use an Oracle Single Client Access Name (SCAN) address instead of multiple host or Virtual IP (VIP) addresses. Then the URL would look something like this.
It’s a lot simpler and makes changes to the nodes in the cluster transparent. This section isn’t intended to be a complete guide to writing Oracle URL’s – see the Oracle RAC Administration Guide.
Assuming that you will replace the MDS with the AGL, you will need to delete the MDS and the generic data sources from the configuration using the administration console and add a single AGL data source. The process is described earlier in this chapter. Give it the same JNDI name as your MDS had. Select whether your generic data sources used an XA or non-XA driver. You can enter the complete URL as described above. The user and password should be the same as what you had on one (hopefully all) of the MDS members. When you get to the “Test GridLink Datasource Connection” page, click on the “Test All Listeners” button to see that you specified the new URL correctly. The next page is where you need the new information for the ONS connections. Specify one or more host:port pairs. For example, “host1-vip:6200” or “scanaddress:6200”. If possible, use a single SCAN address and port. Make sure that FAN enabled is checked. On the next page, test the ONS connections. Finally, you are ready to deploy the data source.
There are many data source parameters that you can’t configure on the creation flow. You need to go back and edit the AGL data source configuration. The parameters that you set should generally be based on the parameters that you were using in the MDS member data sources. Hopefully they were all the same; if not, you need to decide what the right values are.