计算机集成制造系统 ›› 2020, Vol. 26 ›› Issue (6): 1456-1464.DOI: 10.13196/j.cims.2020.06.002

• 当期目次 • 上一篇    下一篇

Activiti引擎的无状态云工作流调度算法

林国丹,黄钦开,余阳+,潘茂林   

  1. 中山大学数据科学与计算机学院
  • 出版日期:2020-06-30 发布日期:2020-06-30
  • 基金资助:
    国家重点研发计划资助项目(2017YFB0202200);国家自然科学基金资助项目(61972427,61572539);广东省科技发展专项国际合作资助项目(2016B050502006);广州市科技计划资助项目(2016201604030001,201704020092)。

Stateless cloud workflow scheduling algorithm on Activiti engine

  • Online:2020-06-30 Published:2020-06-30
  • Supported by:
    Project supported by the National Key Research & Development Program,China(No.2017YFB0202200),the National Natural Science Foundation,China(No.61972427,61572539),the International Cooperation Science & Technology Development Program of Guangdong Province,China(No.2016B050502006),and the Science & Technology Plan of Guangzhou City,China(No.2016201604030001,201704020092).

摘要: 业务流程请求的执行需要工作流引擎解析流程定义文档,构建内存流程模型,而当前无状态云工作流调度没有考虑流程模型在引擎内存上的分布,导致引擎重复解析流程文档,造成系统性能下降。鉴于此,以无状态工作流引擎Activiti为研究对象,根据Activiti引擎流程模型缓存机制,提出一种无状态云工作流流程实例任务请求的调度算法,使得同一流程定义下的请求尽量分配到少数引擎。仿真对比实验结果表明,该算法在实现了引擎实例负载均衡的前提下,通过提高引擎的缓存命中率,减少了数据库查询次数和流程定义文档解析次数,从而减少了请求响应时间,节约了云上资源。

关键词: 云工作流, 工作流引擎, 无状态, 调度算法

Abstract: The execution of business process requests requires the workflow engine to parse the process definition document to build an in-memory process model.However,the current stateless cloud workflow scheduling does not consider the distribution of process model in engine memory,which leads to the repeated parsing of process documents by the engine,resulting in the degradation of system performance.For this reason,by taking the stateless workflow engine Activiti as the research object,a scheduling algorithm was proposed for task requests of stateless cloud workflow process instances based on Activiti engine process model caching mechanism,which made requests under the same process definition be allocated to few engines as much as possible.Simulation results showed that the proposed algorithm could improve the cache hit ratio of engine and reduce the number of database query and process definition document parsing under the premise of engine instances load balancing,so as to reduce the request response time and save the resources on the cloud.

Key words: cloud workflow, workflow engine, stateless, scheduling algorithm

中图分类号: