setting up Activiti BPMN Workflow Engine with Spring Boot

spring.activiti.database-schema-update: true

  • Controls how Activiti handles its database tables on startup.

  • Options:

    • true -- Default. Creates or updates tables automatically if missing. ✅ Good for development.

    • false -- Disables auto-update. Throws an error if tables are missing or version mismatch. ❌ For production.

    • create_drop -- Creates tables on start and drops them on shutdown. ⚠️ Risky, only for testing.

    • drop-create -- Drops existing tables and creates new ones every time app starts.


📚 spring.activiti.db-history-used: true

  • Enables Activiti's history tables.

  • These store past process execution info (like who approved what and when).

  • Without this, even with history-level set, no history tables are created.


🕘 spring.activiti.history-level: full

  • Defines how much history Activiti saves.

  • Options:

    • none -- No history (best performance).

    • activity -- Saves basic activity instance data.

    • audit -- Adds task info like who did what.

    • full -- Saves everything , including variables and execution details. ✅ Best for debugging/auditing.


🔍 spring.activiti.check-process-definitions: false

  • Whether to automatically scan and deploy BPMN process files from resources/processes/.

  • false -- You must manually deploy processes (e.g., via code or REST).

  • ✅ Useful when you don't want automatic redeployments (e.g., in production).


🚫 spring.activiti.deployment-mode: never-fail

  • Controls deployment conflict handling:

    • default -- May fail if process definition is already deployed.

    • single-resource -- Deploys each file separately.

    • never-fail -- Ignores duplicate deployments, avoids errors.

  • ✅ Safer option to prevent deployment exceptions during startup.


spring.activiti.async-executor-activate: false

  • Controls whether the async executor is started.

  • Async executor handles asynchronous jobs and timers in workflows.

  • false -- Disables it.

  • ✅ Disable if you don't use timers/events to avoid unnecessary thread usage.


✅ Summary (recommended for dev)

Setting Value Meaning
database-schema-update true Auto-create/update tables
db-history-used true Enable history tables
history-level full Save full execution history
check-process-definitions false Don't auto-load BPMN files
deployment-mode never-fail Avoid deployment errors on startup
async-executor-activate false Don't start async job processor
相关推荐
平凡运维之路15 分钟前
Linux入侵挖矿处理记录
后端
王中阳Go16 分钟前
15 Go Eino AI应用开发实战 | 性能优化
后端·面试·go
記億揺晃着的那天26 分钟前
Amazon SP-API,授权封装、SDK 分层与 AAD 加密一致性设计
spring boot·架构设计·amazon sp-api·sdk 设计
云和恩墨29 分钟前
告别 “事后救火”:7 大前置动作规避 80% 数据库故障
数据库·oracle
shoubepatien35 分钟前
JAVA -- 07
java·后端·intellij-idea
王中阳Go35 分钟前
09 Go Eino AI应用开发实战 | Hertz Web 框架搭建
人工智能·后端·go
STLearner1 小时前
VLDB 2025 | 时间序列(Time Series)论文总结(预测,异常检测,压缩,自动化等)
数据库·人工智能·深度学习·神经网络·机器学习·数据挖掘·时序数据库
1 小时前
TIDB——TIKV——raft
数据库·分布式·tidb
無量1 小时前
ConcurrentHashMap实现原理
java·后端
不会c嘎嘎1 小时前
MySQL 指南:全面掌握用户管理与权限控制
数据库·mysql