0

I'm learning Camunda the workflow engine. I understand that for some long-running processes, process modeling brings many tactical and strategic benefits such as expressiveness, fail-tolerance and observability with additional overhead ofcourse.

The book I'm reading also advocates the use of DMN (decision tables) to bundle business rules inside the process model. The motive is to centralize maintenance and decouple configuration from the code. I'm taking this advice with grain of salt, as decision tables smells somewhat clunky to work with. There is no strong typing and powerful IDE features. I'm used to implementations where business parameters are stored in database table and consumed by the application. The implementation also provides admin GUI to maintain these parameters at runtime.

For what reason I should favor DMN over more solid database based solution?

Tuomas Toivonen
  • 21,690
  • 47
  • 129
  • 225

1 Answers1

2

You are moving the business logic to BPMN to get it out of the code, make it transparent in graphical model, accessible to all stakeholders, support business-IT alignment, empower business to own they business process/logic, support multi-version enactment at runtime, and more...

The same reasoning applies to business rules, which are too complex to be modeled out as graphs in BPMN diagrams. The DMN standard is also aimed at business people and the expression language used is intentionally kept simpler than an Excel formula. It is the "Friendly Enough Expression Language" (FEEL). So you see where this is going.

Database tables

  • are not well accessible to business users
  • do not flexible changes to the table structure(s)/schema at runtime
  • usually do not support multi-version enactment at runtime
  • do not support a graphical, logical decomposition of rules (into DRDs) unless you work with multiple tables - but db schema are not flexible
  • cannot be easily deployed to many systems
  • cannot be easily tested in unit test
  • likely do not automatically generate audit data, which is accessible for audits and analytics

These are just a few points. So, for business rules, definitely DMN over DB tables.

rob2universe
  • 7,059
  • 39
  • 54