[jBPM Users] - Re: deploy examples error, classcastexception
by hrworx
I get the same thing trying to run a ProcessDefinitionQuery:
| org.jbpm.jpdl.internal.model.JpdlProcessDefinition cannot be cast to java.util.List
| at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338)
| at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473)
| at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
| at java.security.AccessController.doPrivileged(Native Method)
| at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
| at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
| at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
| at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
| at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
| at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
| at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429)
| at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728)
| at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:380)
| at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
| at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
| at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
| at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3830)
| at org.apache.catalina.core.StandardContext.start(StandardContext.java:4337)
| at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1237)
| at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:591)
| at org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:128)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:263)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Thread.java:637)
| Caused by: java.lang.ClassCastException: org.jbpm.jpdl.internal.model.JpdlProcessDefinition cannot be cast to java.util.List
| at org.jbpm.pvm.internal.repository.ProcessDeployer.deploy(ProcessDeployer.java:64)
| at org.jbpm.pvm.internal.repository.DeployerManager.deploy(DeployerManager.java:46)
| at org.jbpm.pvm.internal.repository.RepositorySessionImpl.getObject(RepositorySessionImpl.java:120)
| at org.jbpm.pvm.internal.query.ProcessDefinitionQueryImpl.execute(ProcessDefinitionQueryImpl.java:72)
| at org.jbpm.pvm.internal.query.AbstractQuery.execute(AbstractQuery.java:81)
| at org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
| at org.jbpm.pvm.internal.spring.CommandTransactionCallback.doInTransaction(CommandTransactionCallback.java:50)
| at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:128)
| at org.jbpm.pvm.internal.tx.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:77)
| at org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:46)
| at org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:55)
| at org.jbpm.pvm.internal.query.AbstractQuery.untypedList(AbstractQuery.java:62)
| at org.jbpm.pvm.internal.query.ProcessDefinitionQueryImpl.list(ProcessDefinitionQueryImpl.java:141)
|
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256717#4256717
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256717
14 years, 9 months
[jBPM Users] - Trying to view certain user's tasks in jbpm-console causes e
by sebastian.s
| 23.09.2009 16:28:27 org.apache.catalina.core.StandardWrapperValve invoke
| SCHWERWIEGEND: Servlet.service() for servlet Resteasy threw exception
| org.jboss.resteasy.spi.UnhandledException: java.lang.NullPointerException
| at org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:319)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:230)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:206)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:360)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:173)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:93)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:68)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilter.java:59)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
| at java.lang.Thread.run(Thread.java:619)
| Caused by: java.lang.NullPointerException
| at org.jbpm.integration.console.ModelAdaptor.adoptTask(ModelAdaptor.java:146)
| at org.jbpm.integration.console.TaskManagementImpl.adoptTasks(TaskManagementImpl.java:69)
| at org.jbpm.integration.console.TaskManagementImpl.getAssignedTasks(TaskManagementImpl.java:49)
| at org.jboss.bpm.console.server.TaskListFacade.getTasksForIdRef(TaskListFacade.java:99)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:117)
| at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:260)
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:232)
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:166)
| at org.jboss.resteasy.core.DispatcherUtilities.getJaxrsResponse(DispatcherUtilities.java:142)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:356)
| ... 20 more
|
This happens when I login to view the tasks of one of the test users. The others work fine.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256663#4256663
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256663
14 years, 9 months
[jBPM Users] - JbpmException using Task.setAssignee
by jjp
Hi there !
=== Environment ==============================
- jBPM Version : 4.1
- Database : Oracle 10.2
- JDK : 1.6
- Container : JBoss 4.2.3
- Configuration : Custom jbpm.cfg.xml:
<?xml version="1.0" encoding="UTF-8"?>
| <jbpm-configuration>
| <import resource="jbpm.default.cfg.xml" />
| <import resource="jbpm.businesscalendar.cfg.xml" />
| <import resource="jbpm.tx.jta.cfg.xml" />
| <import resource="jbpm.jpdl.cfg.xml" />
| <!--import resource="jbpm.identity.cfg.xml" /-->
| <import resource="jbpm.jobexecutor.cfg.xml" />
| <transaction-context>
| <object class="com.feltengroup.jbpm.PilotIdentitySession" />
| </transaction-context>
| </jbpm-configuration>
|
- Libraries : the libs from inside the jbpm distribution
=== Process ==================================
Just a Test Jpdl: Start -> Task -> End
=== API ===================================
Task task = taskService.getTask( "myTaskId" );
task.setAssignee( "myUserName" );
=== Stacktrace ==============================
org.jbpm.api.JbpmException: no environment to get org.jbpm.pvm.internal.session.RepositorySession
at org.jbpm.pvm.internal.env.EnvironmentImpl.getFromCurrent(EnvironmentImpl.java:197)
at org.jbpm.pvm.internal.env.EnvironmentImpl.getFromCurrent(EnvironmentImpl.java:190)
at org.jbpm.pvm.internal.model.ExecutionImpl.getProcessDefinition(ExecutionImpl.java:1096)
at org.jbpm.pvm.internal.model.ExecutionImpl.getActivity(ExecutionImpl.java:1118)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
=== Problem description =========================
I'm using JBPM 4.1 with a Seam 2.2.0/Richfaces 3.3.1 (no Pageflows). From a WebPage I try to set the assignee on a Task, it results in the Exception described above.
All other set* Functions on Task are working. TaskService.assignTask is working too!
Best Regards,
Joerg
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256653#4256653
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256653
14 years, 9 months
[jBPM Users] - Re: Only Sync Fork Join working after Multiplicity fix
by mmusaji
I forgot to add the test without the syn that works ok.
| package org.workflow.test.forum;
|
| import org.jbpm.api.Execution;
| import org.jbpm.api.activity.ActivityBehaviour;
| import org.jbpm.api.activity.ActivityExecution;
| import org.jbpm.test.JbpmTestCase;
|
| public class JoinTestApp extends JbpmTestCase{
| String deploymentDbid;
|
| protected void setUp() throws Exception {
| super.setUp();
| }
|
| protected void tearDown() throws Exception {
| repositoryService.deleteDeploymentCascade(deploymentDbid);
| super.tearDown();
| }
|
| public void testJoinASync() throws Exception {
| deploymentDbid = repositoryService.createDeployment()
| .addResourceFromClasspath("org/workflow/test/forum/aSyncProcessCustom.jpdl.xml")
| .deploy();
|
| String processInstanceId = executionService.startProcessInstanceByKey("aSyncProcessCustom").getId();
| assertNotNull(processInstanceId);
|
| Thread.sleep(4000);
|
| assertProcessInstanceEnded(processInstanceId);
| }
| public static class CustomOneClass implements ActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
| }
|
| public static class CustomTwoClass implements ActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
| }
|
| public static class CustomThreeClass implements ActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
| }
|
| public static class CustomFourClass implements ActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
|
| }
|
| }
|
Process Definition (NB. with no async nodes)
| <process name="aSyncProcessCustom">
| <start>
| <transition to="theFork" />
| </start>
| <fork name="theFork">
| <transition to="customOne" />
| <transition to="customTwo" />
| <transition to="customThree" />
| </fork>
| <custom name="customOne" class="org.workflow.test.forum.JoinTestApp$CustomOneClass">
| <transition to="join"/>
| </custom>
| <custom name="customTwo" class="org.workflow.test.forum.JoinTestApp$CustomTwoClass">
| <transition to="join"/>
| </custom>
| <custom name="customThree" class="org.workflow.test.forum.JoinTestApp$CustomThreeClass">
| <transition to="join"/>
| </custom>
| <join name="join">
| <transition to="customFour" />
| </join>
| <custom name="customFour" class="org.workflow.test.forum.JoinTestApp$CustomFourClass">
| <transition to="end"/>
| </custom>
| <end name="end" />
| </process>
|
Output... please note that customFour is executed.
| 15:02:53,799 FIN | [BaseJbpmTestCase] === starting testJoinASync =============================
| 15:02:53,940 FIN | [WireContext] eagerly initializing org.jbpm.pvm.internal.jobexecutor.JobExecutor
| 15:02:53,956 INF | [DispatcherThread] starting DispatcherThread
| log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
| log4j:WARN Please initialize the log4j system properly.
| 15:02:55,018 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:55,034 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:55,034 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:55,049 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:55,049 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:55,221 FIN | [ProcessDefinitionImpl] creating new execution for process 'aSyncProcessCustom'
| 15:02:55,237 FIN | [DefaultIdGenerator] generated execution id aSyncProcessCustom.25
| 15:02:55,237 FIN | [ExecuteActivity] executing activity(7819553)
| 15:02:55,237 FIN | [ExecuteActivity] executing activity(theFork)
| Executing
| customOne
| Executing
| customTwo
| Executing
| customThree
| 15:02:55,237 FIN | [DefaultIdGenerator] generated execution id aSyncProcessCustom.25.26
| 15:02:55,237 FIN | [ExecutionImpl] created execution[aSyncProcessCustom.25.26]
| 15:02:55,237 FIN | [ExecuteActivity] executing activity(customOne)
| 15:02:55,237 FIN | [ExecuteActivity] executing activity(join)
| 15:02:55,253 FIN | [DefaultIdGenerator] generated execution id aSyncProcessCustom.25.27
| 15:02:55,253 FIN | [ExecutionImpl] created execution[aSyncProcessCustom.25.27]
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(customTwo)
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(join)
| 15:02:55,253 FIN | [DefaultIdGenerator] generated execution id aSyncProcessCustom.25.28
| Executing
| customFour
| 15:02:55,253 FIN | [ExecutionImpl] created execution[aSyncProcessCustom.25.28]
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(customThree)
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(join)
| 15:02:55,253 FIN | [ExecutionImpl] execution[aSyncProcessCustom.25.26] ends
| 15:02:55,253 FIN | [ExecutionImpl] execution[aSyncProcessCustom.25.27] ends
| 15:02:55,253 FIN | [ExecutionImpl] execution[aSyncProcessCustom.25.28] ends
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(customFour)
| 15:02:55,253 FIN | [ExecuteActivity] executing activity(end)
| 15:02:55,253 FIN | [ExecutionImpl] execution[aSyncProcessCustom.25] ends
| 15:02:55,268 FIN | [DbSessionImpl] deleting process instance aSyncProcessCustom.25
| 15:02:55,659 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:55,659 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:55,659 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:55,659 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:55,659 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:55,659 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:56,253 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:56,253 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:56,253 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:56,253 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:56,253 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:56,253 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:56,862 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:56,862 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:56,862 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:56,862 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:56,862 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:56,862 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:57,456 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:57,456 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:57,471 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:57,471 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:57,471 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:57,471 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:58,065 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:58,065 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:58,065 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:58,065 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:58,065 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:58,065 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:58,674 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:58,674 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:58,674 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:58,674 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:58,674 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:58,674 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:59,268 FIN | [DispatcherThread] DispatcherThread woke up
| 15:02:59,268 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 15:02:59,268 FIN | [AcquireJobsCmd] locking jobs []
| 15:02:59,268 FIN | [GetNextDueDateCmd] getting next due date...
| 15:02:59,268 FIN | [GetNextDueDateCmd] next due date is null
| 15:02:59,268 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@6025e7
| 15:02:59,300 FIN | [DeleteDeploymentCmd] deleting deployment 110
| 15:02:59,331 FIN | [BaseJbpmTestCase] === ending testJoinASync =============================
|
I'm using the jobExecutor in all these examples on purpose as this is the only way I can show what is happening. Executing job one by one isn't async obviously and thus signalling the jobs doesn't reproduce this issue.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4256651#4256651
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4256651
14 years, 9 months