- 浏览: 81160 次
- 性别:
- 来自: 上海
文章分类
最新评论
-
白菜1578:
Unable to update index for cent ...
Drools规则引擎介绍PPT及利用Drools实现的信用卡申请审批规则实例 -
sinodragon21:
学习 留爪
《深入浅出jBPM》一书中第7章与第9章相关工程的源码 -
glorysongglory:
org.jbpm.JbpmException: closed ...
《深入浅出jBPM》一书中第7章与第9章相关工程的源码 -
chancong:
貌似跟杨大川视频上讲的内容很像
多维查询表达式——MDX教程系列一 -
chengguogen:
请您给我们作个培训吧,如何?我们需要专业支持。chenggg@ ...
jbpm工作流引擎介绍
《深入浅出jBPM》一书中第7章与第9章相关工程的源码。本书由人民邮电出版社出版。
第7章介绍的报销及采购流程的完整工程及其源代码: jbpm-web-test.rar
第9章企业级应用里涉及到的工程及相关EJB的源代码:jbpm-ent-test.ear.rar
我发现ManagerAssignment这个handler根本没有被调用,请高老师解释下
要在 destinations-service.xml 配置文件中配置队列吗?
第7章介绍的报销及采购流程的完整工程及其源代码: jbpm-web-test.rar
第9章企业级应用里涉及到的工程及相关EJB的源代码:jbpm-ent-test.ear.rar
- jbpm-web-test.rar (5.4 MB)
- 下载次数: 6216
- jbpm-ent-test.ear.rar (5.3 MB)
- 下载次数: 2826
评论
171 楼
sinodragon21
2014-03-26
学习 留爪
170 楼
glorysongglory
2012-11-12
org.jbpm.JbpmException: closed JbpmContext in different order then they were created... check your try-finally's around JbpmContexts blocks
org.jbpm.JbpmConfiguration.popJbpmContext(JbpmConfiguration.java:580)
org.jbpm.JbpmConfiguration.jbpmContextClosed(JbpmConfiguration.java:592)
org.jbpm.JbpmContext.close(JbpmContext.java:144)
org.jbpm.web.JbpmContextFilter.doFilter(JbpmContextFilter.java:85)
这样的问题怎么解决呢?高老师
org.jbpm.JbpmConfiguration.popJbpmContext(JbpmConfiguration.java:580)
org.jbpm.JbpmConfiguration.jbpmContextClosed(JbpmConfiguration.java:592)
org.jbpm.JbpmContext.close(JbpmContext.java:144)
org.jbpm.web.JbpmContextFilter.doFilter(JbpmContextFilter.java:85)
这样的问题怎么解决呢?高老师
169 楼
SB1006
2010-11-21
高老师 您好 我有个问题,就是第一个流程我创建实例的时候我后台打出下面部分后没有报错,但是我查了下jbpm_taskinstance这个表 没有任务实例数据,创建实例没成功,麻烦帮我看下,谢谢
2010-11-21 22:05:12,812 WARN (org.hibernate.engine.StatefulPersistenceContext.ProxyWarnLog:581) - Narrowing proxy to class org.jbpm.graph.node.StartState - this operation breaks ==
2010-11-21 22:05:12,843 WARN (org.hibernate.engine.StatefulPersistenceContext.ProxyWarnLog:581) - Narrowing proxy to class org.jbpm.graph.node.TaskNode - this operation breaks ==
2010-11-21 22:05:12,812 WARN (org.hibernate.engine.StatefulPersistenceContext.ProxyWarnLog:581) - Narrowing proxy to class org.jbpm.graph.node.StartState - this operation breaks ==
2010-11-21 22:05:12,843 WARN (org.hibernate.engine.StatefulPersistenceContext.ProxyWarnLog:581) - Narrowing proxy to class org.jbpm.graph.node.TaskNode - this operation breaks ==
168 楼
SB1006
2010-11-18
您好,能不能把建表sql上传下,这样跑实例代码更容易些,谢谢
167 楼
eminemning
2010-11-12
高洁写的垃圾书,他tm难看
166 楼
ye无痕
2010-11-10
郁闷,为什么我这里也没有配置文件呢,请指点下!!!
165 楼
roy2008linkage
2010-09-27
同问167楼的。第七章的采购流程实例。
看了高老师的jbpm的mail配置,怎么发邮件不用用户名、密码啊。一直报错,和167楼的一样的错
看了高老师的jbpm的mail配置,怎么发邮件不用用户名、密码啊。一直报错,和167楼的一样的错
164 楼
liyunqi
2010-09-19
高老师,首先感谢你出的这本《深入浅出jBPM》,对我帮助很大。不过,我是入门新手,在认真看本书中遇到一些问题,希望你帮助解决一下:
我从第一章看到第七章(目前看到第七章),所有的例子基本都可以正常运行,也仔细的按照书中所写的内容实现了相当的代码,不过,也发现一些问题,都是与邮件发送有关的。
问题分别来自:
1、第107-111页的mail node节点示例
2、第127-131页的tasknotify流程示例
3、第七章的采购流程示例中的邮件发送功能
以上3处问题都出现在邮件发送失败。
按照书中所写,配置jbpm.cfg.xml(已放在classpath下),增加内容:
<string name="jbpm.mail.smtp.host" value="smtp.gmail.com"/>
<bean name="jbpm.mail.address.resolver" class="test.TestMailResolver" singleton="true"/>
<string name="jbpm.mail.from.address" value="liyunqi168@gmail.com"/>
以上内容,我当然改成了自己所使用的邮箱, ,
我当时也在想,这样应该是不能发邮件吧,理由是:邮件的用户名和密码都没有配置出来,这样就能发邮件了吗,感觉不行?
果然在测试是发送不了邮件,报出程度异常错误,如:运行第七章的采购流程示例TestPurchaseProcess.java报错如下:
org.jbpm.graph.def.DelegationException: couldn't send email
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:259)
at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:198)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:197)
at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:168)
at org.jbpm.graph.def.Node.enter(Node.java:318)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.def.Node.leave(Node.java:368)
at org.jbpm.graph.node.Fork.execute(Fork.java:140)
at org.jbpm.graph.def.Node.enter(Node.java:318)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.node.StartState.leave(StartState.java:70)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.leave(<generated>)
at org.jbpm.graph.exe.Token.signal(Token.java:192)
at org.jbpm.graph.exe.Token.signal(Token.java:140)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:479)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:393)
at test.testprocess.TestPurchaseProcess.newProcessInstance(TestPurchaseProcess.java:46)
at test.testprocess.TestPurchaseProcess.testPurchaseProcess(TestPurchaseProcess.java:18)
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 junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
Caused by: org.jbpm.JbpmException: couldn't send email
at org.jbpm.mail.Mail.send(Mail.java:208)
at org.jbpm.mail.Mail.send(Mail.java:160)
at org.jbpm.mail.Mail.execute(Mail.java:81)
at org.jbpm.graph.def.Action.execute(Action.java:122)
at org.jbpm.graph.def.GraphElement.executeAction(GraphElement.java:259)
at org.jbpm.graph.def.GraphElement.executeActions(GraphElement.java:215)
at org.jbpm.graph.def.GraphElement.fireAndPropagateEvent(GraphElement.java:185)
at org.jbpm.graph.def.GraphElement.fireEvent(GraphElement.java:169)
at org.jbpm.taskmgmt.exe.TaskInstance.setActorId(TaskInstance.java:292)
at org.jbpm.taskmgmt.exe.TaskInstance.setActorId(TaskInstance.java:262)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentActorIdExpr(TaskMgmtInstance.java:287)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:247)
... 54 more
Caused by: javax.mail.SendFailedException: Sending failed;
nested exception is:
class javax.mail.MessagingException: 530 5.7.0 Must issue a STARTTLS command first. 33sm10603102wad.6
at javax.mail.Transport.send0(Transport.java:218)
at javax.mail.Transport.send(Transport.java:80)
at org.jbpm.mail.Mail.send(Mail.java:206)
... 65 more
另外,我也查看了高老师这里前面的几个回贴,如你回的第26楼贴,说这样配置:
<string name="jbpm.mail.smtp.host" value="smtp.gmail.com" />
<!-- 配置邮件来源地址 -->
<string name="jbpm.mail.from.address" value="aaa@gmail.com" />
<!-- 邮件安全验证 -->
<string name="jbpm.mail.smtp.auth" value="true" />
<!-- 用户名 -->
<string name="jbpm.mail.user" value="aaa@gmail.com" />
<!-- 密码 -->
<string name="jbpm.mail.password" value="****" />
我参考了这里的方法,我更改成这样依然邮件发送不成功。
另,又有回帖说,更改jBPM源码org.jbpm.mail包下的Mail.java文件,这一步,我没有试过,不知真的能否成功。
相信其他书友也遇到同样的问题,
麻烦高老师把邮件发送的这个功能详细指点一下,谢谢!
我从第一章看到第七章(目前看到第七章),所有的例子基本都可以正常运行,也仔细的按照书中所写的内容实现了相当的代码,不过,也发现一些问题,都是与邮件发送有关的。
问题分别来自:
1、第107-111页的mail node节点示例
2、第127-131页的tasknotify流程示例
3、第七章的采购流程示例中的邮件发送功能
以上3处问题都出现在邮件发送失败。
按照书中所写,配置jbpm.cfg.xml(已放在classpath下),增加内容:
<string name="jbpm.mail.smtp.host" value="smtp.gmail.com"/>
<bean name="jbpm.mail.address.resolver" class="test.TestMailResolver" singleton="true"/>
<string name="jbpm.mail.from.address" value="liyunqi168@gmail.com"/>
以上内容,我当然改成了自己所使用的邮箱, ,
我当时也在想,这样应该是不能发邮件吧,理由是:邮件的用户名和密码都没有配置出来,这样就能发邮件了吗,感觉不行?
果然在测试是发送不了邮件,报出程度异常错误,如:运行第七章的采购流程示例TestPurchaseProcess.java报错如下:
org.jbpm.graph.def.DelegationException: couldn't send email
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:259)
at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:198)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:197)
at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:168)
at org.jbpm.graph.def.Node.enter(Node.java:318)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.def.Node.leave(Node.java:368)
at org.jbpm.graph.node.Fork.execute(Fork.java:140)
at org.jbpm.graph.def.Node.enter(Node.java:318)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.node.StartState.leave(StartState.java:70)
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.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$9daea9b7.leave(<generated>)
at org.jbpm.graph.exe.Token.signal(Token.java:192)
at org.jbpm.graph.exe.Token.signal(Token.java:140)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:479)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:393)
at test.testprocess.TestPurchaseProcess.newProcessInstance(TestPurchaseProcess.java:46)
at test.testprocess.TestPurchaseProcess.testPurchaseProcess(TestPurchaseProcess.java:18)
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 junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
Caused by: org.jbpm.JbpmException: couldn't send email
at org.jbpm.mail.Mail.send(Mail.java:208)
at org.jbpm.mail.Mail.send(Mail.java:160)
at org.jbpm.mail.Mail.execute(Mail.java:81)
at org.jbpm.graph.def.Action.execute(Action.java:122)
at org.jbpm.graph.def.GraphElement.executeAction(GraphElement.java:259)
at org.jbpm.graph.def.GraphElement.executeActions(GraphElement.java:215)
at org.jbpm.graph.def.GraphElement.fireAndPropagateEvent(GraphElement.java:185)
at org.jbpm.graph.def.GraphElement.fireEvent(GraphElement.java:169)
at org.jbpm.taskmgmt.exe.TaskInstance.setActorId(TaskInstance.java:292)
at org.jbpm.taskmgmt.exe.TaskInstance.setActorId(TaskInstance.java:262)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentActorIdExpr(TaskMgmtInstance.java:287)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:247)
... 54 more
Caused by: javax.mail.SendFailedException: Sending failed;
nested exception is:
class javax.mail.MessagingException: 530 5.7.0 Must issue a STARTTLS command first. 33sm10603102wad.6
at javax.mail.Transport.send0(Transport.java:218)
at javax.mail.Transport.send(Transport.java:80)
at org.jbpm.mail.Mail.send(Mail.java:206)
... 65 more
另外,我也查看了高老师这里前面的几个回贴,如你回的第26楼贴,说这样配置:
<string name="jbpm.mail.smtp.host" value="smtp.gmail.com" />
<!-- 配置邮件来源地址 -->
<string name="jbpm.mail.from.address" value="aaa@gmail.com" />
<!-- 邮件安全验证 -->
<string name="jbpm.mail.smtp.auth" value="true" />
<!-- 用户名 -->
<string name="jbpm.mail.user" value="aaa@gmail.com" />
<!-- 密码 -->
<string name="jbpm.mail.password" value="****" />
我参考了这里的方法,我更改成这样依然邮件发送不成功。
另,又有回帖说,更改jBPM源码org.jbpm.mail包下的Mail.java文件,这一步,我没有试过,不知真的能否成功。
相信其他书友也遇到同样的问题,
麻烦高老师把邮件发送的这个功能详细指点一下,谢谢!
163 楼
showtime520
2010-09-12
summerweiyang 写道
刚才翻阅前面的同志出现的异常和我的很像,高老师说是否把变量ISSEU_PERSON放入流程实例当中,看后果然发现是个错误。
于是我尝试着修改拉Constans.java中,String final ISSEU_PERSON="issueperson"
或者把流程其他文件里的issueperson改为issue_person则都不会使junit报错。
但是无论修改于否,整个流程只能进行到部门经理这个环节,不能向下进行。
我也尝试修改TestProcess.java中关于关于部门经理是否同意的参数,调整为不同意,但是仍然流不到财务报销结果的Node当中,望指教啊。。。
是不是就是
package test.assignment;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.taskmgmt.def.AssignmentHandler;
import org.jbpm.taskmgmt.exe.Assignable;
import test.Constants;
public class ManagerAssignment implements AssignmentHandler,Constants
{
public void assign(Assignable assignable, ExecutionContext executionContext) throws Exception
{
//从当前流程实例上下文中取得当前报销人
String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
if(issueperson.equals("user1"))
{
//当前报销人为user1,部门经理为manager1;
assignable.setActorId("manager1");
}
else
{
//当报销人为其他人时manager2
assignable.setActorId("manager2");
}
}
}
当中String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
无法获取ISSUE_PERSON在上下文当中的传进来的数据呢?怎么可以传进来呢?
还有,如果有可能的话,能不能发一份带有第一个报销流程的TestPaymentProcess.java的文件给我呢,谢谢拉。
于是我尝试着修改拉Constans.java中,String final ISSEU_PERSON="issueperson"
或者把流程其他文件里的issueperson改为issue_person则都不会使junit报错。
但是无论修改于否,整个流程只能进行到部门经理这个环节,不能向下进行。
我也尝试修改TestProcess.java中关于关于部门经理是否同意的参数,调整为不同意,但是仍然流不到财务报销结果的Node当中,望指教啊。。。
是不是就是
package test.assignment;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.taskmgmt.def.AssignmentHandler;
import org.jbpm.taskmgmt.exe.Assignable;
import test.Constants;
public class ManagerAssignment implements AssignmentHandler,Constants
{
public void assign(Assignable assignable, ExecutionContext executionContext) throws Exception
{
//从当前流程实例上下文中取得当前报销人
String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
if(issueperson.equals("user1"))
{
//当前报销人为user1,部门经理为manager1;
assignable.setActorId("manager1");
}
else
{
//当报销人为其他人时manager2
assignable.setActorId("manager2");
}
}
}
当中String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
无法获取ISSUE_PERSON在上下文当中的传进来的数据呢?怎么可以传进来呢?
还有,如果有可能的话,能不能发一份带有第一个报销流程的TestPaymentProcess.java的文件给我呢,谢谢拉。
我发现ManagerAssignment这个handler根本没有被调用,请高老师解释下
162 楼
summerweiyang
2010-08-24
楼下的同志们,有没有会连接TOMCAT6。0到SQL2005啊,求帮助啊。。。
161 楼
xufang123456
2010-08-20
高老师,在采购流程中我在点击“我的待办任务”菜单中的操作列表下的“处理该流程”出现如下异常:
java.sql.SQLException: 未执行语句句柄: getMetaData
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:111)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:145)
at oracle.jdbc.driver.OracleResultSetImpl.getMetaData(OracleResultSetImpl.java:134)
at oracle.jdbc.driver.OraclePreparedStatement.getMetaData(OraclePreparedStatement.java:3984)
at test.dao.BusinessDAO.query(BusinessDAO.java:45)
at org.apache.jsp.cancel_002dapply_jsp._jspService(cancel_002dapply_jsp.java:96)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
这是什么原因?希望你帮我解决一下
java.sql.SQLException: 未执行语句句柄: getMetaData
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:111)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:145)
at oracle.jdbc.driver.OracleResultSetImpl.getMetaData(OracleResultSetImpl.java:134)
at oracle.jdbc.driver.OraclePreparedStatement.getMetaData(OraclePreparedStatement.java:3984)
at test.dao.BusinessDAO.query(BusinessDAO.java:45)
at org.apache.jsp.cancel_002dapply_jsp._jspService(cancel_002dapply_jsp.java:96)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
这是什么原因?希望你帮我解决一下
160 楼
summerweiyang
2010-08-20
刚才翻阅前面的同志出现的异常和我的很像,高老师说是否把变量ISSEU_PERSON放入流程实例当中,看后果然发现是个错误。
于是我尝试着修改拉Constans.java中,String final ISSEU_PERSON="issueperson"
或者把流程其他文件里的issueperson改为issue_person则都不会使junit报错。
但是无论修改于否,整个流程只能进行到部门经理这个环节,不能向下进行。
我也尝试修改TestProcess.java中关于关于部门经理是否同意的参数,调整为不同意,但是仍然流不到财务报销结果的Node当中,望指教啊。。。
是不是就是
package test.assignment;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.taskmgmt.def.AssignmentHandler;
import org.jbpm.taskmgmt.exe.Assignable;
import test.Constants;
public class ManagerAssignment implements AssignmentHandler,Constants
{
public void assign(Assignable assignable, ExecutionContext executionContext) throws Exception
{
//从当前流程实例上下文中取得当前报销人
String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
if(issueperson.equals("user1"))
{
//当前报销人为user1,部门经理为manager1;
assignable.setActorId("manager1");
}
else
{
//当报销人为其他人时manager2
assignable.setActorId("manager2");
}
}
}
当中String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
无法获取ISSUE_PERSON在上下文当中的传进来的数据呢?怎么可以传进来呢?
还有,如果有可能的话,能不能发一份带有第一个报销流程的TestPaymentProcess.java的文件给我呢,谢谢拉。
于是我尝试着修改拉Constans.java中,String final ISSEU_PERSON="issueperson"
或者把流程其他文件里的issueperson改为issue_person则都不会使junit报错。
但是无论修改于否,整个流程只能进行到部门经理这个环节,不能向下进行。
我也尝试修改TestProcess.java中关于关于部门经理是否同意的参数,调整为不同意,但是仍然流不到财务报销结果的Node当中,望指教啊。。。
是不是就是
package test.assignment;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.taskmgmt.def.AssignmentHandler;
import org.jbpm.taskmgmt.exe.Assignable;
import test.Constants;
public class ManagerAssignment implements AssignmentHandler,Constants
{
public void assign(Assignable assignable, ExecutionContext executionContext) throws Exception
{
//从当前流程实例上下文中取得当前报销人
String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
if(issueperson.equals("user1"))
{
//当前报销人为user1,部门经理为manager1;
assignable.setActorId("manager1");
}
else
{
//当报销人为其他人时manager2
assignable.setActorId("manager2");
}
}
}
当中String issueperson = executionContext.getContextInstance().getVariable(Constants.ISSUE_PERSON).toString();
无法获取ISSUE_PERSON在上下文当中的传进来的数据呢?怎么可以传进来呢?
还有,如果有可能的话,能不能发一份带有第一个报销流程的TestPaymentProcess.java的文件给我呢,谢谢拉。
159 楼
summerweiyang
2010-08-20
Dear Jacky
在第七章报销流程进行junit进行测试的时候,出现错误。错误代码如下。
org.jbpm.graph.def.DelegationException
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:259)
at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:198)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:197)
at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:168)
at org.jbpm.graph.def.Node.enter(Node.java:318)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$fd4ef93d.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.node.StartState.leave(StartState.java:70)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$fd4ef93d.leave(<generated>)
at org.jbpm.graph.exe.Token.signal(Token.java:192)
at org.jbpm.graph.exe.Token.signal(Token.java:140)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:479)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:393)
at test.testprocess.TestProcess.newProcessInstance(TestProcess.java:66)
at test.testprocess.TestProcess.testPayProcess(TestProcess.java:25)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.NullPointerException
at test.assignment.ManagerAssignment.assign(ManagerAssignment.java:15)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:271)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:244)
... 44 more
指向的句子是
String issueperson = executionContext.getContextInstance().getVariable(this.ISSUE_PERSON).toString();
请问该怎么处理啊,搞拉好久拉。
在第七章报销流程进行junit进行测试的时候,出现错误。错误代码如下。
org.jbpm.graph.def.DelegationException
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:259)
at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:198)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:197)
at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:168)
at org.jbpm.graph.def.Node.enter(Node.java:318)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$fd4ef93d.enter(<generated>)
at org.jbpm.graph.def.Transition.take(Transition.java:151)
at org.jbpm.graph.def.Node.leave(Node.java:393)
at org.jbpm.graph.node.StartState.leave(StartState.java:70)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$fd4ef93d.leave(<generated>)
at org.jbpm.graph.exe.Token.signal(Token.java:192)
at org.jbpm.graph.exe.Token.signal(Token.java:140)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:479)
at org.jbpm.taskmgmt.exe.TaskInstance.end(TaskInstance.java:393)
at test.testprocess.TestProcess.newProcessInstance(TestProcess.java:66)
at test.testprocess.TestProcess.testPayProcess(TestProcess.java:25)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at junit.framework.TestCase.runTest(TestCase.java:168)
at junit.framework.TestCase.runBare(TestCase.java:134)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.NullPointerException
at test.assignment.ManagerAssignment.assign(ManagerAssignment.java:15)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:271)
at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:244)
... 44 more
指向的句子是
String issueperson = executionContext.getContextInstance().getVariable(this.ISSUE_PERSON).toString();
请问该怎么处理啊,搞拉好久拉。
158 楼
xufang123456
2010-08-13
做采购流程时,项目代码写完后运行,出现如下错误:
java.lang.NullPointerException
at org.apache.jsp.write_002dpurchase_jsp._jspService(write_002dpurchase_jsp.java:110)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
提示的是项目中write-purchase.jsp中的
ProcessDefinition pd=jbpmContext.getGraphSession().findLatestProcessDefinition("purchase");
ProcessInstance pi=pd.createProcessInstance();
ContextInstance ci=pi.getContextInstance();
ci.setVariable("issueperson",issueperson);中ProcessInstance pi=pd.createProcessInstance();出现错误,请问高老师这是什么原因,我找了好久都不知道,现在很急这两个问题。你能帮我解决一下吗?谢谢
java.lang.NullPointerException
at org.apache.jsp.write_002dpurchase_jsp._jspService(write_002dpurchase_jsp.java:110)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
提示的是项目中write-purchase.jsp中的
ProcessDefinition pd=jbpmContext.getGraphSession().findLatestProcessDefinition("purchase");
ProcessInstance pi=pd.createProcessInstance();
ContextInstance ci=pi.getContextInstance();
ci.setVariable("issueperson",issueperson);中ProcessInstance pi=pd.createProcessInstance();出现错误,请问高老师这是什么原因,我找了好久都不知道,现在很急这两个问题。你能帮我解决一下吗?谢谢
157 楼
xufang123456
2010-08-13
做p173的例子运行出来时候出现这个错误是怎么回事啊,高老师?
java.lang.NullPointerException
at test.testprocess.TestProcess.newProcessInstance(TestProcess.java:50)
at test.testprocess.TestProcess.testPayProcess(TestProcess.java:21)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
TaskInstance ti = pi.getTaskMgmtInstance().createStartTaskInstance();
//向任务实例当中写入相关变量
ti.setVariable("title", "测试报销");
ti.setVariable("money_count", "1111");
ti.setVariable("remark", "测试报销的备注");
就是这一行ti.setVariable("title", "测试报销");
它报空指针。很急
java.lang.NullPointerException
at test.testprocess.TestProcess.newProcessInstance(TestProcess.java:50)
at test.testprocess.TestProcess.testPayProcess(TestProcess.java:21)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
TaskInstance ti = pi.getTaskMgmtInstance().createStartTaskInstance();
//向任务实例当中写入相关变量
ti.setVariable("title", "测试报销");
ti.setVariable("money_count", "1111");
ti.setVariable("remark", "测试报销的备注");
就是这一行ti.setVariable("title", "测试报销");
它报空指针。很急
156 楼
dblin_xm
2010-07-02
解决了,需要在 destinations-service.xml 文件内配置好相应的队列!
155 楼
dblin_xm
2010-06-30
dblin_xm 写道
在学习9.1 EJB方式的异步和任务调度章节时,按书上的要求部署,出现如下错误:
16:49:28,176 WARN [JMSContainerInvoker] JMS provider failure detected for CommandListenerBean
org.jboss.deployment.DeploymentException: Could not find the queue destination-jndi-name=queue/JbpmCommandQueue; - neste
d throwable: (javax.naming.NameNotFoundException: JbpmCommandQueue not bound)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:872)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:944)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
....
请问是不是还要手工配置队列:JbpmCommandQueue
原因?
16:49:28,176 WARN [JMSContainerInvoker] JMS provider failure detected for CommandListenerBean
org.jboss.deployment.DeploymentException: Could not find the queue destination-jndi-name=queue/JbpmCommandQueue; - neste
d throwable: (javax.naming.NameNotFoundException: JbpmCommandQueue not bound)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:872)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:944)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
....
请问是不是还要手工配置队列:JbpmCommandQueue
原因?
要在 destinations-service.xml 配置文件中配置队列吗?
154 楼
dblin_xm
2010-06-30
在学习9.1 EJB方式的异步和任务调度章节时,按书上的要求部署,出现如下错误:
16:49:28,176 WARN [JMSContainerInvoker] JMS provider failure detected for CommandListenerBean
org.jboss.deployment.DeploymentException: Could not find the queue destination-jndi-name=queue/JbpmCommandQueue; - neste
d throwable: (javax.naming.NameNotFoundException: JbpmCommandQueue not bound)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:872)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:944)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
....
请问是不是还要手工配置队列:JbpmCommandQueue
原因?
16:49:28,176 WARN [JMSContainerInvoker] JMS provider failure detected for CommandListenerBean
org.jboss.deployment.DeploymentException: Could not find the queue destination-jndi-name=queue/JbpmCommandQueue; - neste
d throwable: (javax.naming.NameNotFoundException: JbpmCommandQueue not bound)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.innerStartDelivery(JMSContainerInvoker.java:872)
at org.jboss.ejb.plugins.jms.JMSContainerInvoker.startService(JMSContainerInvoker.java:944)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
....
请问是不是还要手工配置队列:JbpmCommandQueue
原因?
153 楼
sofeik
2010-05-01
我现在发不了邮件 报错如下:
org.jbpm.JbpmException: couldn't send email
楼上说“然后是重写org.jbpm.mail包里面的Mail文件”
我该怎样重写jbpm-jpdl.jar 这可是一个.jar包呀 里面有mail.class文件 不明白
org.jbpm.JbpmException: couldn't send email
楼上说“然后是重写org.jbpm.mail包里面的Mail文件”
我该怎样重写jbpm-jpdl.jar 这可是一个.jar包呀 里面有mail.class文件 不明白
152 楼
matthewtmj_ynnu
2010-04-20
高老师,你好!买了你的书,并对第七章的应用进行了部署,感觉很有收获。但目前有个问题:在查看流程进度的时候,process-image.jsp页面老是出现问题。如,org.apache.jasper.JasperException: javax.servlet.ServletException: org.dom4j.DocumentException: Error on line 24 of document : Element type "node" must be followed by either attribute specifications, ">" or "/>". Nested exception: Element type "node" must be followed by either attribute specifications, ">" or "/>".
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:522)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:398)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
但之前发布的流程,有成功显示过。个人感觉是解析gpd.xml文件的时候出现问题,但经过修改乱码问题后,目前好像没错。
谢谢!
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:522)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:398)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
但之前发布的流程,有成功显示过。个人感觉是解析gpd.xml文件的时候出现问题,但经过修改乱码问题后,目前好像没错。
谢谢!
相关推荐
【深入浅出JBPM最新源码第七章-报销实例】是一个关于企业流程管理(Business Process Management,简称BPM)的实战教程,主要聚焦在JBPM框架的使用上,结合了myeclipse集成开发环境、SQL数据库、Tomcat6.0应用服务器...
《深入浅出jBPM 5,6章》是一本专为理解jBPM这一流程管理系统而精心编写的书籍。jBPM是一个开源的工作流管理系统,它提供了业务流程建模、执行、监控和优化的全面解决方案。这本书的第5章和第6章尤其关键,它们涵盖...
本资源“jbpm深入浅出第7章实例代码”聚焦于通过jbpm实现工作流的实战演练,旨在帮助读者更深入地理解和掌握jbpm的使用。 jbpm的工作流程管理包括了流程定义、流程执行、流程监控等多个方面。第7章可能涉及的内容...
深入浅出jBPM 电子文档,内容包括:面向图的程序设计,流程建模,节点——Node 职责,task-node节点,state节点类型,decision节点类型.等等,.还 综合大量例子和资料 , 是 学习 JBPM 必读首选! 希望这部书,大家能...
《深入浅出jBPM》中文版由jBPM方面的专家高杰根据自己的经验编写,是一本实用的jBPM教程。全书分两个部分,第一部分详细讲 解jBPM 3.2,第二部分介绍jBPM 4。作者从初学者的角度由浅入深地介绍jBPM的基本知识、使用...
深入浅出 jBPM 电子书,很适合初学者学习的一个开发文档
《深入浅出jBPM》中文版由jBPM方面的专家高杰根据自己的经验编写,是一本实用的jBPM教程。全书分两个部分,第一部分详细讲 解jBPM 3.2,第二部分介绍jBPM 4。作者从初学者的角度由浅入深地介绍jBPM的基本知识、使用...
《深入浅出jBPM》中文版由jBPM方面的专家高杰根据自己的经验编写,是一本实用的jBPM教程。全书分两个部分,第一部分详细讲 解jBPM 3.2,第二部分介绍jBPM 4。作者从初学者的角度由浅入深地介绍jBPM的基本知识、使用...
《深入浅出jBPM:1-6章测试代码详解》 jBPM,全称为Java Business Process Management,是一款开源的工作流管理系统,用于处理业务流程的建模、部署、执行和监控。它提供了灵活的工作流定义,支持BPMN 2.0标准,...
**深入浅出JBPM** JBPM,全称Java Business Process Management,是一款开源的工作流管理系统,由JBoss组织开发,现在是Red Hat公司的产品。它提供了一整套解决方案,用于设计、执行、监控和优化业务流程。JBPM的...
第 1 章 helloworld..............................................2 1.1 下载开发套件.............................................2 1.2 安装流程设计器 .........................................7 1.3 jBPM...
《深入浅出jBPM》深入浅出,示例丰富,实用性强,适合有一定Java基础的读者阅读。
深入浅出jBPM电子书,JBOSS jBPM是一个灵活的、可扩展的工作流管理系统。JBOSS jBPM拥有直观的流程语言,用任务、异步的等待状态、定时器、自动化动作…等来表示业务流程图,把这些操作绑定在一起,JBOSS jBPM就拥有...
【深入浅出JBPM 采购实例】是一个基于Myeclipse8.5、Tomcat6.0和JBPM3.2.3的实践教程,旨在帮助读者理解并掌握工作流管理系统JBPM在采购流程中的应用。在这个实例中,作者省略了邮件功能,因为JBPM3.2.3版本不包含...
【深入浅出jbpm系统开发】是一本专为jbpm工作流引擎初学者设计的入门指南,旨在帮助读者快速理解和掌握这一强大的开源工作流引擎。jbpm作为一个流行且功能丰富的工具,广泛应用于企业流程自动化、任务管理和决策支持...
压缩包中的文件 "Java23种设计模式(总结).doc" 显然是一个关于Java设计模式的文档,这与jbpm源码阅读紧密相关。设计模式是软件工程中的最佳实践,对于理解任何复杂系统的源码都是非常有帮助的。jbpm作为一个成熟的...