[jBPM Development] - Problem inserting in JBPM_JOB
by Iecisa
Hi all,
we are developing a system, using jbpm. This developemt is under aix, oracle 10g and glassfish 2.1. Connection pool is configured in glassfish using oracleXADatasource because we are using several schemas in the same transaction.
We have developed workflows with tasks insert jobs in jbpm_job, however this insert using jbpm hibernate. if a task insert 2 jobs, the first one takes too much time (over 10 seconds) but the second one takes only 3 miliseconds. And the call method is the same for both, as you can see below:
public void AlarmCreate(ExecutionContext executionContext,Date date,String className,String actionName,String timerName){
Delegation delegation = new Delegation();
delegation.setClassName(className);
delegation.setProcessDefinition(executionContext.getProcessDefinition());
Action moveAction = new Action();
moveAction.setName(actionName);
moveAction.setActionDelegation(delegation);
executionContext.getProcessDefinition().addAction(moveAction);
Timer timer = new Timer(executionContext.getToken());
timer.setName(timerName+"_"+executionContext.getProcessInstance().getId());
timer.setDueDate(date);
timer.setGraphElement(executionContext.getEventSource());
timer.setTaskInstance(executionContext.getTaskInstance());
timer.setAction(moveAction);
timer.setLockOwner(executionContext.getProcessDefinition().getName());
DbSchedulerService schservice = new DbSchedulerService();
schservice.createTimer(timer);
}
any help would be really appreciated.
regards
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4260156#4260156
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4260156
15 years, 4 months
Re: [jbpm-dev] Quick question on wiring / EJB3 as process variable
by Tom Baeyens
Hi Bernd,
> The wiring is still pretty wired to me,
i plead guilty as charged
> (with all these indirections and wirings it gets
> pretty hard to find something ;-)).
you even managed to find a bug! so you even found more then you're looking for :-)
an EJB3 matcher and variable type would be great to include.
I've reproduced your problem and fixed it. Once I've committed it (in the next
hour or so) then you'll find an example in
modules\test-cfg\src\test\java\org\jbpm\test\customtype\CustomVariableTypeTest.java
Thanks for reporting it! Let me know if there is any other problem you
encounter with adding ejb3 variable support.
regards, tom.
Bernd Rücker wrote:
> Hey Tom.
>
>
>
> A very quick question, because I start to integrate EJB3 Entities as
> process variables.
>
>
>
> 1. What’s wrong with that? The wiring is still pretty wired to me,
> but this should work, right? I always get a Nullpointer, even if the
> class exists: error: matcher is not a
> org.jbpm.pvm.internal.type.Matcher: null
>
>
>
> <type name="ejb3-long-id" id-type="long"
> variable-class="de.dillinger.stw.jbpm.Ejb3LongEntityVariable">
>
> <matcher><object
> class="de.dillinger.stw.jbpm.Ejb3LongMatcher" /></matcher>
>
> </type>
>
>
>
> 2. What do you think of this approach:
> http://www.jboss.org/index.html?module=bb&op=viewtopic&t=161886
> <http://www.jboss.org/index.html?module=bb&op=viewtopic&t=161886>.
> Wouldn’t the better way be to integrate that with a Matcher and Type? Or
> what do you think about that proposal, seems a bit wired to me?
>
>
>
> Thanks a lot! Sorry for newbie questions, still try to understand some
> stuff in the engine (with all these indirections and wirings it gets
> pretty hard to find something ;-)).
>
>
>
> Cheers
>
> Bernd
>
> --
>
> Unsere Seminare: www.camunda.com/seminare/
> <http://www.camunda.com/seminare/>__
>
> Blog: _www.bpm-guide.de_
>
> ---------------------------------------------
>
> camunda services GmbH - The Business Process Company
>
> Zossener Straße 55-58 - 10961 Berlin
>
> www.camunda.com <http://www.camunda.com> - info(a)camunda.com
> <mailto:info@camunda.com>
>
> ---------------------------------------------
>
> Bernd Rücker
>
> Geschäftsführer
>
> Telefon +49 +49 30 664040 901
>
> Mobil +49 171 1473461
>
> bernd.ruecker(a)camunda.com <mailto:bernd.ruecker@camunda.com>
>
> ---------------------------------------------
>
> Amtsgericht Charlottenburg: HRB 113230 B
>
> Geschäftsführer: Jakob Freund, Bernd Rücker
>
> ---------------------------------------------
>
> EJB-3-Buch: http://www.ejbbuch.de/
>
> BPMN-Buch: http://www.hanser.de/buch.asp?isbn=978-3-446-41768-7
>
>
>
15 years, 4 months