Bug 1032619 - In Spring Camel integration the JSON batch execution of a Jbpm process doesn't return the process id
Summary: In Spring Camel integration the JSON batch execution of a Jbpm process doesn'...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: jBPM Core
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ER6
: 6.0.0
Assignee: Kris Verlaenen
QA Contact: Ivo Bek
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-20 13:41 UTC by Ivo Bek
Modified: 2014-08-06 20:12 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-08-06 20:12:51 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Ivo Bek 2013-11-20 13:41:18 UTC
Description of problem:

I have following REST server:

<cxf:rsServer
    id="rsJsonServer"
    address="http://localhost:58002/restjson"
    serviceClass="org.kie.jax.rs.CommandExecutorImpl">
    <cxf:providers>
      <bean class="org.kie.jax.rs.CommandMessageBodyReader" />
    </cxf:providers>
  </cxf:rsServer>

for that I've created this camel route:

<route id="restJsonGW">
      <from uri="cxfrs://bean://rsJsonServer" />
      <policy ref="kiePolicy">
        <unmarshal ref="json" />
        <to uri="kie:ksession1" />
        <marshal ref="json" />
      </policy>
    </route>

When I work just with business rules and objects, the responses are right. The problem is when I start a business process. For xstream I always receive a result with process instance id but not for json. The result is there but without any values. To marshall the batch xml, I use BatchExecutionHelper.newJSonMarshaller().

String outIdentifier = "taskProcess";
StartProcessCommand startProcessCommand = new StartProcessCommand(HUMAN_TASK_PROCESS_ID,
                new HashMap<String, Object>(), outIdentifier);
ExecutionResults result = sc.execute(startProcessCommand);
assertNotNull(result);
Long processInstanceId = (Long) result.getValue(outIdentifier); // the processInstanceId is null

and as I logged the result, actually there are no values at all.

Comment 2 Kris Verlaenen 2013-11-29 03:05:39 UTC
JSON marshalling of StartProcessCommand was missing outIdentifier

master: http://github.com/droolsjbpm/drools/commit/47a6171c3
6.0.x: http://github.com/droolsjbpm/drools/commit/8407a85ef

Comment 3 Ivo Bek 2014-01-08 12:25:41 UTC
Verified in BPMS 6.0.0.ER7


Note You need to log in before you can comment on or make changes to this bug.