OEPE provides support for Oracle Coherence. For more information, see the Coherence information, which is available on Oracle Technology Network at http://www.oracle.com/technetwork/middleware/coherence
.
This document contains the following sections:
This section describes how to work with Coherence facets.
Use the context menu and the properties dialog to add and configure your facets.
To configure your project for Coherence:
If you didn't add the Coherence facet when you create a project, you can add the facet to an existing project by right-clicking your project in the Project Explorer and selecting Properties from the drop-down menu. This opens the Properties dialog.
In the Properties dialog, select Project Facets on the left panel, and then select Oracle Coherence from the Project Facet list.
Click Further configuration required to open the Modify Faceted Project > Coherence dialog.
If the Coherence library is listed as a user library, proceed as follows:
Select the Coherence library from the list.
Accept default settings.
Click OK.
If you are using Oracle WebLogic Server 12c (12.1.3) runtime, Coherence might already be installed on your machine if you chose this option when you installed. In this case, the Coherence Library in Fusion Middleware Install option is available in the Library > Type list.
If the Coherence library is not listed, you need to either point to an existing installation, or download the library.
To point to an already downloaded Oracle Coherence library:
Click Manage User Library to open the Preferences > User Libraries dialog.
Select a Java user library in the form of the coherence.jar,
which represents the entire library.
Note that the Coherence JAR files reside in the \coherence\lib
directory of the Oracle Coherence installation. Also note that the same dialog allows you to fine tune your Coherence library configuration.
To obtain the Coherence library, click Download Library. This opens the Download Library dialog.
Click OK on the Modify Faceted Project > Coherence dialog.
Click Apply > OK to complete the configuration.
The Coherence launch configuration editor sets the most commonly used Coherence command line arguments.
To modify the Coherence launch configuration for your project configured with the Coherence facet:
The created Coherence XML files, such as coherence-cache-config.xml
, pof-config.xml
, and tangosol-coherence-override.xml
, reside in your project's src
directory.
OEPE provides an editor that you can use to modify the generated tangosol-coherence-override.xml
Oracle Coherence deployment descriptor.
To modify operational configuration elements defined in the tangosol-coherence-override.xml
file:
For information on Oracle Coherence operational configuration deployment descriptors and their elements, see "Operational Configuration Elements" in Developing Applications with Oracle Coherence.
OEPE provides an editor that you can use to modify the generated coherence-cache-config.xml
Oracle Coherence deployment descriptor.
To modify cache configuration elements defined in the coherence-cache-config.xml
file:
For more information on Oracle Coherence cache configuration elements, see "Cache Configuration Elements" in Oracle Coherence Developer's Guide.
This section describes how to create Coherence applications, export them, deploy them, and locate deployed Coherence applications.
With the release of WebLogic 12.1.3, Eclipse now supports the GAR (GridArchive) mechanism, a new packaging mechanism for Coherence cache configurations and classes.
You can create a new Coherence application using the Oracle Coherence Application wizard. The wizard creates a Coherence GAR project and gives you to option to add it to a J2EE EAR project.
To create a Coherence Application:
Choose File > New > Other > Oracle > Coherence > Oracle Coherence Application. The Oracle Coherence Application dialog appears.
Enter the project name. The project name is the name of the GAR project module in the application. The project name you enter here will be the name of the application. If you choose to add the project to the EAR, the EAR name will be generated based on the GAR project name.
Select your target runtime and server configuration details. The Coherence application requires that you use the Oracle WebLogic server 12.1.3.
Check to add the GAR project to the EAR. If you choose to add the GAR project module to EAR, a reference of the GAR module will be added to weblogic-application.xml
in the EAR. Adding the project to the EAR allows the GAR module access to resources defined in the EAR, as well as other J2EE modules such as WAR and EJB.
Note:
Only one GAR module can exist in an EAR project. Only Coherence configuration and classes can be included in GAR. No EJBs are allowed in GAR.
Check to add the project to working sets. Working sets help you contextually organize resources across projects. Working sets are a subset of files/classes/folders/projects and represent development workflows.
Click Next. The Java Configure project for building a Java application dialog appears. Add or edit the source path.
Click Next. The Coherence library configuration page appears. You have the option to change the Coherence library type to a user library, by specifying an Eclipse User Library containing the coherence.jar
. Specifying the user library compiles the GAR project against the user library, instead of against the JARs from the WebLogic server, or Fusion Middleware installation. You can also select which default Coherence configuration files to create. When configuration files are created as part of the GAR, files such as coherence-cache-config.xml
and pof-config.xml
are placed in the root directory. For an overview of the Coherence default configuration files, see Developing Applications with Oracle Coherence.
You can export your Coherence project as either an EAR or a GAR file using the right-click context menu.
To export a Coherence Application:
You can deploy your Coherence application to a WebLogic server directly from OEPE, or you can export the application in an EAR or GAR and then deploy it to the WebLogic server with the Admin console, WLST, and weblogic.Deployer.
To deploy a Coherence Application:
Note:
Standalone GAR projects (not part of an EAR) require changing WLS Server publishing mode to the Exploded Archive Mode, in the server properties page.