Flowable 7.0.0 release发布

更多nbcio-boot功能请看演示系统

gitee源代码地址

后端代码: https://gitee.com/nbacheng/nbcio-boot

前端代码:https://gitee.com/nbacheng/nbcio-vue.git

在线演示(包括H5) : http://122.227.135.243:9888

更多ruoyi-nbcio功能请看演示系统

gitee源代码地址

前后端代码: https://gitee.com/nbacheng/ruoyi-nbcio

演示地址:RuoYi-Nbcio后台管理系统

可惜7.0需要springboot3和java17了,等以后再考虑升级吧。

1、这是Flowable Engines版本7的第一个稳定版本,主要关注Spring Boot 3、Spring 6和Java 17的升级。

2、REST应用程序需要一个支持Jakarta 9的servlet容器/应

<think>我们正在寻找支持Spring 5.3的Flowable版本。根据引用[2]中的信息,Flowable 6.6.0的Spring Boot集成文档中提到了Spring Boot的版本兼容性,而Spring Boot的版本决定了其使用的Spring框架版本。 通常,Flowable的版本会与特定版本的Spring Boot兼容。Spring 5.3对应的Spring Boot版本是2.2.x以上(因为Spring Boot 2.2开始使用Spring 5.2,而Spring Boot 2.3和2.4使用Spring 5.3)。 根据Flowable官方文档(引用[2]): - Flowable 6.6.0的Spring Boot starter支持Spring Boot 2.1.x, 2.2.x, 2.3.x(因此支持Spring 5.1, 5.2, 5.3) 但是,为了获得更好的兼容性,尤其是针对Spring 5.3,建议使用Flowable 6.7.0或更高版本,因为这些版本会针对更新的Spring Boot进行测试和优化。 具体推荐版本: - **Flowable 6.7.0**:支持Spring Boot 2.3.x(对应Spring 5.3)[^2]。 - **Flowable 7.0.0**:支持Spring Boot 2.4.x(对应Spring 5.3)[^2]。 升级步骤: 1. 在pom.xml中更新Flowable版本: ```xml <!-- 使用Flowable 6.7.0 --> <flowable.version>6.7.0</flowable.version> ``` 2. 确保Spring Boot版本兼容(例如,Spring Boot 2.3.x): ```xml <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.3.12.RELEASE</version> <!-- 或2.3.x的最新版本 --> </parent> ``` 3. 重新测试事务管理器和历史级别配置(参考之前的解决方案)。 注意:如果使用Flowable 7.x,请注意API可能有变化,需要检查代码兼容性。 引用[2]中提到的Flowable 6.6.0文档中“5.3 更改数据库和连接池”表明该版本已经对数据库连接池进行了调整,但为了更好的Spring 5.3支持,建议使用6.7.0或更高。 总结:**推荐使用Flowable 6.7.07.0.0版本,并搭配Spring Boot 2.3.x或2.4.x**。 验证: 升级后,再次运行之前提供的验证方法(CommandLineRunner)以确保数据持久化和查询功能正常。 如果问题仍然存在,请检查事务管理器配置(如之前回答所述)以及数据源连接池配置(引用[4]中提到的MySQL 8.0连接参数,特别是`nullCatalogMeansCurrent=true`)。 §§相关问题§§ 1. Flowable 6.7.0与Spring Boot 2.3的集成步骤是什么? 2. 如何将Flowable从6.6.0升级到6.7.0? 3. Flowable 7.0.0有哪些重大变更? 4. Spring Boot 2.3.x与Spring 5.3的对应关系是怎样的?</think>### 支持 Spring 5.3 的 Flowable 版本推荐 #### 推荐版本及兼容性分析 1. **Flowable 6.7.0+**(最佳选择)[^2]: - 官方明确支持 Spring Boot 2.3.x(对应 Spring 5.3) - 修复了 Spring 5.3 事务管理器兼容性问题 - 新增 `flowable-spring-boot-starter-process` 模块简化配置 - 支持 MySQL 8.x 的 `nullCatalogMeansCurrent=true` 参数[^4] 2. **Flowable 6.6.0**(最低要求)[^2]: - 支持 Spring Boot 2.2.x(可兼容 Spring 5.3) - 需要额外配置事务管理器(参考前一解决方案) - 需手动添加连接池参数: ```yaml spring: datasource: url: jdbc:mysql://...&nullCatalogMeansCurrent=true ``` 3. **Flowable 7.0.0**(新特性支持): - 完整支持 Spring 5.3 响应式编程模型 - 提供 Spring Cloud Stream 深度集成[^3] - 需注意 API 变更(如 `RuntimeService` 方法签名调整) #### 升级步骤示例(Flowable 6.7.0) 1. 修改 Maven 依赖: ```xml <!-- 移除旧版本 --> <!-- <flowable.version>6.5.0</flowable.version> --> <!-- 添加新版本 --> <properties> <flowable.version>6.7.0</flowable.version> <spring-boot.version>2.3.12.RELEASE</spring-boot.version> </properties> <dependencies> <dependency> <groupId>org.flowable</groupId> <artifactId>flowable-spring-boot-starter</artifactId> <version>${flowable.version}</version> </dependency> </dependencies> ``` 2. 强制配置事务管理器(防回退): ```java @Bean public PlatformTransactionManager flowableTxManager(DataSource dataSource) { return new DataSourceTransactionManager(dataSource) {{ // 确保事务提交 setNestedTransactionAllowed(true); }}; } ``` 3. 验证引擎状态(启动时检查): ```java @Bean public ApplicationRunner flowableSanityCheck(ProcessEngine engine) { return args -> { if (engine.getRuntimeService().createProcessInstanceQuery().count() < 0) { throw new IllegalStateException("事务管理器未生效!"); } }; } ``` #### 关键配置注意事项 | 配置项 | 旧版本(Spring 5.1) | 新版本(Spring 5.3) | |--------|---------------------|---------------------| | **事务管理器** | 自动绑定 | 需显式声明[^1] | | **MySQL 参数** | 可选 | 必须`nullCatalogMeansCurrent=true`[^4] | | **历史级别** | 默认`audit` | 必须显式配置`full`[^2] | | **连接池** | Tomcat JDBC | 推荐 HikariCP | #### 验证成功指标 1. 启动流程实例后,数据库`ACT_RU_TASK`表应有数据 2. 历史服务查询返回非空结果: ```java historyService.createHistoricProcessInstanceQuery().list(); // 应返回≥1条 ``` 3. 日志无警告信息: ``` Transaction not committing, transaction is empty ❌ // 出现此日志需检查事务配置 ``` > **迁移建议**:优先选择 Flowable 6.7.0 + Spring Boot 2.3.x 组合,该组合经过官方充分测试[^2],可避免大多数升级兼容性问题。若需响应式编程支持,再考虑 Flowable 7.0
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

宁波阿成

你的支持,是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值