0 Replies Latest reply on Feb 11, 2015 1:39 PM by Pankaj Patro

    jbpm6.1 List<TaskSummary> listTasks = taskService.getActiveTasks(), thorws could not locate named parameter [language]

    Pankaj Patro Newbie

      in jBPM 6.1 product.

      I am trying to run below scenario to fetch list of active tasks for a process, but facing with could not locate named parameter [language]

       

       

       

      RuntimeManager manager = createRuntimeManager("Evaluation.bpmn");

              RuntimeEngine engine = getRuntimeEngine(null);

              InternalTaskService taskService = (InternalTaskService)engine.getTaskService();

             

             

              List<TaskSummary> listTasks = taskService.getActiveTasks();

              System.out.println("size .. "+listTasks.size());

       

      Full trace log details-

      java.lang.IllegalArgumentException: org.hibernate.QueryParameterException: could not locate named parameter [language]

          at org.hibernate.ejb.QueryImpl.setParameter(QueryImpl.java:377) ~[hibernate-entitymanager-4.2.12.Final.jar:4.2.12.Final]

          at org.hibernate.ejb.QueryImpl.setParameter(QueryImpl.java:74) ~[hibernate-entitymanager-4.2.12.Final.jar:4.2.12.Final]

          at org.jbpm.services.task.persistence.JPATaskPersistenceContext.queryStringWithParameters(JPATaskPersistenceContext.java:486) ~[classes/:na]

          at org.jbpm.services.task.persistence.JPATaskPersistenceContext.queryWithParametersInTransaction(JPATaskPersistenceContext.java:344) ~[classes/:na]

          at org.jbpm.services.task.impl.TaskAdminServiceImpl.getActiveTasks(TaskAdminServiceImpl.java:48) ~[classes/:na]

          at org.jbpm.services.task.commands.GetActiveTasksCommand.execute(GetActiveTasksCommand.java:41) ~[classes/:na]

          at org.jbpm.services.task.commands.GetActiveTasksCommand.execute(GetActiveTasksCommand.java:1) ~[classes/:na]

          at org.jbpm.services.task.commands.TaskCommandExecutorImpl$SelfExecutionCommandService.execute(TaskCommandExecutorImpl.java:65) ~[classes/:na]

          at org.drools.core.command.impl.AbstractInterceptor.executeNext(AbstractInterceptor.java:41) ~[drools-core-6.1.1-SNAPSHOT.jar:6.1.1-SNAPSHOT]

          at org.jbpm.services.task.persistence.TaskTransactionInterceptor.execute(TaskTransactionInterceptor.java:54) ~[classes/:na]

          at org.jbpm.services.task.commands.TaskCommandExecutorImpl.execute(TaskCommandExecutorImpl.java:40) [classes/:na]

          at org.jbpm.services.task.impl.command.CommandBasedTaskService.getActiveTasks(CommandBasedTaskService.java:358) [classes/:na]

          at org.jbpm.runtime.manager.impl.task.SynchronizedTaskService.getActiveTasks(SynchronizedTaskService.java:185) [classes/:na]

          at com.sample.ProcessHT1.testEvaluationProcess(ProcessHT1.java:28) [bin/:na]

          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_71]

          at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_71]

          at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_71]

          at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.7.0_71]

          at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) [junit.jar:na]

          at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) [junit.jar:na]

          at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) [junit.jar:na]

          at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) [junit.jar:na]

          at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) [junit.jar:na]

          at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) [junit.jar:na]

          at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271) [junit.jar:na]

          at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) [junit.jar:na]

          at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50) [junit.jar:na]

          at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238) [junit.jar:na]

          at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63) [junit.jar:na]

          at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236) [junit.jar:na]

          at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53) [junit.jar:na]

          at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229) [junit.jar:na]

          at org.junit.runners.ParentRunner.run(ParentRunner.java:309) [junit.jar:na]

          at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50) [.cp/:na]

          at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) [.cp/:na]

          at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467) [.cp/:na]

          at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683) [.cp/:na]

          at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390) [.cp/:na]

          at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197) [.cp/:na]

      Caused by: org.hibernate.QueryParameterException: could not locate named parameter [language]

          at org.hibernate.engine.query.spi.ParameterMetadata.getNamedParameterDescriptor(ParameterMetadata.java:100) ~[hibernate-core-4.2.12.Final.jar:4.2.12.Final]

          at org.hibernate.engine.query.spi.ParameterMetadata.getNamedParameterExpectedType(ParameterMetadata.java:106) ~[hibernate-core-4.2.12.Final.jar:4.2.12.Final]

          at org.hibernate.internal.AbstractQueryImpl.determineType(AbstractQueryImpl.java:466) ~[hibernate-core-4.2.12.Final.jar:4.2.12.Final]

          at org.hibernate.internal.AbstractQueryImpl.setParameter(AbstractQueryImpl.java:436) ~[hibernate-core-4.2.12.Final.jar:4.2.12.Final]

          at org.hibernate.ejb.QueryImpl.setParameter(QueryImpl.java:371) ~[hibernate-entitymanager-4.2.12.Final.jar:4.2.12.Final]

          ... 38 common frames omitted