-
Language:
English
-
Language:
English
4.5. Deploy Web Applications on WebLogic Server (Remote Client-Server Mode)
Red Hat JBoss Data Grid supports the WebLogic 12c application server in Remote Client-Server mode. The following procedure describes how to deploy web applications on a WebLogic server.
Procedure 4.2. Deploying Web Applications on a WebLogic Server
- To install the WebLogic server, see http://docs.oracle.com/cd/E24329_01/doc.1211/e24492/toc.htm.
- Configure JBoss Data Grid in Remote Client-Server mode, define cache, cache container, and endpoint configuration. After configuration, start JBoss Data Grid to confirm that the Hot Rod endpoint is listening on the configured port. For information about configuring JBoss Data Grid in Remote Client-Server, see Chapter 6, Run Red Hat JBoss Data Grid in Remote Client-Server Mode.
- Create a web application and add the
infinispan-client-hotrod
library as a dependency if Maven is used. - Create a
weblogic.xml
deployment descriptor with the following elements in it:<?xml version="1.0" encoding="UTF-8"?> <weblogic-web-app xmlns="http://www.bea.com/ns/weblogic/90" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.bea.com/ns/weblogic/90 http://www.bea.com/ns/weblogic/90/weblogic-web-app.xsd"> <container-descriptor> <prefer-web-inf-classes>true</prefer-web-inf-classes> </container-descriptor> </weblogic-web-app>
Note
Theprefer-web-inf-classes
class indicates that the libraries and classes in theWEB-INF/lib
folder are preferred over the default libraries bundled in the WebLogic server. For example, thecommons-pool.jar
file in the WebLogic server has version 1.4 and is automatically loaded by the classloader, however the Hot Rod client uses a newer version of this library. - Add deployment descriptor file in the
WEB-INF
folder. - Ensure that the
infinispan-client-hotrod
dependency is added to thepom.xml
file, then use a Maven plugin to create a web archive. These dependencies ensure that the required libraries (infinispan-commons
,infinispan-client-hotrod
,commons-pool
,jboss-logging
, andjboss-marshalling-osgi
) are included.Alternatively, create the web archive manually and add all the required libraries. - Deploy the application in the WebLogic server and verify that the Hot Rod client embedded inside the web application connects to the remote JBoss Data Grid server.