栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Java

springboot整合activiti实例详解

Java 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

springboot整合activiti实例详解

  1. 使用eclipse或者IDEA创建springboot项目,命名为:spb-activiti7,选择spring-boot-parent版本为:2.6.2并引入web 和mysqljar引用
  2. 在pom文件中引入activiti7坐标,版本号为:7.0.0.Beta2,pom全文件如下:


	4.0.0
	
		org.springframework.boot
		spring-boot-starter-parent
		2.6.2
		 
	
	com.yf.cn
	sbt-act7
	0.0.1-SNAPSHOT
	springboot-activiti7
	Demo project for Spring Boot
	
		1.8
	
	
			
				org.springframework.boot
				spring-boot-starter-web
			
			
			
	         org.springframework.boot
	         spring-boot-devtools
	         runtime
	         true
	      
	      
	      
	         org.projectlombok
	         lombok
	         true
	      
	      
	         org.activiti
	         activiti-spring-boot-starter
	         7.0.0.Beta2
	      
	      
	            org.springframework.boot
	            spring-boot-starter-jdbc
	      

		
			mysql
			mysql-connector-java
			runtime
		
		
			org.springframework.boot
			spring-boot-starter-test
			test
		
	

	
		
			
				org.springframework.boot
				spring-boot-maven-plugin
			
		
	



  1. 添加application.yml配置:数据库信息对应成自己的即可
spring:
  datasource:
    username: root
    password: 123456
    url: jdbc:mysql://localhost:3306/spbt-activiti7?nullCatalogMeansCurrent=true
    driver-class-name: com.mysql.cj.jdbc.Driver
  devtools:
      restart:
        enabled: true  #设置开启热部署
  activiti:
    database-schema-update: true
    history-level: full
    db-history-used: true


debug: false
  1. 启动springboot,看控制台以及对应的数据库看看是否生成了对应的25张表
  2. 至此说明springboot和activiti7整合的初步环境已经搭建成功,接下来设计流程图,进行相应的流程测试
  3. 流程图设计如下:
转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/678608.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号