JBoss Community

Re: Problem with starting process

created by Lukasz Kozerski in jBPM - View the full discussion

Please consider attached example (http://community.jboss.org/servlet/JiveServlet/download/622346-39304/drools-serialization-test.zip).

 

There is one test method:

luk.SerializationTest.shouldSerializeVariable()

 

Right now it works fine. Script1 prints Foo: A, X and Script2 prints Foo: A, Y.

 

But if we change method of starting process from this:

        ksession.startProcess("process", parameters);

        // ProcessInstance process = ksession.createProcessInstance("process",

        // parameters);

        // long processId = process.getId();

        // ksession.startProcessInstance(processId);

 

to this:

        // ksession.startProcess("process", parameters);

        ProcessInstance process = ksession.createProcessInstance("process", parameters);

        long processId = process.getId();

        ksession.startProcessInstance(processId);

 

then Script2 isn't fired.

Reply to this message by going to Community

Start a new discussion in jBPM at Community