Development Lifecycle for Task Flows in Oracle WebCenter Portal Builder

Introduction This articles promotes the paper published by A-Team which steps you through the development lifecycle of a sample task flow in WebCenter Portal Builder. The document shows how to develop and test a task flow in JDeveloper, then describes how to deploy, redeploy, and use the task flow in WebCenter Portal, as well as […]

Configure Coherence for Oracle WebCenter Portal Framework Content Presenter Task Flow

This guide aims to give you complete configuration overview for how to configure Coherence Cache for Oracle WebCenter Portal Framework Application using the Content Presenter Task Flow.

This document is intended for WebCenter Portal Application administrators who have to improve performance by configuring Coherence cache for Content Presenter.

For more information about the Coherence Cache for Content Presenter have a look at the following link:

http://docs.oracle.com/cd/E21764_01/webcenter.1111/e12405/wcadm_documents.htm#BABHFCJH

Details

 

 

The Content Presenter and the Content Management Interoperability Service (CMIS) are delivered out of the box with in-memory Coherence cache. This cache is NOT enabled by default. You can enable it by adding the file content-coherence-cache-config.xml to the application class path of the WebCenter Portal Application. This guide describes how to configure the cache when you deploy applications based on WebCenter Portal Framework.

The Content Coherence Configuration file below uses the distributed cache mode in combination with local cache mode depending on the type of objects to be cached. Here the example Coherence cache file to use for the configuration:

<!DOCTYPE cache-config SYSTEM “cache-config.dtd”>
<cache-config>
  <caching-scheme-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.nodeUidCache.*</cache-name>
      <scheme-name>ContentNodeCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.nodePathToUidCache.*</cache-name>
      <scheme-name>ContentNodeCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.securityInfoCache.*</cache-name>
      <scheme-name>ContentNodeCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.typeNameCache.*</cache-name>
      <scheme-name>ContentTypeCaches</scheme-name>
    </cache-mapping>
   <cache-mapping>
      <cache-name>repo.ucm.typeNamesCache.*</cache-name>
      <scheme-name>ContentTypeCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>binaryCache.*</cache-name>
      <scheme-name>ContentBinaryCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.searchCriteriaCache.*</cache-name>
      <scheme-name>ContentSearchCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name> repo.ucm.indexedFieldsCache.*</cache-name>
      <scheme-name>ContentSearchCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.securityUserCache.*</cache-name>
      <scheme-name>ContentSecurityCaches</scheme-name>
    </cache-mapping>
    <cache-mapping>
      <cache-name>repo.ucm.profileTriggerValueCache.*</cache-name>
      <scheme-name>ContentProfileCaches</scheme-name>
    </cache-mapping>
  </caching-scheme-mapping>

  <caching-schemes>
    <distributed-scheme>
      <scheme-name>ContentNodeCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentNodeCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <distributed-scheme>
      <scheme-name>ContentTypeCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentTypeCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <distributed-scheme>
      <scheme-name>ContentBinaryCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentBinaryCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <distributed-scheme>
      <scheme-name>ContentSearchCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentSearchCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <distributed-scheme>
      <scheme-name>ContentSecurityCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentSecurityCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <distributed-scheme>
      <scheme-name>ContentProfileCaches</scheme-name>
      <backing-map-scheme>
        <local-scheme>
          <scheme-ref>BM_ContentProfileCaches</scheme-ref>
        </local-scheme>
      </backing-map-scheme>
      <backup-count>0</backup-count>
      <autostart>true</autostart>
    </distributed-scheme>

    <local-scheme>
      <scheme-name>BM_ContentNodeCaches</scheme-name>
      <expiry-delay>5m</expiry-delay>
      <high-units>100</high-units>
    </local-scheme>

    <local-scheme>
      <scheme-name>BM_ContentTypeCaches</scheme-name>
      <expiry-delay>30m</expiry-delay>
      <high-units>50</high-units>
    </local-scheme>

    <local-scheme>
      <scheme-name>BM_ContentBinaryCaches</scheme-name>
      <expiry-delay>5m</expiry-delay>
      <high-units>1000000</high-units>
      <unit-calculator>
        <class-scheme>
          <class-name>com.tangosol.net.cache.SimpleMemoryCalculator</class-name>
        </class-scheme>
      </unit-calculator>
    </local-scheme>

    <local-scheme>
      <scheme-name>BM_ContentSearchCaches</scheme-name>
      <expiry-delay>5m</expiry-delay>
      <high-units>50</high-units>
    </local-scheme>

   <local-scheme>
      <scheme-name>BM_ContentSecurityCaches</scheme-name>
      <expiry-delay>10m</expiry-delay>
      <high-units>50</high-units>
    </local-scheme>

   <local-scheme>
      <scheme-name>BM_ContentProfileCaches</scheme-name>
      <expiry-delay>1h</expiry-delay>
      <high-units>100</high-units>
    </local-scheme>
  </caching-schemes>
</cache-config>

 

The cache entries are described in the following documentation:

http://docs.oracle.com/cd/E21764_01/webcenter.1111/e12405/wcadm_documents.htm#BABEDDBI

NOTE: You have to put this file into the application classpath. If you use the file in the managed server class path or node manager class path it will NOT work.

 

Step by Step Installation Process

 

 

Step 1: Create JAR file with the Coherence Cache Config file

 

 

Create JAR file which contains the example content-coherence-cache-config.xml shown above. For how to create JAR files follow the tutorial from the Java documentation here:

http://docs.oracle.com/javase/tutorial/deployment/jar/build.html

You will use this JAR file to put it inside your WebCenter Portal Framework Application. As mention above this works only if this JAR file is part of the WebCenter Portal Framework Application class path.

 

Step 2: Create WebCenter Application EAR Lib folder

To put the created JAR file into the APP-INF/lib you have to update your project settings:

·From the JDeveloper WebCenter Portal Application Project click on Application->Application Properties.

 

·From the new window select Deployment. From the deployment profile select the EAR profile you want to use and then click on Edit button.

 

· From the new window select File Groups and then click on New button. From the new opened window select Packaging and type a name for the file group as shown bellow. Then click OK to add your new packaging file group. Click then OK again the save the changes.

 

·Create the APP-INF/lib folder into your project. Go to the file system where you create the WebCenter Portal Application Project as shown bellow

 

·<!–[endif]–>You have to create the APP-INF/lib folder under the src/ folder:

 

·<!–[endif]–>Inside the newly created APP-INF/lib folder you can place your JAR file with the Coherence Cache configurations.

 

·<!–[endif]–>To make sure that the file will be picked go back to JDeveloper and open the Application Properties again by clicking on Application->Application Properties and then click on Deployment. Select the EAR Profile which you used to add the Packaging File Group and click on Edit button. Inside the new window you should see that your APP-INF/lib folder is selected and inside there, there is also the JAR file you copied.

 

·<!–[endif]–>WebCenter Portal Framework Application is ready for deployment now. Redeploy your application and bounce(load your application one in an browser) to make sure that the configurations are loaded.

Step 3: Check your configuration

NOTE: You have to open your application once to make sure that the Coherence Configuration is loaded.

Make sure that you open the application once in the browser then open your <managed_server>_diagnosting.log file and search for coherence inside. If you see message like this:

[APP: AviTrustSamplePortal#V2.0] Unable to load Coherence configuration file content-coherence-cache-config.xml. Using in-memory (local) caches.

 

… then it means that your application did not find the configuration file. The reason for that is that the JAR file was not inside the application classpath. In this case you may used the Managed Server Classpath which is not working. You have to place the JAR file inside the application classpath as described above.

 

If you don’t see the message above you can go for the next step and look for the Coherence configuration inside the MBean.

To do so open your Enterprise Manager and go to the application configuration like shown bellow:

 

 

Then from the Application Deployment click on the System MBean Browser to have a look in the MBeans. Inside the MBean Tree search for the word <coherence>:

 

You should be able to see the configurations as shown above.

 

Another very good why to check if the cache works is to have a look inside the WCC request audit. It shows if queries were fired against the Content Server.

To do so login as Administrator to WCC.

 

After you login in as administrator select System Audit Information and from the Active Sections select only system and requestaudit as well as Full Verbose Tracing checkbox.

 

Click on Update button to update the configuration.

 

 

After that click from the upper right menu on View Server Output to trace the Content Presenter queries to the Content Server.

If you open a example page where the content presenter is used, like this:

 

You can see after that in the audit log the queries used by the content presenter to get the information:

 

Refresh the page by click on F5 or just the browser refresh button. There’re should be no new queries visible in the audit log anymore, since the content presenter should use the coherence cache now:

 

 

 

Step 4: Configuration for Cluster Environment

 

 

If you run your application in cluster environment you have to make sure that the coherence configuration works inside the cluster. If you have two managed servers in one cluster you can configure following parameters in the startup arguments. If Node Manager is used to start the Managed Servers, you can put the argument in the Server Start argument option.

First server:

-Dtangosol.coherence.wka1=server1.mycompany.com

-Dtangosol.coherence.wka1.port=8088

-Dtangosol.coherence.wka2= server2.mycompany.com

-Dtangosol.coherence.wka2.port=8088

-Dtangosol.coherence.localhost= server1.mycompany.com

-Dtangosol.coherence.localport=8088

 

Second server:

-Dtangosol.coherence.wka1= server1.mycompany.com

-Dtangosol.coherence.wka1.port=8088

-Dtangosol.coherence.wka2= server2.mycompany.com

-Dtangosol.coherence.wka2.port=8088

-Dtangosol.coherence.localhost= server2.mycompany.com

-Dtangosol.coherence.localport=8088

 

NOTE: If the two server are running on the same physical machine, you have to make sure that they use different ports.

 

Configuring the iPlanet as web tier for Oracle WebCenter Content (UCM)

If you are looking for configure the iPlanet as Web server/proxy to use with
the Oracle WebCenter Content, you probably won’t found an specific documentation
for that or will found some old complex notes related to the old 10gR3.

This post will help you out with few simple steps.

That’s the diagram of the test scenario, considering that you will deploy in
production in an cluster environment.

Sample-iPlanet-wcC-topology

 

Working With Deployment Plans

In my overview blog entry ‘From Dev to Test to Production‘, I already mentioned AIA Deployment Plans as key elements for transferring integration code from environment to another. So what is a Deployment Plan then? Primarily it is a set … Continue reading

Deploying Task Flows as Weblogic Shared Libraries to be used by ADF and WebCenter Portal applications

The idea for this post came from some discussions with Lucas Jellema and Edwin Biemond on how to deploy Task Flows that are commonly used across various application deployments. You will learn how you can deploy ADF Task Flows as Weblogic shared libraries that can then be referenced by multiple application deployments. 

Using a Web Proxy Server with WebCenter Family

The use of a Web Tier is always recommended in a production environment, for security, performance and better control and load management, no matter if is a Intranet, internet or extranet environment.

The most common use for the Web Tier with WebCenter is acting as Reverse Proxy to forward all requests to a frontend WebCenter site to the application server (Figure A), but there’s to many ways to do an enterprise deployment with a web tier and many flavors of web servers and load balancing options.

FigA

Let’s start with the WebLogic plugin with supported webservers. You can found the standard plugins in your WebLogic instalation dir, that will something like “%WEBLOGIC_HOME%/server/plugin/%OS%/”, but I recommend you to download the latest plugin from Oracle’s OTN or eDelivery websites, you will found the Oracle WebLogic Server Web Server Plugins 1.1 or later. With the version 1.1 you will found plugins for Apache 2.2.x (32-Bits and 64-Bits) and for IIS 6+ and IIS 7+. Always confirm the OS support with the WLS Plugin Support Matrix. If you need support for iPlanet 6+ or 7+, you can use the version 1.0. Any throuble to found the files, try search or create to the Oracle support (Ref.: Doc ID 1111903.1).

FigB

Some times you do not want to use a separate web server, you can use the WebLogic as a Web Server by using a servlet, but this is subject for another post.

When you are deploying a WebCenter solution using a proxy server, you need to remember to proxy all your requests from all weblogics for Security, performance and Control and also all non-weblogic requests such as static files, WebCenter Content custom requests, Services, Portlets and 3rd Party.

Is common in intranet deployments you see calls direct to the application servers, calls to several different servers, like the Figure C.

FigC

Above you can see the same sample with all calls using the web server, for proxy forward, for reverse proxy, static files caching, even the use of Oracle Coherence is easy when you have a WebCenter Spaces + Content deployment.

FigD

We cannot forget to talk about the clustering and load balancers, Clustering is easy done by the WebLogic, you just need to follow the documentation. For Load balancing you need to choose what kind and what load balancer you will use.

LOAD BALANCING

You can do load balancing using the Web Proxy Server with WLS Plugin or a servlet as mentioned above or a External Load Balancer (Hardware) or Appliance.

Using the WLS Plugin you will need to remember to create a entry for WebCenter Server that are you using, that means that you need to create a entry for the /webcenter/ another for the /cs/, another for the “custom sitestudio” calls, for the portlets (If you do not create a parent folder for the portlets, you will need to create a entry for each portlet) and an entry for any other 3rd calls.

The configuration file for each entry will looks like this sample for IIS7:

 

# Changed by Oracle A-Team (Adao.Junior)
# Date: 07/31/2011
# WebCenter Content: CUSTOMER_WEB_SERVER
# WLSPlugin1.1-IIS6-IIS7-win64-x64

WebLogicCluster=192.168.100.101:8888,192.168.100.102:8888,192.168.100.101:8891,192.168.100.102:8891
ConnectTimeoutSecs=25
ConnectRetrySecs=5
KeepAliveEnabled=true
FileCaching=ON
SecureProxy=OFF

Debug=OFF
WLTempDir=C:\DEBUG\CONTENT

 

For a External Load Balancer (Hardware) you have many options, such as the f5 Big-IP, a guide to help you deploy with WebCenter could be found here.

 

There’s a option to use a hybrid configuration, with Hardware loadbalancers and Web Proxy to handle the web calls between the users and web farms, and web proxies and between the proxies and applications servers.

Deploying to WebLogic Server on Amazon EC2 from JDeveloper

Sometimes, when running WebLogic Server on the Amazon Elastic Compute Cloud, you may find that you are unable to deploy from your local JDeveloper to your WebLogic Server instance. Andrew Rosson has written a helpful post (here) that provides a simple … Continue reading

Additional configuration to allow SOA managed server to be started from Node Manager

I usually don’t start my managed servers from the Node Manager, as I like to have easy access to the console while I am developing and debugging.  But today, I needed to get it working as a prerequisite for another … Continue reading

Installing Oracle Policy Automation on WebLogic Server

Today I needed to install Oracle Policy Automation into a WebLogic Server (11g) environment, for integration into a WebCenter Spaces portal (more on that later).   The documentation provides some hints on how to do this, but not all of … Continue reading

How to disable on-demand deployment of WebLogic console application

This is just a quick one… I often find that just after installing WebLogic Server, I want to disable the on-demand deployment of the console application.  No good reason why, I just don’t like it.  Maybe because I tend to … Continue reading