精华内容
下载资源
问答
  • JBPM

    2019-09-15 01:26:37
    jbpm(jboss business process managerament)是覆盖了业务管理,工作流,服务协作等领域的,一个开源的,灵活的可执行流程语言框架.既然它是一种工作流框架,我们就应该明白什么是工作流. 工作流就是业务的部分或者整体在...

            jbpm(jboss business process managerament)是覆盖了业务管理,工作流,服务协作等领域的,一个开源的,灵活的可执行流程语言框架.既然它是一种工作流框架,我们就应该明白什么是工作流.

            工作流就是业务的部分或者整体在计算机的应用条件实现自动化.他要解决的问题是使多个参与者按照某种预定的规则传递文档,数据,管理和监督业务流程的过程自动进行,从而实现某种业务目标,或者促进业务流程的执行.

            jboss公司提供的jbpm框架的优势就是灵活,开源,并且还提供了jpdl(jboss process definition language)的图形化工具(gpd),使得流程规则的制定更直观化,形象化.

            jbpm的核心就是工作流引擎,jbpm4.0以后他的工作流引擎成为Execution,不再是jbpm3.0中的token,它的作用就是负责业务流程的部署,执行,以及监督和管理业务流程.

            jpdl就是指定xml的模式和机制包装流程定义的相关文件到流程文档.

            而它的简单实现只要关注三个步骤:

            1. 绘制流程定义图,包括流程定义规则以及流程图

            2. jbpm4.0 Api的使用.

            3. 数据库的结构变化

            一.流程定义图的绘制要在eclipse中导入图形化工具插件

                绘制*.jpdl.xml和*.png文件.

            二.了解jbpm的Api.

                他提供的核心是processEngine(流程引擎),通过它可以获得jbpm的各种服务.

                大致有:

                        仓库类服务类(repositoryService):用于发布流程,删除业务流程.

                        流程执行服务类(executionService):用于启动流程实例,设置流程变量等.

                        任务服务类(TaskService):用于完成任务,查看正在执行的任务信息以及

                    设置流程变量等

                        历史服务类(HistoryService):用于查看已经完成的任务.

            三.了解数据库结构

                    jbpm4.0在jbpm3.0的基础上做了很大的改良,如增加了历史表,去除了流程定

            义的相关表.将module的冗余和流程实例合并.

                    一共有18张表,分为三类:

                    1.资源库和流

                    1)      JBPM4_DEPLOYMENT 流程定义表

                    2)      JBPM4_DEPLOYPROP 流程定义属性表

                    3)      JBPM4_LOB   存储流程定义相关的部署信息。主要存储jpdl文件和 png图片

                    4)      JBPM4_EXECUTION   主要是存放JBPM4的执行信息

                    5)      JBPM4_TASK 存放需要人来完成的Activities(活动),需要人来参与完成的Activity 被称为Task

                    6)      JBPM4_PARTICIPATION   参与者表,存放参与者信息,参与者的种类有  CandidateClientOwnerReplacedAssigneeViewer。而具体的参与者既可以是单一用户,也可以是用   户组

                     7)      JBPM4_SWIMLANE    泳道表

                     8)      JBPM4_JOB   存放的是Timer 的定义

                     9)      JBPM4_VARIABLE存的是进行时的临时变量程执行表

                    2.历史任务查看表

                            

                  1)      JBPM4_HIST_PROCINST        存放Process Instance的历史记录

                    2)      JBPM4_HIST_ACTINST          存放ActivityInstance的历史记录

                    3)      JBPM4_HIST_DETAIL 保存 Variable的变更记录

                    4)      JBPM4_HIST_VAR      保存历史的变量

                    5)      JBPM4_HIST_TASK    Task的历史信息

                    3.身份认证表

     

                        

                1)      JBPM4_ID_GROUP

                2)       JBPM_ID_MEMBERSHIP

                3)       JBPM4_ID_USER

                    

    转载于:https://my.oschina.net/KangL/blog/78563

    展开全文
  • jbpm

    2016-12-15 10:24:52
    Eclipse或myeclipse安装jbpm6.3插件 最近在学习jbpm,但是安装在Eclipse上安装插件(GPD插件)时把我坑苦了,网上的答案五花八门,我特此来修正“三观”,以下分享已经实战验证!   友情连接: Eclipse 下载...

    Eclipse或myeclipse安装jbpm6.3插件

    最近在学习jbpm,但是安装在Eclipse上安装插件(GPD插件)时把我坑苦了,网上的答案五花八门,我特此来修正“三观”,以下分享已经实战验证!

     
    友情连接:

    Eclipse 下载地址:http://www.eclipse.org/downloads/

    JBPM下载地址:http://sourceforge.net/projects/jbpm/files/

     

    一、安装插件

    (1)在Eclipse安装目录下创建一个名为:“eclipse_plugins”的插件目录,存放各种插件

    (2)找到JBPM6解压缩包 “\jbpm-6.0.1.Final-installer-full\jbpm-installer\lib” 下的 “org.drools.updatesite-6.0.1.Final.zip”,将其解压到 “eclipse_plugins” 目录下

    (3)然后再Eclipse的安装目录下创建一个名为“links”的文件夹(注意:必须叫这个名字)

    (4)在“links”文件夹里面创建一个“jbpm6.link”的文件,添加一行代码:“path=D:\\eclipse\\eclipse_plugins\\org.drools.updatesite-6.0.1.Final” (org.drools.updatesite-6.0.1.Final.zip的解压路径 ; 很多插件都可以通过同类方法安装)

    (5)删除Eclipse安装目录“D:\eclipse\configuration”中的“org.eclipse.update”目录

    (6)重新启动Eclipse.

    (7)在window——preferences中搜索jbpm,找到了则安装成功了(如图)

     

    二、配置JBPM6的运行环境

    安装Eclipse插件成功后,需要配置JBPM6的运行环境

    1. 先在解压包 “\jbpm-6.0.1.Final-installer-full\jbpm-installer\lib” 下“jbpm-6.0.1.Final-bin.zip”找到,并解压

    2. 打开Eclipse->Preferences 会弹出一个对话框,在文本框中搜索到"JBPM".

    3. installed jbpm Runtimes——Add,Name写上:“Jbpm6_Jun”,Path:浏览到“jbpm-6.0.1.Final-bin”解压的路径

    4.配置完成

     



    http://blog.csdn.net/xiaxiaorui2003/article/details/38388113
    展开全文
  • Jbpm

    千次阅读 2011-05-03 23:51:00
    import java.io.ByteArrayInputStream;import java.util.ArrayList;import java.util.Collection;import java.util.Iterator;import java.util.List;import java.util.Map;...import org.jbpm.JbpmConfiguration;impor

    package cn.cslg.shally.manager.impl;

    import java.io.ByteArrayInputStream;
    import java.util.ArrayList;
    import java.util.Collection;
    import java.util.Iterator;
    import java.util.List;
    import java.util.Map;
    import java.util.Set;

    import org.jbpm.JbpmConfiguration;
    import org.jbpm.JbpmContext;
    import org.jbpm.graph.def.ProcessDefinition;
    import org.jbpm.graph.def.Transition;
    import org.jbpm.graph.exe.ProcessInstance;
    import org.jbpm.taskmgmt.exe.TaskInstance;

    import cn.cslg.shally.manager.JbpmFacede;
    import cn.cslg.shally.model.Document;
    import cn.cslg.shally.utils.AbstractPageModel;
    import cn.cslg.shally.utils.SystemException;

    public class JbpmFacedeImpl  extends AbstractPageModel implements JbpmFacede{
     

     private JbpmConfiguration jbpmConfiguration;
     
     

     public JbpmConfiguration getJbpmConfiguration() {
      return jbpmConfiguration;
     }

     public void setJbpmConfiguration(JbpmConfiguration jbpmConfiguration) {
      this.jbpmConfiguration = jbpmConfiguration;
     }
    //添加流程实例
     //返回流程实例的ID
     @Override
     public long addProcessInstance(String processName, Document doc) throws SystemException {
      JbpmContext context=getJbpmContext();
     //获取流程的定义 
      ProcessDefinition pdf=context.getGraphSession().findLatestProcessDefinition(processName);
      //获取流程实例变量
      ProcessInstance instance=new ProcessInstance(pdf);
      //将公文ID提交到流程实例变量中
      instance.getContextInstance().setVariable("document", doc.getId());
      
      //将公文标题也提交到流程实例变量中,以便在E-Mail中能够提示这个公文的名称
      instance.getContextInstance().setVariable("docTitle", doc.getTitle());
      
      //将公文的相关属性设置进入流程实例变量
      Map props = doc.getProperties();
      if(props != null){
       Set entries = props.entrySet();
       for (Iterator iterator = entries.iterator(); iterator.hasNext();) {
        Map.Entry entry = (Map.Entry) iterator.next();
        String propertyName = (String)entry.getKey();
        Object obj = doc.getProperty(propertyName);
        //将变量放入流程实例变量
        instance.getContextInstance().setVariable(propertyName, obj);
       }
      }
      
      context.save(instance);
      
      return instance.getId();
      
     }
    //回退也就是不同意 暂时没看明白
     @Override
     public Object[] backStep(long processInstanceId, String actorId) {
    JbpmContext context = getJbpmContext();
      
      //根据流程实例标识查找流程实例
      ProcessInstance instance = context.getProcessInstance(processInstanceId);
      Object[] os = new Object[2];
      //搜索用户对应的所有的任务实例
      List taskInstances = context.getTaskMgmtSession().findTaskInstances(actorId);
      for (Iterator iterator = taskInstances.iterator(); iterator
        .hasNext();) {
       TaskInstance ti = (TaskInstance) iterator.next();
       if(ti.getProcessInstance().getId() == processInstanceId){
        
        //先判断是否是要回退到起点
        Set set = ti.getToken().getNode().getArrivingTransitions();
        for (Iterator iterator2 = set.iterator(); iterator2.hasNext();) {
         Transition t = (Transition) iterator2.next();
         //如果它需要回退到起点
         if(t.getFrom().equals(ti.getProcessInstance().getProcessDefinition().getStartState())){
          int docId = (Integer)ti.getProcessInstance().getContextInstance().getVariable("document");
          //结束当前的流程实例
          ti.getProcessInstance().end();
          //结束当前任务实例
          ti.end();
          
          //重新创建流程实例对象
          ProcessInstance pi = new ProcessInstance(ti.getProcessInstance().getProcessDefinition());
          pi.getContextInstance().setVariable("document", docId);
          //将流程实例对象重新持久化到数据库
          context.save(pi);
          
          os[0] = Document.STATUS_NEW;
          os[1] = pi.getId();
          
          return os;
         }
        }
        
        //如果不需要回退到起点
        ti.end(CreateTransitionAction.BACK_TRANSITION);
        break;
       }
      }
      
      os[0] = instance.getRootToken().getNode().getName();
      os[1] = processInstanceId;
      
      return os;
     }
    //删除流程定义  为了避免覆盖 导致其他没流完的流程无法继续进行下去 所以采用版本控制的方式避免覆盖 所以在删除时要循环的删除
     @Override
     public void delProcessDefinition(String processName) {
         JbpmContext context=getJbpmContext();
         List defs=context.getGraphSession().findAllProcessDefinitionVersions(processName);
         for (Iterator iterator = defs.iterator(); iterator.hasNext();) {
       ProcessDefinition def = (ProcessDefinition) iterator.next();
       context.getGraphSession().deleteProcessDefinition(def);
      }
     }
    //删除流程实例
     @Override
     public void delProcessInstance(long processInstanceId) {
      JbpmContext context = getJbpmContext();
      context.getGraphSession().deleteProcessInstance(processInstanceId);
     }
    //上传流程定义 返回流程定义的名字
     @Override
     public String deployProcessDefinition(byte[] processDef) {
    JbpmContext context = getJbpmContext();
      
      ProcessDefinition def = ProcessDefinition.parseXmlInputStream(
       new ByteArrayInputStream(processDef)
      );
      
      context.deployProcessDefinition(def);
      
      return def.getName();
     }
    //提交到下一个节点
     //返回下一个节点的名称
     @Override
     public String nextStep(long processInstanceId, String actorId,
       String transitionName) {

      JbpmContext context = getJbpmContext();
      //获取流程实例变量
      ProcessInstance instance = context.getProcessInstance(processInstanceId);
      
      //当前节点的名称
      String currentNodeName = instance.getRootToken().getNode().getName();
      
      //起点的名称
      String startNodeName = instance.getProcessDefinition().getStartState().getName();
        
      //如果是在起点
      if(startNodeName.equals(currentNodeName)){
       if(transitionName == null){
        instance.signal();
       }else{
        instance.signal(transitionName);
       }
      }else{
       //获取改用户的所有任务列表
       List taskInstances = context.getTaskMgmtSession().findTaskInstances(actorId);
       for (Iterator iterator = taskInstances.iterator(); iterator
         .hasNext();) {
        TaskInstance ti = (TaskInstance) iterator.next();
        //如果当前的流程实例==循环中的流程实例
        if(ti.getProcessInstance().getId() == processInstanceId){
         if(transitionName == null){
          ti.end();
         }else{
          ti.end(transitionName);
         }
         break;
        }
       }
       
       
       //查找所属组的任务实例
       List pooledTaskInstances = context.getTaskMgmtSession().findPooledTaskInstances(actorId);
       for (Iterator iterator = pooledTaskInstances.iterator(); iterator
         .hasNext();) {
        TaskInstance ti = (TaskInstance) iterator.next();
        if(ti.getProcessInstance().getId() == processInstanceId){
         if(transitionName == null){
          ti.end();
         }else{
          ti.end(transitionName);
         }
         break;
        }
       }
      }
      
      //返回转向之后的节点名称
      return instance.getRootToken().getNode().getName();
     }
    //搜索我的待审的公文的列表
     @Override
     public List searchMyTaskList(String actorId) {
      JbpmContext context = getJbpmContext();
      List docIds = new ArrayList();
      List taskInstances = context.getTaskMgmtSession().findTaskInstances(actorId);
      for (Iterator iterator = taskInstances.iterator(); iterator.hasNext();) {
       TaskInstance ti = (TaskInstance) iterator.next();
       Integer docId = (Integer)ti.getProcessInstance().getContextInstance().getVariable("document");
       docIds.add(docId);
      }
      
      //查找所属组的任务实例
      List pooledTaskInstances = context.getTaskMgmtSession().findPooledTaskInstances(actorId);
      for (Iterator iterator = pooledTaskInstances.iterator(); iterator
        .hasNext();) {
       TaskInstance ti = (TaskInstance) iterator.next();
       Integer docId = (Integer)ti.getProcessInstance().getContextInstance().getVariable("document");
       docIds.add(docId);
      }  
      
      return docIds;
     }
    //查护下往下走的可选的路径
     @Override
     public List searchNextTransitions(long processInstanceId, String actorId) {
      JbpmContext context = getJbpmContext();
      ProcessInstance instance = context.getProcessInstance(processInstanceId);
      
      //当前节点
      String currentNodeName = instance.getRootToken().getNode().getName();
      
      //起点的名称
      String startNodeName = instance.getProcessDefinition().getStartState().getName();
      
      Collection transitions = null;
      
      //如果是在起点
      if(startNodeName.equals(currentNodeName)){
       transitions = instance.getRootToken().getAvailableTransitions();
      }else{
       //如果是中间节点
       List taskInstances = context.getTaskMgmtSession().findTaskInstances(actorId);
       for (Iterator iterator = taskInstances.iterator(); iterator
         .hasNext();) {
        TaskInstance ti = (TaskInstance) iterator.next();
        if(ti.getProcessInstance().getId() == processInstanceId){
         transitions = ti.getAvailableTransitions();
         break;
        }
       }
       
       //查找所属组的任务实例
       List pooledTaskInstances = context.getTaskMgmtSession().findPooledTaskInstances(actorId);
       for (Iterator iterator = pooledTaskInstances.iterator(); iterator
         .hasNext();) {
        TaskInstance ti = (TaskInstance) iterator.next();
        if(ti.getProcessInstance().getId() == processInstanceId){
         transitions = ti.getAvailableTransitions();
        }
       }
      }
      
      List transitionNames = new ArrayList();
      
      if(transitions != null){
       //为了不把Transition对象直接暴露给OA系统,需要将其转换为名称列表
       for (Iterator iterator = transitions.iterator(); iterator.hasNext();) {
        Transition transition = (Transition) iterator.next();
        transitionNames.add(transition.getName());
       }
      }
      
      return transitionNames;
     }

     
     private JbpmContext getJbpmContext(){
      JbpmContext context = jbpmConfiguration.createJbpmContext();
      context.setSession(getSession());
      return context;
     }

    }

     

     

     

     

     

     

     

     

     

     

    <jbpm-configuration>

      <!--
        This configuration is used when there is no jbpm.cfg.xml file found in the
        root of the classpath.  It is a very basic configuration without persistence
        and message services.  Only the authorization service installed.
        You can parse and create processes, but when you try to use one of the
        unavailable services, you'll get an exception.
      -->
     
      <jbpm-context>
        <service name="persistence" factory="org.jbpm.persistence.db.DbPersistenceServiceFactory" />
        <service name="tx" factory="org.jbpm.tx.TxServiceFactory" />
        <service name="message" factory="org.jbpm.msg.db.DbMessageServiceFactory" />
        <service name="scheduler" factory="org.jbpm.scheduler.db.DbSchedulerServiceFactory" />
        <service name="logging" factory="org.jbpm.logging.db.DbLoggingServiceFactory" />
        <service name="authentication" factory="org.jbpm.security.authentication.DefaultAuthenticationServiceFactory" />
      </jbpm-context>

      <!-- configuration property used by persistence service impl org.jbpm.persistence.db.DbPersistenceServiceFactory -->
      <string name="resource.hibernate.cfg.xml" value="hibernate.cfg.xml" />

      <!-- configuration resource files pointing to default configuration files in jbpm-{version}.jar -->
      <string name="resource.business.calendar" value="org/jbpm/calendar/jbpm.business.calendar.properties" />
      <string name="resource.default.modules" value="org/jbpm/graph/def/jbpm.default.modules.properties" />
      <string name="resource.converter" value="org/jbpm/db/hibernate/jbpm.converter.properties" />
      <string name="resource.action.types" value="org/jbpm/graph/action/action.types.xml" />
      <string name="resource.node.types" value="org/jbpm/graph/node/node.types.xml" />
      <string name="resource.parsers" value="org/jbpm/jpdl/par/jbpm.parsers.xml" />
      <string name="resource.varmapping" value="org/jbpm/context/exe/jbpm.varmapping.xml" />
      <string name="resource.mail.templates" value="jbpm.mail.templates.xml" />

      <int    name="jbpm.byte.block.size" value="1024" singleton="true" />
      <string name="jbpm.mail.smtp.host" value="localhost" />
      <bean   name="jbpm.task.instance.factory" class="org.jbpm.taskmgmt.impl.DefaultTaskInstanceFactoryImpl" singleton="true" />
      <bean   name="jbpm.variable.resolver" class="org.jbpm.jpdl.el.impl.JbpmVariableResolver" singleton="true" />
      <bean   name="jbpm.mail.address.resolver" class="org.jbpm.identity.mail.IdentityAddressResolver" singleton="true" />
     
      <bean name="jbpm.job.executor" class="org.jbpm.job.executor.JobExecutor">
        <field name="jbpmConfiguration"><ref bean="jbpmConfiguration" /></field>
        <field name="name"><string value="JbpmJobExector" /></field>
        <field name="nbrOfThreads"><int value="1" /></field>
        <field name="idleInterval"><int value="5000" /></field>
        <field name="maxIdleInterval"><int value="3600000" /></field> <!-- 1 hour -->
        <field name="historyMaxSize"><int value="20" /></field>
        <field name="maxLockTime"><int value="600000" /></field> <!-- 10 minutes -->
        <field name="lockMonitorInterval"><int value="60000" /></field> <!-- 1 minute -->
        <field name="lockBufferTime"><int value="5000" /></field> <!-- 5 seconds -->
      </bean>

    </jbpm-configuration>

     

     

     

    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">

    <hibernate-configuration>
      <session-factory>
        <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
        <property name="hibernate.connection.url">jdbc:mysql://127.0.0.1/realoa</property>
        <property name="hibernate.connection.username">root</property>
        <property name="hibernate.connection.password">root</property>
        <property name="hibernate.connection.autocommit">true</property>
        <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
        <property name="hibernate.show_sql">true</property>
        <property name="hibernate.hbm2ddl.auto">update</property>
        <property name="hibernate.cache.provider_class">org.hibernate.cache.HashtableCacheProvider</property>
        <mapping resource="cn/cslg/shally/model/ACL.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/ApptoveInfo.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/Document.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/FieldInput.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/FieldType.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/FlowForm.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/FormField.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/Module.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/Organization.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/Person.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/Roles.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/User.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/UsersRoles.hbm.xml"/>
        <mapping resource="cn/cslg/shally/model/WorkFlow.hbm.xml"/>
         <mapping resource="org/jbpm/graph/action/Script.hbm.xml"/>
        <mapping resource="org/jbpm/identity/User.hbm.xml"/>
        <mapping resource="org/jbpm/identity/Group.hbm.xml"/>
        <mapping resource="org/jbpm/identity/Membership.hbm.xml"/>
        <mapping resource="org/jbpm/db/hibernate.queries.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/ProcessDefinition.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/Node.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/Transition.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/Event.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/Action.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/SuperState.hbm.xml"/>
        <mapping resource="org/jbpm/graph/def/ExceptionHandler.hbm.xml"/>
        <mapping resource="org/jbpm/instantiation/Delegation.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/StartState.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/EndState.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/ProcessState.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/Decision.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/Fork.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/Join.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/State.hbm.xml"/>
        <mapping resource="org/jbpm/graph/node/TaskNode.hbm.xml"/>
        <mapping resource="org/jbpm/context/def/ContextDefinition.hbm.xml"/>
        <mapping resource="org/jbpm/context/def/VariableAccess.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/def/TaskMgmtDefinition.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/def/Swimlane.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/def/Task.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/def/TaskController.hbm.xml"/>
        <mapping resource="org/jbpm/module/def/ModuleDefinition.hbm.xml"/>
        <mapping resource="org/jbpm/bytes/ByteArray.hbm.xml"/>
        <mapping resource="org/jbpm/file/def/FileDefinition.hbm.xml"/>
        <mapping resource="org/jbpm/scheduler/def/CreateTimerAction.hbm.xml"/>
        <mapping resource="org/jbpm/scheduler/def/CancelTimerAction.hbm.xml"/>
        <mapping resource="org/jbpm/graph/exe/Comment.hbm.xml"/>
        <mapping resource="org/jbpm/graph/exe/ProcessInstance.hbm.xml"/>
        <mapping resource="org/jbpm/graph/exe/Token.hbm.xml"/>
        <mapping resource="org/jbpm/graph/exe/RuntimeAction.hbm.xml"/>
        <mapping resource="org/jbpm/module/exe/ModuleInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/ContextInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/TokenVariableMap.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/VariableInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/ByteArrayInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/DateInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/DoubleInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/HibernateLongInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/HibernateStringInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/LongInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/NullInstance.hbm.xml"/>
        <mapping resource="org/jbpm/context/exe/variableinstance/StringInstance.hbm.xml"/>
        <mapping resource="org/jbpm/job/Job.hbm.xml"/>
        <mapping resource="org/jbpm/job/Timer.hbm.xml"/>
        <mapping resource="org/jbpm/job/ExecuteNodeJob.hbm.xml"/>
        <mapping resource="org/jbpm/job/ExecuteActionJob.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/exe/TaskMgmtInstance.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/exe/TaskInstance.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/exe/PooledActor.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/exe/SwimlaneInstance.hbm.xml"/>
        <mapping resource="org/jbpm/logging/log/ProcessLog.hbm.xml"/>
        <mapping resource="org/jbpm/logging/log/MessageLog.hbm.xml"/>
        <mapping resource="org/jbpm/logging/log/CompositeLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/ActionLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/NodeLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/ProcessInstanceCreateLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/ProcessInstanceEndLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/ProcessStateLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/SignalLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/TokenCreateLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/TokenEndLog.hbm.xml"/>
        <mapping resource="org/jbpm/graph/log/TransitionLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/VariableLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/VariableCreateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/VariableDeleteLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/VariableUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/ByteArrayUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/DateUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/DoubleUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/HibernateLongUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/HibernateStringUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/LongUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/context/log/variableinstance/StringUpdateLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/TaskLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/TaskCreateLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/TaskAssignLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/TaskEndLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/SwimlaneLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/SwimlaneCreateLog.hbm.xml"/>
        <mapping resource="org/jbpm/taskmgmt/log/SwimlaneAssignLog.hbm.xml"/>
      </session-factory>
    </hibernate-configuration>

     

     

    <?xml version="1.0" encoding="UTF-8"?>

    <beans xmlns="http://www.springframework.org/schema/beans"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xmlns:aop="http://www.springframework.org/schema/aop"
          xmlns:tx="http://www.springframework.org/schema/tx"
          xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
               http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
               http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd">
     <!-- 配置SessionFactory -->
     <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
      <property name="configLocation">
       <value>classpath:hibernate.cfg.xml</value>
      </property>
     </bean>
     
     <!-- 配置事务管理器 -->
     <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
      <property name="sessionFactory">
       <ref bean="sessionFactory"/>
      </property> 
     </bean>   
     
     <!-- 事务的传播特性 -->
     <tx:advice id="txAdvice" transaction-manager="transactionManager">
      <tx:attributes>
      
       <tx:method name="add*" propagation="REQUIRED"/>
       <tx:method name="del*" propagation="REQUIRED" />
       <tx:method name="update*" propagation="REQUIRED"/>
       <tx:method name="*"/>
       <!--
       <tx:method name="*" propagation="REQUIRED"/>
        -->
      </tx:attributes>
     </tx:advice>
     
     <!-- 那些类那些方法使用事务 -->
     <aop:config>
      <aop:pointcut id="allManagerMethod" expression="execution(* cn.clsg.shally.manager.*.*(..))"/>
      <aop:advisor advice-ref="txAdvice" pointcut-ref="allManagerMethod"/>
     </aop:config>
    <bean id="jbpmConfiguration" class="org.springmodules.workflow.jbpm31.LocalJbpmConfigurationFactoryBean">
      <property name="configuration" value="classpath:jbpm.cfg.xml"></property>
     </bean>
    </beans>

     

     

    <?xml version="1.0" encoding="UTF-8"?>

    <beans xmlns="http://www.springframework.org/schema/beans"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
     xmlns:tx="http://www.springframework.org/schema/tx"
     xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
               http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
               http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd">
     <bean id="orgManager" class="cn.cslg.shally.manager.impl.OrgManagerImpl">
      <property name="sessionFactory" ref="sessionFactory" />
     </bean>
     <bean id="personManager" class="cn.cslg.shally.manager.impl.PersonManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>

     <bean id="userManager" class="cn.cslg.shally.manager.impl.UserManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>
     <bean id="roleManager" class="cn.cslg.shally.manager.impl.RoleManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>
     <bean id="moduleManager" class="cn.cslg.shally.manager.impl.ModuleManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>
     <bean id="initSystemDatas" class="cn.cslg.shally.utils.InitSystemDatasImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
      <property name="userManager" ref="userManager"></property>
      <property name="orgManager" ref="orgManager"></property>
     </bean>
     <bean id="aclManager" class="cn.cslg.shally.manager.impl.AclManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>
     <bean id="securityFunctions" class="cn.cslg.shally.utils.SecurityFunctions">
      <property name="aclManager" ref="aclManager"></property>
     </bean>
     <bean id="documentManager" class="cn.cslg.shally.manager.impl.DocumentManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
      <property name="jbpmFacede" ref="jbpmFacede"></property>
     </bean>
     <bean name="jbpmFacede" class="cn.cslg.shally.manager.impl.JbpmFacedeImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
      <property name="jbpmConfiguration" ref="jbpmConfiguration"></property>
     </bean>
     <bean name="formManager" class="cn.cslg.shally.manager.impl.FormManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
     </bean>
     <bean name="workFlowManager" class="cn.cslg.shally.manager.impl.WorkFlowManagerImpl">
      <property name="sessionFactory" ref="sessionFactory"></property>
      <property name="jbpmFacede" ref="jbpmFacede"></property>
     </bean>
     <bean name="DynaFormFunction" class="cn.cslg.shally.utils.DynaFormFunction">
      <property name="formManager" ref="formManager"></property>
     </bean>
    </beans>

     

     

    <?xml version="1.0" encoding="UTF-8"?>

    <beans xmlns="http://www.springframework.org/schema/beans"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
     xmlns:tx="http://www.springframework.org/schema/tx"
     xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
               http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
               http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd">
     <bean name="/org" class="cn.cslg.shally.web.actions.OrgAction"
      scope="prototype">
      <property name="orgManager" ref="orgManager"></property>
     </bean>
     <bean name="/person" class="cn.cslg.shally.web.actions.PersonAction">
      <property name="personManager" ref="personManager"></property>
     </bean>
     <bean name="/user" class="cn.cslg.shally.web.actions.UserAction">
      <property name="userManager" ref="userManager"></property>
      <property name="personManager" ref="personManager"></property>
      <property name="roleManager" ref="roleManager"></property>
     </bean>
     <bean name="/role" class="cn.cslg.shally.web.actions.RoleAction">
      <property name="roleManager" ref="roleManager"></property>
     </bean>
     <bean name="/module" class="cn.cslg.shally.web.actions.ModuleAction">
          <property name="moduleManager" ref="moduleManager"></property>
     </bean>
     <bean name="/acl" class="cn.cslg.shally.web.actions.AclAction">
       <property name="userManager" ref="userManager"></property>
       <property name="roleManager" ref="roleManager"></property>
       <property name="moduleManager" ref="moduleManager"></property>
     </bean>
     <bean name="/login" class="cn.cslg.shally.web.actions.LoginAction">
       <property name="userManager" ref="userManager"></property>
     </bean>
     <bean name="/index" class="cn.cslg.shally.web.actions.IndexAction">
          <property name="aclManager" ref="aclManager"></property>
     </bean>
     <bean name="/document" class="cn.cslg.shally.web.actions.DocumentAction">
      <property name="documentManager" ref="documentManager"></property>
      <property name="workFlowManager" ref="workFlowManager"></property>
     </bean>
     <bean name="/workflow" class="cn.cslg.shally.web.actions.WorkFlowAction">
      <property name="workFlowManager" ref="workFlowManager"></property>
     </bean>
     <bean name="/flowform" class="cn.cslg.shally.web.actions.FlowFormAction">
      <property name="workFlowManager" ref="workFlowManager"></property>
      <property name="formManager" ref="formManager"></property>
     </bean>
     
    </beans>

    展开全文
  • jBPM

    千次阅读 2004-11-06 19:14:00
    http://jbpm.org/What is Java Business Process Management JBoss jBPM is a flexible, extensible workflow management system. Business processes, expressed in a simple and powerfull language and pac
    http://jbpm.org/

    What is Java Business Process Management
    JBoss jBPM is a flexible, extensible workflow management system. Business processes, expressed in a simple and powerfull language and packaged in process archives, serve as input for the JBoss jBPM runtime server. JBoss jBPM bridges the gap between managers and developers by giving them a common language : the JBoss jBPM Process definition language (jPdl). This gives software project managers much more control on their software development efforts. After loading the process archive, users or systems perform single steps of the process. JBoss jBPM maintains the state, logs and performs all automated actions. JBoss jBPM combines easy development of workflow-applications with excellent enterprise application integration (EAI) capabilities. JBoss jBPM includes a web-application and a scheduler. JBoss jBPM can be used in the simplest environment like an ant task and scale up to a clustered J2EE application. For easy of evaluation, there is a download of a preconfigured JBoss application server. For more information about what JBoss jBPM is, refer to docs
    展开全文
  • jbpm

    2010-08-18 21:02:00
     <mapping resource="org/jbpm/context/exe/variableinstance/HibernateStringInstance.hbm.xml"/>  <mapping resource="org/jbpm/context/exe/variableinstance/LongInstance.hbm.xml"/>  ...

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 11,248
精华内容 4,499
关键字:

jBPM