Communities
|
Social Applications
Networks
Support
|
|
C-Level Executives
Other Roles
|
|
Support
Education
Partner
Other Tasks
|
Articles
Architect: SOA
Hands-on Guide: Creating an Oracle Service Registry 11g High-Availability Setup on Oracle WebLogic Server 11gby Yogesh Sontakke Published May 2010 This guide provides step-by-step instructions for creating an active-active high-availability (HA) setup for Oracle Service Registry 11g in an Oracle WebLogic Server cluster environment. Prerequisites
OverviewFigure 1 depicts the HA architecture this article discusses:
Figure 1
Here are the steps involved:
Create the Oracle WebLogic Server Environment: Domain, Servers, and ClusterFigure 2 and Table 1 show the Oracle WebLogic Server setup we will be creating:
Figure 2: The Oracle Service Registry setup includes an admin server and several managed servers.
Creating the Oracle WebLogic Server environment for our Oracle Service Registry HA setup involves the following steps. Further detailed instructions on Oracle WebLogic Server administration are available here.
Start your newly created admin server, and go to the Admin Console by using the following URL: http://<hostname>:7001/console Log in, using the username/password you provided. Go to Servers and/or Clusters, where you should see the following overview of the Oracle WebLogic Server environment you just created (Figure 6):
Figure 6
Create an Oracle Service Registry Application for the ClusterHere we create the Oracle Service Registry application (Web archive [WAR] file) we'll deploy to the Oracle WebLogic Server cluster later. For detailed instructions on installing Oracle Service Registry, see the Installation Guide, which is a part of the registry.pdf that comes with the Oracle Service Registry installable.
When you have completed the installation successfully, registry.war should be created under $MIDDLEWARE_HOME/osr_ha_home/conf/porting/weblogic/build. Deploy the Oracle Service Registry Application to the Clustered NodesNow that we have the Oracle Service Registry application ( registry.war) ready, we can proceed to deploy it to the Oracle Service Registry HA nodes:
The Oracle Service Registry application is now deployed to both of the Oracle Service Registry HA nodes: osr_ha_nodeA and osr_ha_nodeB. Simulate a Load Balancer Using Oracle WebLogic Server's Built-in HTTPClusterServletIn this step, we simulate a load balancer by using the HTTPClusterServlet. The servlet is already available in Oracle WebLogic Server, but we need to configure the descriptor files for this servlet and tell it about the existence of our two Oracle Service Registry HA nodes. Also, we need to copy some of the user interface information of Oracle Service Registry to the load balancer application. Finally, we have a load balancer application ( balancer.war), which we deploy to the managed server osr_ha_lbr. Create the directory structure for the balancer application
Figure 12
To create the directory structure:
Create the load balancer's Web configuration file. To create the Web configuration file, open a simple text editor such as Notepad and create $MIDDLEWARE_HOME\osr_ha_home\balancer\WEB-INF\web.xml with this content:
<web-app>
<servlet>
<servlet-name>HttpClusterServlet</servlet-name>
<servlet-class>weblogic.servlet.proxy.HttpClusterServlet</servlet-class>
<init-param>
<param-name>WebLogicCluster</param-name>
<param-value><your_hostname>:17101|<yourhostname>:27101</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>FileServlet</servlet-name>
<servlet-class>weblogic.servlet.FileServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>FileServlet</servlet-name>
<url-pattern>registry/uddi/bsc/webdata*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>FileServlet</servlet-name>
<url-pattern>registry/uddi/webdata*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>FileServlet</servlet-name>
<url-pattern>registry/uddi/doc*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>HttpClusterServlet</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
</web-app>
Create the registry context file <weblogic-web-app> <context-root>/registry</context-root> </weblogic-web-app> Copy registry user interface information to the balancer
Figure 13
Your directory structure should now look like this (Figure 14):
Figure 14
Create the load balancer package To create the load balancer package (balancer.war ), open a command prompt, browse to $MIDDLEWARE_HOME\osr_ha_home\balancer, and run the following: jar cvf balancer.war *.* Deploy load balancer to the osr_ha_lbr managed server
Test the Newly Created Oracle Service Registry HA EnvironmentTo test that the load balancing in your new Oracle Service Registry HA environment works:
You have now successfully created a highly available Oracle Service Registry 11g active-active environment on Oracle WebLogic Server 11g. Yogesh Sontakke is a Principal Engineer in the Oracle Java Technologies Team, specialising in Oracle's SOA Web Services stack which includes Web Services Architecture, WS-Security, Oracle Web Services Manager and Oracle Service Registry. He has over 10 years of technology experience in the Java/J2EE world in Design, Development, Consulting, Support and Pre-Sales. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
