Tuesday, April 8, 2014

OPatch'ing Pre-built Virtual Machine for SOA Suite and BPM Suite 11g

In March 2014, Oracle released an updated version of its Pre-built Virtual Machine for SOA Suite and BPM Suite 11g for Patchset 6 (11.1.1.7). The bundle patch 17014142 for Oracle BPM 11.1.1.7.1 is already installed. However, most of you will like to upgrade to bundle patch 17584181 directly (11.1.1.7.2). By using the installed version of OPatch in /oracle/fmwhome/Oracle_SOA1/OPatch directory, you will run into an opatch error 70:

[ Error during Patch conflict resolution for apply patch phase ] Detail: OUI-67073:OPatch failed: ApplySession failed in system modification phase... 'Current access level does not allow writing to the inventory'
OPatch will attempt to restore the system...


The reason is that the OPatch version installed in /oracle/fmwhome/Oracle_SOA1/OPatch is 11.2.0.3.5. However, for any opatch application on Oracle Fusion Middleware 11.1.x, the most recent version of OPatch 11.1.x is recommended (at the time of writing OPatch version 11.1.0.10.3).

  1. Download most recent version of OPatch 11.1.x
  2. Copy it to /oracle/fmwhome/Oracle_SOA1/OPatch_11.1.0.10.3
  3. Apply opatch by using absolute path:
    $ sh /oracle/fmwhome/Oracle_SOA1/OPatch_11.1.0.10.3/opatch apply
 OPatch will then work correctly.

Tuesday, February 18, 2014

Case UI browser compatibility

For Oracle Patners, Oracle provides a non-productive patch that enables an OOTB case UI in Oracle Business Process Composer 11g for Adaptive Case Management (cf. notice by Jürgen Kress).

Testing around a bit on my local environment, I was wondering why I could access this case UI but none of my case instances showed up.
Fig. 1: Case UI in Firefox 27.0 without case instances shown

Finally testing in the web browser on my linux VM where the server is running, indeed everything was there!
 Fig. 2: Case UI in IE 11 mode IE 8 showing case instances

So I guess it's about browser compatibility issues ... which is pretty much ok since the case UI is still in beta stage. Following settings have been tested by me so fare:

BrowserOSRemote/HostResult
Firefox 26.0 x86Windows 7 x64RemoteFail
Firefox 27.0 x86Windows 7 x64RemoteFail
IE 11.0.9600.16476 in Document Mode = IE 5 and User Agent = Standard (IE 6)Windows 7 x64RemoteBPM Workspace not supported
IE 11.0.9600.16476 in Document Mode = IE 7 and User Agent = Standard (IE 7)Windows 7 x64RemoteWorking, but rendering issues
IE 11.0.9600.16476 in Document Mode = IE 8 and User Agent = Standard (IE 8)Windows 7 x64RemoteWorking
IE 11.0.9600.16476 in Document Mode = IE 9 and User Agent = Standard (IE 9)Windows 7 x64RemoteWorking
IE 11.0.9600.16476 in Document Mode = IE 10 and User Agent = Standard (IE 10)Windows 7 x64RemoteWorking
IE 11.0.9600.16476 Document Mode = Standard (IE 11) and User Agent = Standard (IE 11)Windows 7 x64RemoteFailed to load Case UI, Worklist loeded
SRWare Iron 32.0.1750.1 (Chrome)Windows 7 x64RemoteFail
Firefox 24.3.0 x32OEL 6.5 x64HostWorking

Friday, February 7, 2014

Test Case Initialization with Web Service end point

The Oracle Adaptive Case Management Demo for HelloWorld introduces how to test a Case Management application by invoking a web service end point. This web service on the other hand will initiate a case instance.
Oracle promotes to invoke this web service using the test end point available at http://<your-server>:<your-port>/soa-infra/ This cause a little bit of frustration to me since this end point did not show the web service payload attributes unless I knew I implemented them.

Checking forth and back, reimplementing the web service again and again, I finally had the idea to check in Enterprise Manager ... and voila: everything there!

I don't really know why the test end point at soa-infra doesn't do the job any more or even if others faced the problem. But if ever, you run into it, you'll at least have a workaround by now.

Thursday, January 30, 2014

JBO-29114 / JBO-25004 with Oracle BPM 11g - Workspace does not load UI for Human Task

A while back, I struggled with the UI of a POC not coming up in Oracle Business Process Workspace. The following has been tested with Oracle BPM 11.1.1.7.0 / 11.1.1.7.2 but may be the same for other releases. To spoil a bit: It's a system fault and once understood, no big deal. However, I passed some time on that since all related sources I found (e.g. on OTN Forums) didn't not exactly cover this context with BPM involved.

Checking the stack trace, I found the following:

Root cause of ServletException.
oracle.jbo.InvalidDefNameException: JBO-29114 ADFContext is not setup to process messages for this exception. Use the exception stack trace and error code to investigate the root cause of this exception. Root cause error code is JBO-25004. Error message parameters are {0=Package, 1=poc-bpm-002_ui.DataBindings}
    at oracle.jbo.mom.DefinitionManager.loadProjectDefinition(DefinitionManager.java:1801)
    at oracle.jbo.uicli.mom.JUMetaObjectManager.findCpx(JUMetaObjectManager.java:667)
    at oracle.jbo.uicli.mom.JUMetaObjectManager.loadCpx(JUMetaObjectManager.java:748)
    at oracle.adf.model.BindingContext.initialize(BindingContext.java:402)
    at oracle.adf.model.BindingRequestHandler.beginRequest(BindingRequestHandler.java:238)
    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:203)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.adf.share.http.ServletADFFilter.doFilter(ServletADFFilter.java:71)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:128)
    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
    at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)
    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)
    at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.bpel.services.workflow.client.worklist.util.WorkflowFilter.doFilter(WorkflowFilter.java:175)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.bpel.services.workflow.client.worklist.util.DisableUrlSessionFilter.doFilter(DisableUrlSessionFilter.java:70)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)
    at java.security.AccessController.doPrivileged(Native Method)
    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)
    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)
    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)
    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)
    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3730)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3696)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2273)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2179)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1490)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)


JBO-29114 doesn't say much and JBO-25004 pointing us to the involved package (poc-bpm-002_ui in my case) only helps when we understand where it comes from. Actually, this package for the DataBindings will be generated by Oracle BPM Studio 11.1.1.7 if you auto-generate the Task Form for a Human Task component. On generation, the package name is taken from the ADF project name you are choosing for the UI project. Unless ADF Naming Conventions (v2.00) do not impose any restrictions on ADF project names, this generation procedure requires that you do not use the minus sign "-" in the ADF UI project name. However, the underscore doesn't impose any problems.

Summery: No minus sign in ADF UI project names if you use Oracle BPM Studio 11g auto-generation of Task Flows!

Saturday, February 5, 2011

Directory path for Java applications

It happens that I would like to load or store files with a Java application. Back in the old days, I always wondered how to construct the right relative path. The clue is that all relative pathes are being evaluated from the point of the root directory of the Java application. Considering the whole project as one simple exe file may help to understand this. The basic directions therefore are
  • moving down a directory

    [subdirectory/]subdirectory/file.file-extension

    which is equal to

    ./subdirectory(/subdirectory)file.file-extension
  • moving up a directory

    [../]../file.file-extension

To access a file in a directory on the same level of the application directory, you therefore need to go up a directory to move down into the target directory afterwards.
../target-directory/file.file-extension

Store a text file in Java

When I started coding, I always searched for a simple way to save resluts from a Java application to a simple txt file. These days, I found it on a post-it behind my desk:

First of all, you need a java.io.File instance:
import java.io.File;
// ...
File file = new File („[file-path]file-name.file-extension“);
// ...
And here is the storage method:
import java.io.*;
//...
public static void save(File file) {
    try {

        BufferedWriter writer = new BufferedWriter(new FileWriter(file));
        writer.close();
    }
    catch (IOException e) {
        e.printStackTrace();
        System.out.println("Error on file saving.");
    }
}
//...

Searching all files in eclipse

I was always wondering how to search all open projects in eclipse for a particular word. The solution is as simple as that: Somehow copy the word you want to search for in the clipboard an select the torch light in the tool bar and select 2 File Search.