bpmn:getDataObject error in Oracle BPM process instance

09 Jan

Our Oracle BPM ( process uses a process Data Object (DO) which is enriched with data during it’s process lifetime. The DO is based on a Business Object (BO) which is a relatively large, but a simple XSD data model.

A strange thing that occured was that when we started using Service Call & Script Task to enrich the data during the response our process got suspended.

Instance error on Service task:


And instance error on the Script task:


Checking the output (logging & instance suspended messsage) we noticed this error:

<auditQueryPayload  auditId="316002"  ciKey="200007">
<dataObject  name="DO_myData"  isBusinessIndicator="false">
<myElement xmlns="<a href=""></a>">
<dataObject  name="FaultMessage"  isBusinessIndicator="false">
<value> oracle.bpm.bpmn.engine.model.runtime.microinstructions.TrappableException: faultName: {{}selectionFailure} messageType: {{}RuntimeFaultMessage} cause: {faultName: {{}selectionFailure} messageType: {{}RuntimeFaultMessage} parts: {{ summary=<summary>empty expression result. The expression bpmn:getDataObject('DO_myData')/ns:myElement/ns:myElement2 is empty. An attempt to read or copy data referenced or computed by the XPath expression either had invalid data, according to the XML schema, or did not contain certain optional data. Ensure that the variable or expression result named in the error message is not empty. Enable XML schema validation of related data elements to ensure the run-time data is valid. </summary>} } </value>

Our output data association is configured with a simple express Copy command, but when we check the BPMN process file source we can see where the bpmn:getDataObject is used.

<ns5:DataAssignment operation="copy"/>
<from xsi:type="tFormalExpression" language="<a href=""></a>" xmlns:ns="<a href=""></a>" xmlns:bpmn="<a href=";>bpmn:getDataOutput('myWebserviceResponseElement')/ns:myElement/ns:myElement2">">bpmn:getDataOutput('myWebserviceResponseElement')/ns:myElement/ns:myElement2</a>
<ns5:Expression mode="simple"/>
<to xsi:type="tFormalExpression" language="<a href=""></a>" xmlns:ns="<a href=""></a>" xmlns:bpmn="<a href=";>bpmn:getDataObject('DO_myData')/ns:myElement/ns:myElement2">">bpmn:getDataObject('DO_myData')/ns:myElement/ns:myElement2</a>
<ns5:Expression mode="simple"/>

So however when using a simple copy in the output Data Associations, the project generates the code above where BPM is apparantly perfoming a getDataObject XPath BPM Extension Functions on the target element before mapping the data. Since the element is still empty (and not existing) in the current state of our process we seem to receive this error.

The solution seems simple to fix with an XSLT mapping, however we are still not sure if this is the way to go.


Using a XSLT transformation on the full Data Object does the trick. However this becomes a lot of work if you just need to map 1 element.

Still a thing bothering me is that the problem suddenly appeared on an script task outout mapping (where we always used Copy there) after some serious data modelling actions we performed on our BO. So I’m thinking that XML data modelling options as nillable, occurence, etc might have something to do with it. Still something requiring more research I guess.

Done all the development and writing together with Marcel vd Glind from AmisA similar blog post therefor can be found on the Amis technology blog.


Comments Off on bpmn:getDataObject error in Oracle BPM process instance

Posted by on 09-01-2013 in BPM, Oracle


Tags: ,

Comments are closed.


Get every new post delivered to your Inbox.

Join 375 other followers

%d bloggers like this: