通过jBPM流程访问数据库 [英] Access database from jBPM process

查看:75
本文介绍了通过jBPM流程访问数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何从jBPM进程访问数据库?您认为我可以使用脚本任务或人工任务的进入/退出操作连接到数据库吗?

How can I access a database from a jBPM process ? Do you think I can connect to a database using a script task, or the entry/exit action of a human task?

推荐答案

我建议您不要使用人工任务的进入/退出动作来存储代码,因为如果有这样的地方,那么弄清楚您将代码放置在何处可能是一场噩梦.当人工任务有代码时,没有视觉提示.

I would advice against using entry/exit action of a human task to store code, it can be a nightmare to figure out where did you place code since there is no visual clue when a human task has code.

您可以尝试执行脚本任务,或者按照核心开发人员的建议,可以使用自定义WorkitemHandler.后者将有助于从bpmn2文件中分离代码,并且自定义服务任务将更易于在其他进程中重用,而不是复制/粘贴.您可以在此处找到文档(jBPM 6) http://docs.jboss .org/jbpm/v6.0.1/userguide/jBPMDomainSpecificProcesses.html

You could try a script task or, as core developers recommend, you can use a custom WorkitemHandler. The latter will help in separation of code from the bpmn2 file and a custom service task will be easier to reuse in other processes instead of copy/paste. You can find the documentation here (jBPM 6) http://docs.jboss.org/jbpm/v6.0.1/userguide/jBPMDomainSpecificProcesses.html

这篇关于通过jBPM流程访问数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆