From eaa79956307fc017d6a5f70218cf256805811007 Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 08:49:31 +0100 Subject: [PATCH 1/6] install dependencies --- package-lock.json | 319 ++++++++++++++++++++++++++++++++++++++++++++-- package.json | 2 + 2 files changed, 309 insertions(+), 12 deletions(-) diff --git a/package-lock.json b/package-lock.json index c1f9481..8e9d17d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,9 +11,11 @@ "@docusaurus/core": "3.9.2", "@docusaurus/preset-classic": "3.9.2", "@mdx-js/react": "^3.1.1", + "bpmn-js": "^18.9.1", "clsx": "^2.1.1", "docusaurus-theme-search-typesense": "^0.25.0-0", "dotenv": "^17.2.3", + "glob": "^13.0.0", "prism-react-renderer": "^2.4.1", "react": "^19.2.0", "react-dom": "^19.2.0" @@ -2050,6 +2052,16 @@ "node": ">=6.9.0" } }, + "node_modules/@bpmn-io/diagram-js-ui": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@bpmn-io/diagram-js-ui/-/diagram-js-ui-0.2.3.tgz", + "integrity": "sha512-OGyjZKvGK8tHSZ0l7RfeKhilGoOGtFDcoqSGYkX0uhFlo99OVZ9Jn1K7TJGzcE9BdKwvA5Y5kGqHEhdTxHvFfw==", + "license": "MIT", + "dependencies": { + "htm": "^3.1.1", + "preact": "^10.11.2" + } + }, "node_modules/@colors/colors": { "version": "1.5.0", "resolved": "https://registry.npmjs.org/@colors/colors/-/colors-1.5.0.tgz", @@ -4039,6 +4051,27 @@ "@hapi/hoek": "^9.0.0" } }, + "node_modules/@isaacs/balanced-match": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@isaacs/balanced-match/-/balanced-match-4.0.1.tgz", + "integrity": "sha512-yzMTt9lEb8Gv7zRioUilSglI0c0smZ9k5D65677DLWLtWJaXIS3CqcGyUFByYKlnUj6TkjLVs54fBl6+TiGQDQ==", + "license": "MIT", + "engines": { + "node": "20 || >=22" + } + }, + "node_modules/@isaacs/brace-expansion": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/@isaacs/brace-expansion/-/brace-expansion-5.0.0.tgz", + "integrity": "sha512-ZT55BDLV0yv0RBm2czMiZ+SqCGO7AvmOM3G/w2xhVPH+te0aKgFjmBvGlL1dH+ql2tgGO3MVrbb3jCKyvpgnxA==", + "license": "MIT", + "dependencies": { + "@isaacs/balanced-match": "^4.0.1" + }, + "engines": { + "node": "20 || >=22" + } + }, "node_modules/@jest/schemas": { "version": "29.6.3", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", @@ -5900,6 +5933,39 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/bpmn-js": { + "version": "18.9.1", + "resolved": "https://registry.npmjs.org/bpmn-js/-/bpmn-js-18.9.1.tgz", + "integrity": "sha512-hpTwvid74iHLdqBW/ZOverBzWboXFY1sMtGsizrbcaftXc7T9STdQ5Ny5++LOw1lAv/AQZiDxgk5JjaRGwKVPw==", + "license": "SEE LICENSE IN LICENSE", + "dependencies": { + "bpmn-moddle": "^9.0.4", + "diagram-js": "^15.4.0", + "diagram-js-direct-editing": "^3.2.0", + "ids": "^1.0.5", + "inherits-browser": "^0.1.0", + "min-dash": "^4.1.1", + "min-dom": "^4.2.1", + "tiny-svg": "^3.1.2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/bpmn-moddle": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/bpmn-moddle/-/bpmn-moddle-9.0.4.tgz", + "integrity": "sha512-dr5s3vtOG8NkVSwa8CC55XBIKKwajomSZRb0RiMOOOF6TpqZBZvtbDjpzWICvdd/plDF6uOtaRfSgblPQLAioQ==", + "license": "MIT", + "dependencies": { + "min-dash": "^4.2.1", + "moddle": "^7.0.0", + "moddle-xml": "^11.0.0" + }, + "engines": { + "node": ">= 18" + } + }, "node_modules/brace-expansion": { "version": "1.1.12", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", @@ -6469,6 +6535,12 @@ "integrity": "sha512-QE33hToZseCH3jS0qN96O/bSh3kaw/h+Tq7ngyY9eWDUnTlTNUyqfqvCXioLe5Na5jFsL78ra/wuBU4iuEgd4w==", "license": "ISC" }, + "node_modules/component-event": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/component-event/-/component-event-0.2.1.tgz", + "integrity": "sha512-wGA++isMqiDq1jPYeyv2as/Bt/u+3iLW0rEa+8NQ82jAv3TgqMiCM+B2SaBdn2DfLilLjjq736YcezihRYhfxw==", + "license": "MIT" + }, "node_modules/compressible": { "version": "2.0.18", "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.18.tgz", @@ -7469,6 +7541,51 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/diagram-js": { + "version": "15.4.0", + "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-15.4.0.tgz", + "integrity": "sha512-rpwDLA/w55wPfiZgp/z2T6cFdCXU3bARGdjhUpEOoh673K18OJ4ruEu3+/94ALRIIyEvJ0XHUk9sgZrzzE79ng==", + "license": "MIT", + "dependencies": { + "@bpmn-io/diagram-js-ui": "^0.2.3", + "clsx": "^2.1.0", + "didi": "^10.2.2", + "inherits-browser": "^0.1.0", + "min-dash": "^4.1.0", + "min-dom": "^4.2.1", + "object-refs": "^0.4.0", + "path-intersection": "^3.0.0", + "tiny-svg": "^3.1.2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/diagram-js-direct-editing": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/diagram-js-direct-editing/-/diagram-js-direct-editing-3.2.0.tgz", + "integrity": "sha512-+pyxeQGBSdLiZX0/tmmsm2qZSvm9YtVzod5W3RMHSTR7VrkUMD6E7EX/W9JQv3ebxO7oIdqFmytmNDDpSHnYEw==", + "license": "MIT", + "dependencies": { + "min-dash": "^4.0.0", + "min-dom": "^4.2.1" + }, + "engines": { + "node": "*" + }, + "peerDependencies": { + "diagram-js": "*" + } + }, + "node_modules/didi": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/didi/-/didi-10.2.2.tgz", + "integrity": "sha512-l8NYkYFXV1izHI65EyT8EXOjUZtKmQkHLTT89cSP7HU5J/G7AOj0dXKtLc04EXYlga99PBY18IPjOeZ+c3DI4w==", + "license": "MIT", + "engines": { + "node": ">= 16" + } + }, "node_modules/dir-glob": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", @@ -8189,6 +8306,15 @@ "url": "https://github.com/fb55/domhandler?sponsor=1" } }, + "node_modules/domify": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/domify/-/domify-1.4.2.tgz", + "integrity": "sha512-m4yreHcUWHBncGVV7U+yQzc12vIlq0jMrtHZ5mW6dQMiL/7skSYNVX9wqKwOtyO9SGCgevrAFEgOCAHmamHTUA==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/domutils": { "version": "3.2.2", "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.2.2.tgz", @@ -9310,21 +9436,17 @@ "license": "ISC" }, "node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "deprecated": "Glob versions prior to v9 are no longer supported", - "license": "ISC", + "version": "13.0.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-13.0.0.tgz", + "integrity": "sha512-tvZgpqk6fz4BaNZ66ZsRaZnbHvP/jG3uKJvAZOwEVUL4RTA5nJeeLYfyN9/VA8NX/V3IBG+hkeuGpKjvELkVhA==", + "license": "BlueOak-1.0.0", "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" + "minimatch": "^10.1.1", + "minipass": "^7.1.2", + "path-scurry": "^2.0.0" }, "engines": { - "node": "*" + "node": "20 || >=22" }, "funding": { "url": "https://github.com/sponsors/isaacs" @@ -9364,6 +9486,21 @@ "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", "license": "BSD-2-Clause" }, + "node_modules/glob/node_modules/minimatch": { + "version": "10.1.1", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.1.1.tgz", + "integrity": "sha512-enIvLvRAFZYXJzkCYG5RKmPfrFArdLv+R+lbQ53BmIMLIry74bjKzX6iHAm8WYamJkhSSEabrWN5D97XnKObjQ==", + "license": "BlueOak-1.0.0", + "dependencies": { + "@isaacs/brace-expansion": "^5.0.0" + }, + "engines": { + "node": "20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/global-dirs": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-3.0.1.tgz", @@ -9836,6 +9973,12 @@ "safe-buffer": "~5.1.0" } }, + "node_modules/htm": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/htm/-/htm-3.1.1.tgz", + "integrity": "sha512-983Vyg8NwUE7JkZ6NmOqpCZ+sh1bKv2iYTlUkzlWmA5JD2acKoxd4KVxbMmxX/85mtfdnDmTFoNKcg5DGAvxNQ==", + "license": "Apache-2.0" + }, "node_modules/html-entities": { "version": "2.6.0", "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-2.6.0.tgz", @@ -10130,6 +10273,12 @@ "postcss": "^8.1.0" } }, + "node_modules/ids": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/ids/-/ids-1.0.5.tgz", + "integrity": "sha512-XQ0yom/4KWTL29sLG+tyuycy7UmeaM/79GRtSJq6IG9cJGIPeBz5kwDCguie3TwxaMNIc3WtPi0cTa1XYHicpw==", + "license": "MIT" + }, "node_modules/ignore": { "version": "5.3.2", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", @@ -10220,6 +10369,12 @@ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "license": "ISC" }, + "node_modules/inherits-browser": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/inherits-browser/-/inherits-browser-0.1.0.tgz", + "integrity": "sha512-CJHHvW3jQ6q7lzsXPpapLdMx5hDpSF3FSh45pwsj6bKxJJ8Nl8v43i5yXnr3BdfOimGHKyniewQtnAIp3vyJJw==", + "license": "ISC" + }, "node_modules/ini": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", @@ -13308,6 +13463,23 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/min-dash": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/min-dash/-/min-dash-4.2.3.tgz", + "integrity": "sha512-VLMYQI5+FcD9Ad24VcB08uA83B07OhueAlZ88jBK6PyupTvEJwllTMUqMy0wPGYs7pZUEtEEMWdHB63m3LtEcg==", + "license": "MIT" + }, + "node_modules/min-dom": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/min-dom/-/min-dom-4.2.1.tgz", + "integrity": "sha512-TMoL8SEEIhUWYgkj7XMSgxmwSyGI+4fP2KFFGnN3FbHfbGHVdsLYSz8LoIsgPhz4dWRmLvxWWSMgzZMJW5sZuA==", + "license": "MIT", + "dependencies": { + "component-event": "^0.2.1", + "domify": "^1.4.1", + "min-dash": "^4.2.1" + } + }, "node_modules/mini-css-extract-plugin": { "version": "2.9.4", "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-2.9.4.tgz", @@ -13355,6 +13527,40 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", + "license": "ISC", + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/moddle": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/moddle/-/moddle-7.2.0.tgz", + "integrity": "sha512-x1+JREThy7JBOBR3g2hbOnOfrlC/YAWXX9RzrSZS5HhqeuBly9H/PCtOBtcQs+Y2sjRAXF+WTNSgHvn8Uq+6Yw==", + "license": "MIT", + "dependencies": { + "min-dash": "^4.2.1" + } + }, + "node_modules/moddle-xml": { + "version": "11.0.0", + "resolved": "https://registry.npmjs.org/moddle-xml/-/moddle-xml-11.0.0.tgz", + "integrity": "sha512-L3Sseepfcq9Uy0iIfqEDTXSoYLva1Y/JGbN/4AMOeQ6cqbu8Ma/SDJIdOFm7smsAa64j2z3SwCGG3FIilQVnUg==", + "license": "MIT", + "dependencies": { + "min-dash": "^4.0.0", + "saxen": "^10.0.0" + }, + "engines": { + "node": ">= 18" + }, + "peerDependencies": { + "moddle": ">= 6.2.0" + } + }, "node_modules/mrmime": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/mrmime/-/mrmime-2.0.1.tgz", @@ -13615,6 +13821,15 @@ "node": ">= 0.4" } }, + "node_modules/object-refs": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/object-refs/-/object-refs-0.4.0.tgz", + "integrity": "sha512-6kJqKWryKZmtte6QYvouas0/EIJKPI1/MMIuRsiBlNuhIMfqYTggzX2F1AJ2+cDs288xyi9GL7FyasHINR98BQ==", + "license": "MIT", + "engines": { + "node": "*" + } + }, "node_modules/object.assign": { "version": "4.1.7", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.7.tgz", @@ -13974,6 +14189,15 @@ "node": "^12.20.0 || ^14.13.1 || >=16.0.0" } }, + "node_modules/path-intersection": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/path-intersection/-/path-intersection-3.1.0.tgz", + "integrity": "sha512-3xS3lvv/vuwm5aH2BVvNRvnvwR2Drde7jQClKpCXTYXIMMjcw/EnMhzCgeHwqbCpzi760PEfAkU53vSIlrNr9A==", + "license": "MIT", + "engines": { + "node": ">= 14.20" + } + }, "node_modules/path-is-absolute": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", @@ -14004,6 +14228,31 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "license": "MIT" }, + "node_modules/path-scurry": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-2.0.1.tgz", + "integrity": "sha512-oWyT4gICAu+kaA7QWk/jvCHWarMKNs6pXOGWKDTr7cw4IGcUbW+PeTfbaQiLGheFRpjo6O9J0PmyMfQPjH71oA==", + "license": "BlueOak-1.0.0", + "dependencies": { + "lru-cache": "^11.0.0", + "minipass": "^7.1.2" + }, + "engines": { + "node": "20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/path-scurry/node_modules/lru-cache": { + "version": "11.2.2", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.2.2.tgz", + "integrity": "sha512-F9ODfyqML2coTIsQpSkRHnLSZMtkU8Q+mSfcaIyKwy58u+8k5nvAYeiNhsyMARvzNcXJ9QfWVrcPsC9e9rAxtg==", + "license": "ISC", + "engines": { + "node": "20 || >=22" + } + }, "node_modules/path-to-regexp": { "version": "1.9.0", "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-1.9.0.tgz", @@ -15514,6 +15763,16 @@ "postcss": "^8.4.31" } }, + "node_modules/preact": { + "version": "10.27.2", + "resolved": "https://registry.npmjs.org/preact/-/preact-10.27.2.tgz", + "integrity": "sha512-5SYSgFKSyhCbk6SrXyMpqjb5+MQBgfvEKE/OC+PujcY34sOpqtr+0AZQtPYx5IA6VxynQ7rUPCtKzyovpj9Bpg==", + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/preact" + } + }, "node_modules/pretty-error": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/pretty-error/-/pretty-error-4.0.0.tgz", @@ -16478,6 +16737,27 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/rimraf/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "deprecated": "Glob versions prior to v9 are no longer supported", + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/rtlcss": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/rtlcss/-/rtlcss-4.3.0.tgz", @@ -16563,6 +16843,15 @@ "integrity": "sha512-+aWOz7yVScEGoKNd4PA10LZ8sk0A/z5+nXQG5giUO5rprX9jgYsTdov9qCchZiPIZezbZH+jRut8nPodFAX4Jg==", "license": "ISC" }, + "node_modules/saxen": { + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/saxen/-/saxen-10.0.0.tgz", + "integrity": "sha512-RXsmWok/SAWqOG/f5ADEz51DN9WtZEzqih3e08ranldcaXekxjx8NBKjGh/y5hlowjo0JH/LekBu6gtPFD1G6g==", + "license": "MIT", + "engines": { + "node": ">= 18" + } + }, "node_modules/scheduler": { "version": "0.27.0", "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz", @@ -17572,6 +17861,12 @@ "integrity": "sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg==", "license": "MIT" }, + "node_modules/tiny-svg": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/tiny-svg/-/tiny-svg-3.1.3.tgz", + "integrity": "sha512-9mwnPqXInRsBmH/DO6NMxBE++9LsqpVXQSSTZGc5bomoKKvL5OX/Hlotw7XVXP6XLRcHWIzZpxfovGqWKgCypQ==", + "license": "MIT" + }, "node_modules/tiny-warning": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/tiny-warning/-/tiny-warning-1.0.3.tgz", diff --git a/package.json b/package.json index e01229f..8708862 100644 --- a/package.json +++ b/package.json @@ -18,9 +18,11 @@ "@docusaurus/core": "3.9.2", "@docusaurus/preset-classic": "3.9.2", "@mdx-js/react": "^3.1.1", + "bpmn-js": "^18.9.1", "clsx": "^2.1.1", "docusaurus-theme-search-typesense": "^0.25.0-0", "dotenv": "^17.2.3", + "glob": "^13.0.0", "prism-react-renderer": "^2.4.1", "react": "^19.2.0", "react-dom": "^19.2.0" From ca94a25885f753e7ec50cb61b28561167b73cd68 Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 09:43:38 +0100 Subject: [PATCH 2/6] add React component and Remark plugin --- src/components/BpmnViewer.jsx | 168 +++++++++++++++++++++++++++++ src/plugins/plugin-copy-bpmn.js | 94 ++++++++++++++++ src/plugins/remark-bpmn-diagram.js | 135 +++++++++++++++++++++++ src/theme/MDXComponents.js | 22 ++++ 4 files changed, 419 insertions(+) create mode 100644 src/components/BpmnViewer.jsx create mode 100644 src/plugins/plugin-copy-bpmn.js create mode 100644 src/plugins/remark-bpmn-diagram.js create mode 100644 src/theme/MDXComponents.js diff --git a/src/components/BpmnViewer.jsx b/src/components/BpmnViewer.jsx new file mode 100644 index 0000000..4760127 --- /dev/null +++ b/src/components/BpmnViewer.jsx @@ -0,0 +1,168 @@ +// src/components/BpmnViewer.jsx + +import React, { useEffect, useRef, useState } from 'react'; + +/** + * BPMN Diagram Viewer Component + * + * Renders BPMN diagrams inline in documentation + * Usage: + */ +export default function BpmnViewer({ diagramPath, height = '400px' }) { + const containerRef = useRef(null); + const viewerRef = useRef(null); + const [error, setError] = useState(null); + const [loading, setLoading] = useState(true); + + useEffect(() => { + if (!containerRef.current) return; + + let mounted = true; + + const initViewer = async () => { + try { + setLoading(true); + setError(null); + + console.log(`[BpmnViewer] Loading diagram: ${diagramPath}`); + + // Fetch BPMN XML + const response = await fetch(diagramPath); + + if (!response.ok) { + throw new Error(`HTTP ${response.status}: ${response.statusText}`); + } + + const xml = await response.text(); + + // Check for 404 HTML + if (xml.trim().startsWith(' { + try { + const canvas = viewer.get('canvas'); + canvas.zoom('fit-viewport'); + console.log('[BpmnViewer] Diagram rendered successfully with zoom'); + } catch (err) { + console.warn('[BpmnViewer] Zoom failed:', err); + } + }); + + } catch (err) { + console.error('[BpmnViewer] Error loading diagram:', err); + if (mounted) { + setError(err.message || 'Failed to load diagram'); + setLoading(false); + } + } + }; + + initViewer(); + + return () => { + mounted = false; + if (viewerRef.current) { + viewerRef.current.destroy(); + viewerRef.current = null; + } + }; + }, [diagramPath]); + + // --- Styles ---------------------------------------------------- + + const wrapperStyle = { + position: 'relative', + height, + marginBottom: '1.5rem', + border: '1px solid var(--ifm-color-emphasis-300, #ccc)', + borderRadius: '4px', + overflow: 'hidden', + backgroundColor: 'var(--ifm-background-color, #fff)' + }; + + const viewerStyle = { + position: 'absolute', + inset: 0, + display: 'block' + }; + + const loadingStyle = { + position: 'absolute', + inset: 0, + display: loading ? 'flex' : 'none', + alignItems: 'center', + justifyContent: 'center', + backgroundColor: 'var(--ifm-color-emphasis-100, #f5f5f5)', + color: 'var(--ifm-color-emphasis-600, #666)', + zIndex: 10 + }; + + const errorStyle = { + padding: '1rem', + backgroundColor: '#fff3cd', + border: '1px solid #ffc107', + borderRadius: '4px', + color: '#856404' + }; + + return ( +
+ {error && ( +
+ ⚠ Error loading diagram +

{error}

+

+ Path: {diagramPath} +

+
+ )} + + {/* Loading overlay */} +
+ Loading BPMN diagram... +
+ + {/* Viewer container */} +
+
+ ); +} diff --git a/src/plugins/plugin-copy-bpmn.js b/src/plugins/plugin-copy-bpmn.js new file mode 100644 index 0000000..7d798ed --- /dev/null +++ b/src/plugins/plugin-copy-bpmn.js @@ -0,0 +1,94 @@ +/** + * Docusaurus Plugin: Copy BPMN Files + * + * Copies BPMN files from docs/ to the build output, making them accessible + * at /bpmn/... URLs while keeping source files in docs/ for easy editing. + * + * Installation: + * Add to docusaurus.config.ts plugins array: + * plugins: [ + * './src/plugins/plugin-copy-bpmn', + * ], + */ + +const path = require('path'); +const fs = require('fs').promises; +const { glob } = require('glob'); + +async function copyFile(src, dest) { + await fs.mkdir(path.dirname(dest), { recursive: true }); + await fs.copyFile(src, dest); +} + +async function findBpmnFiles(dir) { + try { + // Use glob to find all .bpmn files + const pattern = path.join(dir, '**/*.bpmn').replace(/\\/g, '/'); + const files = await glob(pattern, { nodir: true }); + return files; + } catch (err) { + console.error('[copy-bpmn] Error finding BPMN files:', err); + return []; + } +} + +module.exports = function pluginCopyBpmn(context) { + const docsDir = path.join(context.siteDir, 'docs'); + + return { + name: 'docusaurus-plugin-copy-bpmn', + + // Copy BPMN files after build + async postBuild({ outDir }) { + const bpmnFiles = await findBpmnFiles(docsDir); + + let copied = 0; + for (const srcFile of bpmnFiles) { + const relativePath = path.relative(docsDir, srcFile); + const destFile = path.join(outDir, 'bpmn', relativePath); + + try { + await copyFile(srcFile, destFile); + copied++; + } catch (err) { + console.error(`[copy-bpmn] Failed to copy ${relativePath}:`, err.message); + } + } + + if (copied > 0) { + console.log(`[copy-bpmn] Copied ${copied} BPMN files to /bpmn/`); + } + }, + + // Configure webpack to serve BPMN files during development + configureWebpack(config, isServer) { + if (isServer) return {}; + + return { + devServer: { + setupMiddlewares: (middlewares, devServer) => { + // Serve BPMN files from docs/ at /bpmn/ path during dev + devServer.app.get('/bpmn/*', async (req, res, next) => { + const requestedPath = req.path.replace('/bpmn/', ''); + const filePath = path.join(docsDir, requestedPath); + + try { + const stat = await fs.stat(filePath); + if (stat.isFile() && filePath.endsWith('.bpmn')) { + res.type('application/xml'); + res.sendFile(filePath); + return; + } + } catch (err) { + // File not found, continue to next middleware + } + next(); + }); + + return middlewares; + }, + }, + }; + }, + }; +}; diff --git a/src/plugins/remark-bpmn-diagram.js b/src/plugins/remark-bpmn-diagram.js new file mode 100644 index 0000000..369ed50 --- /dev/null +++ b/src/plugins/remark-bpmn-diagram.js @@ -0,0 +1,135 @@ +/** + * Remark plugin to transform data-bpmn-diagram tags to BpmnViewer React components + * + * Handles MDX v2+ where
is parsed as JSX (mdxJsxFlowElement) + * + * Transforms:
+ * Into: + */ +import { visit } from 'unist-util-visit'; +import path from 'path'; + +export default function remarkBpmnDiagram() { + console.log('[remark-bpmn] Plugin loaded!'); + + return (tree, file) => { + const filePath = file.history?.[0] || 'unknown'; + console.log(`[remark-bpmn] Processing file: ${filePath}`); + + let transformCount = 0; + + visit(tree, (node) => { + let bpmnPath = null; + + // Case 1: MDX JSX element (MDX v2+) + if ((node.type === 'mdxJsxFlowElement' || node.type === 'mdxJsxTextElement') && + node.name === 'div') { + + const attr = node.attributes?.find(a => + a.type === 'mdxJsxAttribute' && a.name === 'data-bpmn-diagram' + ); + + if (attr && attr.value) { + console.log(`[remark-bpmn] Found JSX div with data-bpmn-diagram: "${attr.value}"`); + bpmnPath = processPath(attr.value, filePath); + } + } + + // Case 2: Raw HTML node (older MDX) + if (node.type === 'html' && node.value?.includes('data-bpmn-diagram')) { + const match = node.value.match(/data-bpmn-diagram\s*=\s*["']([^"']+)["']/i); + if (match) { + console.log(`[remark-bpmn] Found HTML with data-bpmn-diagram: "${match[1]}"`); + bpmnPath = processPath(match[1], filePath); + } + } + + if (bpmnPath) { + transformCount++; + console.log(`[remark-bpmn] Transforming to: `); + + node.type = 'mdxJsxFlowElement'; + node.name = 'BpmnViewer'; + node.attributes = [ + { + type: 'mdxJsxAttribute', + name: 'diagramPath', + value: bpmnPath + } + ]; + node.children = []; + } + }); + + console.log(`[remark-bpmn] File complete. Transforms: ${transformCount}`); + }; +} + +function processPath(relativePath, fullFilePath) { + relativePath = relativePath.trim(); + + // Skip external URLs + if (relativePath.startsWith('http://') || relativePath.startsWith('https://')) { + return null; + } + + // Extract the path relative to docs/ from the full file path + // Example: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\error-events.md + // We want: documentation/reference/bpmn20/events/error-events.md + + let docRelativePath = ''; + + // Handle both Windows and Unix paths + const normalizedFilePath = fullFilePath.replace(/\\/g, '/'); + + // Find the docs/ part + const docsIndex = normalizedFilePath.indexOf('/docs/'); + if (docsIndex !== -1) { + // Get everything after /docs/ + docRelativePath = normalizedFilePath.substring(docsIndex + 6); // +6 for '/docs/' + } else { + // Fallback: try to find just 'docs/' + const altIndex = normalizedFilePath.indexOf('docs/'); + if (altIndex !== -1) { + docRelativePath = normalizedFilePath.substring(altIndex + 5); + } + } + + console.log(`[remark-bpmn] Doc relative path: ${docRelativePath}`); + + // Get the directory of the markdown file (relative to docs/) + const fileDir = path.posix.dirname(docRelativePath); + console.log(`[remark-bpmn] File directory: ${fileDir}`); + + // Resolve the relative BPMN path against the file's directory + // Example: fileDir = "documentation/reference/bpmn20/events" + // relativePath = "../bpmn/event-error" + // result should be = "documentation/reference/bpmn20/bpmn/event-error" + + let resolvedPath; + if (relativePath.startsWith('/')) { + // Absolute path (rare) + resolvedPath = relativePath.substring(1); + } else { + // Relative path - join and normalize + const joined = path.posix.join(fileDir, relativePath); + resolvedPath = path.posix.normalize(joined); + } + + console.log(`[remark-bpmn] Resolved path: ${resolvedPath}`); + + // Add .bpmn extension if not present + if (!resolvedPath.endsWith('.bpmn')) { + resolvedPath += '.bpmn'; + } + + // Clean up any leading ./ + if (resolvedPath.startsWith('./')) { + resolvedPath = resolvedPath.substring(2); + } + + const finalPath = `/bpmn/${resolvedPath}`; + console.log(`[remark-bpmn] Final path: ${finalPath}`); + + return finalPath; +} \ No newline at end of file diff --git a/src/theme/MDXComponents.js b/src/theme/MDXComponents.js new file mode 100644 index 0000000..2421820 --- /dev/null +++ b/src/theme/MDXComponents.js @@ -0,0 +1,22 @@ +/** + * Custom MDX Components + * + * This file extends Docusaurus's default MDX components with custom components + * that can be used directly in markdown files. + * + * @see https://docusaurus.io/docs/markdown-features/react#mdx-component-scope + */ +import React from 'react'; +import MDXComponents from '@theme-original/MDXComponents'; +import BpmnViewer from '@site/src/components/BpmnViewer'; + +export default { + // Spread the default components + ...MDXComponents, + + // Add custom components that can be used in any MDX file without importing + BpmnViewer, + + // You can also add aliases for convenience + // 'bpmn-viewer': BpmnViewer, +}; From bf6d265007d9f8f831368f2ea3721072d82f4ed1 Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 09:44:21 +0100 Subject: [PATCH 3/6] Updated config with plugins --- docusaurus.config.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 1826479..464c1a1 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -4,6 +4,7 @@ import { themes as prismThemes } from 'prism-react-renderer'; import type { Config } from '@docusaurus/types'; import type * as Preset from '@docusaurus/preset-classic'; import rehypeRegisterCustomIds from './src/plugins/rehype-register-custom-ids.js'; +import remarkBpmnDiagram from './src/plugins/remark-bpmn-diagram.js'; // This runs in Node.js - Don't use client-side code here (browser APIs, JSX...) const config: Config = { @@ -29,6 +30,11 @@ const config: Config = { } }, + // The BPMN copy plugin + plugins: [ + './src/plugins/plugin-copy-bpmn.js', + ], + customFields: { javaDocUrl: '/reference/latest/javadoc', restApiDocUrl: '/reference/latest/rest-api' @@ -51,6 +57,10 @@ const config: Config = { '**/_*.{js,jsx,ts,tsx,md,mdx,bpmn}', 'docs/documentation/introduction/third-party-libraries/camunda-bpm-platform-license-book.md' ], + + // The BPMN remark plugin + remarkPlugins: [remarkBpmnDiagram], + // Please change this to your repo. // Remove this to remove the "edit this page" links. editUrl: From f64db56e9233a76561c258fa9c3c7e6e09f68dc7 Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 11:22:19 +0100 Subject: [PATCH 4/6] script to fix
+ *
+ * With: + *
+ *
+ */ + +const fs = require('fs'); +const path = require('path'); +const { glob } = require('glob'); + +const DRY_RUN = true; // <-- set to false to actually write changes +const docsDir = path.join(__dirname, 'docs'); // Adjust if your docs folder is elsewhere + +async function fixBpmnReferences() { + // Match both .md and .mdx files + const pattern = path.join(docsDir, '**/*.{md,mdx}').replace(/\\/g, '/'); + const files = await glob(pattern, { nodir: true }); + + console.log(`[fix-bpmn] Found ${files.length} Markdown/MDX files`); + + let totalReplacements = 0; + + for (const file of files) { + let content = fs.readFileSync(file, 'utf-8'); + let replacements = 0; + + // Regex: matches data-bpmn-diagram="../bpmn/..." in both
and
+ const newContent = content.replace( + /(data-bpmn-diagram\s*=\s*["'])\.\.\/bpmn\//g, + (match, p1) => { + replacements++; + return `${p1}./bpmn/`; + } + ); + + if (replacements > 0) { + totalReplacements += replacements; + + if (DRY_RUN) { + console.log(`[dry-run] ${replacements} reference(s) WOULD be fixed in: ${file}`); + } else { + fs.writeFileSync(file, newContent, 'utf-8'); + console.log(`[fix-bpmn] ${replacements} reference(s) fixed in: ${file}`); + } + } + } + + console.log(`[fix-bpmn] Done! Total replacements across all files: ${totalReplacements}`); + if (DRY_RUN) { + console.log('[dry-run] No files were modified. Set DRY_RUN = false to apply changes.'); + } +} + +fixBpmnReferences().catch(err => console.error(err)); From 419869a543b90ccfb051c6f048a0431cb6be6c3e Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 11:22:36 +0100 Subject: [PATCH 5/6] log dry run fix script --- fix-bpmn-references-dry-run.log | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 fix-bpmn-references-dry-run.log diff --git a/fix-bpmn-references-dry-run.log b/fix-bpmn-references-dry-run.log new file mode 100644 index 0000000..9367f42 --- /dev/null +++ b/fix-bpmn-references-dry-run.log @@ -0,0 +1,27 @@ +$ node fix-bpmn-references.js +[fix-bpmn] Found 413 Markdown/MDX files +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\transactions-in-processes.md +[dry-run] 6 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\process-instance-modification.md +[dry-run] 10 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\process-instance-migration.md +[dry-run] 4 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\tasks\task-markers.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\transaction-subprocess.md +[dry-run] 4 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\event-subprocess.md +[dry-run] 3 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\embedded-subprocess.md +[dry-run] 2 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\call-activity.md +[dry-run] 3 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\sequence-flow.md +[dry-run] 2 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\parallel-gateway.md +[dry-run] 5 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\inclusive-gateway.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\exclusive-gateway.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\event-based-gateway.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\timer-events.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\terminate-event.md +[dry-run] 2 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\signal-events.md +[dry-run] 2 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\none-events.md +[dry-run] 3 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\message-events.md +[dry-run] 1 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\link-events.md +[dry-run] 5 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\escalation-events.md +[dry-run] 4 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\error-events.md +[dry-run] 3 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\conditional-events.md +[dry-run] 2 reference(s) WOULD be fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\cancel-and-compensation-events.md +[fix-bpmn] Done! Total replacements across all files: 67 +[dry-run] No files were modified. Set DRY_RUN = false to apply changes. \ No newline at end of file From cd30670ff2928abea95308744c90c309a5bff167 Mon Sep 17 00:00:00 2001 From: Steven Gort Date: Fri, 28 Nov 2025 11:24:49 +0100 Subject: [PATCH 6/6] live run fix script --- .../events/cancel-and-compensation-events.md | 4 +-- .../bpmn20/events/conditional-events.md | 6 ++--- .../reference/bpmn20/events/error-events.md | 8 +++--- .../bpmn20/events/escalation-events.md | 10 +++---- .../reference/bpmn20/events/link-events.md | 2 +- .../reference/bpmn20/events/message-events.md | 6 ++--- .../reference/bpmn20/events/none-events.md | 4 +-- .../reference/bpmn20/events/signal-events.md | 4 +-- .../bpmn20/events/terminate-event.md | 2 +- .../reference/bpmn20/events/timer-events.md | 2 +- .../bpmn20/gateways/event-based-gateway.md | 2 +- .../bpmn20/gateways/exclusive-gateway.md | 2 +- .../bpmn20/gateways/inclusive-gateway.md | 10 +++---- .../bpmn20/gateways/parallel-gateway.md | 4 +-- .../bpmn20/gateways/sequence-flow.md | 6 ++--- .../bpmn20/subprocesses/call-activity.md | 4 +-- .../subprocesses/embedded-subprocess.md | 6 ++--- .../bpmn20/subprocesses/event-subprocess.md | 8 +++--- .../subprocesses/transaction-subprocess.md | 2 +- .../reference/bpmn20/tasks/task-markers.md | 8 +++--- .../process-instance-migration.md | 20 +++++++------- .../process-instance-modification.md | 12 ++++----- .../transactions-in-processes.md | 2 +- fix-bpmn-references-live-run.log | 26 +++++++++++++++++++ fix-bpmn-references.js | 2 +- 25 files changed, 94 insertions(+), 68 deletions(-) create mode 100644 fix-bpmn-references-live-run.log diff --git a/docs/documentation/reference/bpmn20/events/cancel-and-compensation-events.md b/docs/documentation/reference/bpmn20/events/cancel-and-compensation-events.md index 606413b..f7b7c83 100644 --- a/docs/documentation/reference/bpmn20/events/cancel-and-compensation-events.md +++ b/docs/documentation/reference/bpmn20/events/cancel-and-compensation-events.md @@ -56,7 +56,7 @@ Triggering compensation: Compensation can either be triggered for a designated a Note: If compensation is thrown within a scope which contains a subprocess and the subprocess contains activities with compensation handlers, compensation is only propagated to the subprocess if it has completed successfully when compensation is thrown. If some of the activities nested inside the subprocess have completed and have attached compensation handlers, the compensation handlers are not executed if the subprocess containing these activities is not completed yet. Consider the following example: -
+
In this process we have two concurrent executions, one executing the embedded subprocess and one executing the "charge credit card" activity. Lets assume both executions are started and the first concurrent execution is waiting for a user to complete the "review bookings" task. The second execution performs the "charge credit card" activity and an error is thrown, which causes the "cancel reservations" event to trigger compensation. At this point the parallel subprocess is not yet completed which means that the compensation event is not propagated to the subprocess and thus the "cancel hotel reservation" compensation handler is not executed. If the user task (and thus the embedded subprocess) completes before the "cancel reservations" is performed, compensation is propagated to the embedded subprocess. @@ -166,7 +166,7 @@ A compensation event subprocess can be used as a compensation handler for the em Contrary to a compensation boundary event attached to a subprocess, a compensation event subprocess *consumes* a thrown compensation event. That means, activities contained in the subprocess are not compensated by default. Instead, the compensation event subprocess can recursively trigger compensation for activities contained in its parent. -
+
The above process contains an embedded subprocess with a compensation event subprocess, triggered by a compensation start event. Note that this compensation handler deviates from default compensation in that it triggers compensation activities in an specific order independent from the order of execution; it also contains an additional activity adding process logic that cannot be derived from the body of the subprocess itself. diff --git a/docs/documentation/reference/bpmn20/events/conditional-events.md b/docs/documentation/reference/bpmn20/events/conditional-events.md index 083c76c..fa69636 100644 --- a/docs/documentation/reference/bpmn20/events/conditional-events.md +++ b/docs/documentation/reference/bpmn20/events/conditional-events.md @@ -162,7 +162,7 @@ are evaluated. This behavior is called *triggering on scope instantiation*. Consider the following process model: -
+
When a process instance is started, i.e., the process definition scope is instantiated, the condition of the sub process is evaluated before the none start event is executed. If fulfilled, it triggers immediately and the none start event never executes. The same applies to activities with conditional boundary events and intermediate conditional events. @@ -218,7 +218,7 @@ That means the evaluation starts at the the conditional events of the BPMN scope For example see the following BPMN process model: -
+
If a variable is set in the context of the sub process instance, then the conditional boundary event of the sub process is evaluated first. If the condition is satisfied, then the execution is interrupted, otherwise the conditional boundary event of `UserTask B` is evaluated and @@ -231,7 +231,7 @@ That means if a variable changes, only those conditional events are evaluated th See the following BPMN process model: -
+
If we have started the process above and `UserTask B` and `UserTask A` are active, then the [activity instance](../../../user-guide/process-engine/process-engine-concepts.md#activity-instances) hierarchy is: diff --git a/docs/documentation/reference/bpmn20/events/error-events.md b/docs/documentation/reference/bpmn20/events/error-events.md index 98f4ca9..0ab4a95 100644 --- a/docs/documentation/reference/bpmn20/events/error-events.md +++ b/docs/documentation/reference/bpmn20/events/error-events.md @@ -12,7 +12,7 @@ menu: Error events are events which are triggered by a defined error. -
+
## Business Errors vs. Technical Errors @@ -99,7 +99,7 @@ For External Tasks, it is also possible to define error events by using a [opera An error start event can only be used to trigger an Event Sub-Process - it __cannot__ be used to start a process instance. The error start event is always interrupting. -
+
Three optional attributes can be added to the error start event: errorRef, operaton:errorCodeVariable and operaton:errorMessageVariable: ```xml @@ -186,7 +186,7 @@ Defining a error boundary event makes most sense on an embedded subprocess, or a When an error event is caught, the activity on which the boundary event is defined is destroyed, also destroying all current executions therein (e.g., concurrent activities, nested subprocesses, etc.). Process execution continues following the outgoing sequence flow of the boundary event. -
+
A error boundary event is defined as a typical boundary event. As with the other error events, the errorRef references an error defined outside of the process element: @@ -226,7 +226,7 @@ This behaviour can be changed with enableExceptionsAfterUnhandledBpmnError An error can be handled by the error start event in the event sub process and the same error can be thrown from the event sub process to handle the error on the higher level scope (in the example below, the error thrown from the Event Subprocess is handled by the error boundary event in the Subprocess). -
+
### Additional Resources diff --git a/docs/documentation/reference/bpmn20/events/escalation-events.md b/docs/documentation/reference/bpmn20/events/escalation-events.md index edd2085..621df6f 100644 --- a/docs/documentation/reference/bpmn20/events/escalation-events.md +++ b/docs/documentation/reference/bpmn20/events/escalation-events.md @@ -12,7 +12,7 @@ menu: Escalation events are events which reference a named escalation. They are mostly used to communicate from a subprocess to an upper process. Unlike an error, an escalation event is non critical and execution continues at the location of throwing. -
+
## Defining Escalation @@ -40,7 +40,7 @@ An escalation event definition is declared by using the `escalationEventDefiniti An escalation start event can only be used to trigger an event sub-process - it __cannot__ be used to start a process instance. -
+
An event sub-process with an escalation start event is triggered by an escalation event that occurs in the same scope or in a lower scope (e.g., sub-process or call activity). When the sub-process is triggered by an escalation event from a call activity, then the defined output variables of the call activity are passed to the sub-process. @@ -89,7 +89,7 @@ The following extensions are supported for `escalationEventDefinition`. An intermediate catching escalation event on the boundary of an activity, or escalation boundary event for short, catches escalations that are thrown within the scope of the activity on which it is defined. -
+
An escalation boundary event can only attached on an embedded sub-process or a call activity, since an escalation can only be thrown by an escalation intermediate throw event or an escalation end event. When the boundary event is triggered by an escalation event from a call activity, then the defined output variables of the call activity are passed to the scope of the boundary event. @@ -134,7 +134,7 @@ The following extensions are supported for `escalationEventDefinition`. When process execution arrives at an escalation intermediate throw event, a named escalation is thrown. This escalation can be caught by an escalation boundary event or an event sub-process with an escalation start event which has the same or none escalation code. -
+
Like an error event, an escalation event is propagated to upper scopes (e.g., from sub-process or call activity) till it is caught. In case no boundary event or event sub-process caught the event, the execution just continues with normal flow. If the escalation is propagated to an upper scope via call activity then the defined output variables of the call activity are passed to the upper scope. @@ -148,7 +148,7 @@ Like an error event, an escalation event is propagated to upper scopes (e.g., fr When process execution arrives at an escalation end event, the current path of execution is ended and a named escalation is thrown. It has the same behavior as an [escalation intermediate throw event](#escalation-intermediate-throw-event). -
+
```xml diff --git a/docs/documentation/reference/bpmn20/events/link-events.md b/docs/documentation/reference/bpmn20/events/link-events.md index 126de39..f78eda8 100644 --- a/docs/documentation/reference/bpmn20/events/link-events.md +++ b/docs/documentation/reference/bpmn20/events/link-events.md @@ -15,7 +15,7 @@ Link events are a special case - it has no special execution semantics but serve in the same process model (to be precise: in the same sub process). Hence you can use two matching links as an alternative to a sequence flow as shown in the following example. -
+
Note that you might have the same event source (throwing intermediate link event with the same event definition name) multiple times, but the event target (catching intermediate link event) has to be unique according to the BPMN 2.0 specification. diff --git a/docs/documentation/reference/bpmn20/events/message-events.md b/docs/documentation/reference/bpmn20/events/message-events.md index 71978fc..3b3c8a6 100644 --- a/docs/documentation/reference/bpmn20/events/message-events.md +++ b/docs/documentation/reference/bpmn20/events/message-events.md @@ -274,7 +274,7 @@ The XML representation of a message start event is the normal start event declar A process can be started using one of two different messages, this is useful if the process needs alternative ways to react to different start events but eventually continues in a uniform way. -
+
## Message Intermediate Catching Event @@ -284,7 +284,7 @@ When a token arrives at the message intermediate catching event it will wait the The following example shows different message events in a process model: -
+
```xml @@ -307,7 +307,7 @@ Boundary events are catching events that are attached to an activity. This means A Message Intermediate Throwing event sends a message to an external service. This event has the same behavior as a [Service Task](../tasks/service-task.md). -
+
```xml diff --git a/docs/documentation/reference/bpmn20/events/none-events.md b/docs/documentation/reference/bpmn20/events/none-events.md index a0821dc..df3fee0 100644 --- a/docs/documentation/reference/bpmn20/events/none-events.md +++ b/docs/documentation/reference/bpmn20/events/none-events.md @@ -18,7 +18,7 @@ ProcessInstance processInstance = runtimeService.startProcessInstanceByKey('invo Note: a subprocess must always have a none start event. -
+
## None End Event @@ -33,7 +33,7 @@ A 'none' end event means that the result thrown when the event is reached is uns The following process diagram shows a simple example of an intermediate none event, which is often used to indicate some state achieved in the process. -
+
This can be a good hook to monitor some KPI's, basically by adding an execution listener diff --git a/docs/documentation/reference/bpmn20/events/signal-events.md b/docs/documentation/reference/bpmn20/events/signal-events.md index a94ed31..2d2af84 100644 --- a/docs/documentation/reference/bpmn20/events/signal-events.md +++ b/docs/documentation/reference/bpmn20/events/signal-events.md @@ -15,11 +15,11 @@ Signal events are events which reference a named signal. A signal is an event of The following is an example of two separate processes communicating using signals. The first process is started if an insurance policy is updated or changed. After the changes have been reviewed by a human participant, a signal event is thrown, signaling that a policy has changed: -
+
This event can now be caught by all process instances which are interested. The following is an example of a process subscribing to the event. -
+
Note: It is important to understand that a signal event is broadcast to all active handlers. In the example given above this means that all instances of the process catching the signal would receive the event. diff --git a/docs/documentation/reference/bpmn20/events/terminate-event.md b/docs/documentation/reference/bpmn20/events/terminate-event.md index bbacded..f107ad5 100644 --- a/docs/documentation/reference/bpmn20/events/terminate-event.md +++ b/docs/documentation/reference/bpmn20/events/terminate-event.md @@ -17,7 +17,7 @@ It is useful if you have a parallel token flow in a process and you want to cons A terminate event on process instance level terminates the complete instance. On subprocess level the current scope and all contained processes instances will be terminated. -
+
## Terminate Event Definition diff --git a/docs/documentation/reference/bpmn20/events/timer-events.md b/docs/documentation/reference/bpmn20/events/timer-events.md index 3990dcb..771f8cf 100644 --- a/docs/documentation/reference/bpmn20/events/timer-events.md +++ b/docs/documentation/reference/bpmn20/events/timer-events.md @@ -13,7 +13,7 @@ menu: Timer events are events which are triggered by a defined timer. They can be used as start event, intermediate event or boundary event. Boundary events can be interrupting or not. -
+
## Configuration diff --git a/docs/documentation/reference/bpmn20/gateways/event-based-gateway.md b/docs/documentation/reference/bpmn20/gateways/event-based-gateway.md index 3cb772e..d222d36 100644 --- a/docs/documentation/reference/bpmn20/gateways/event-based-gateway.md +++ b/docs/documentation/reference/bpmn20/gateways/event-based-gateway.md @@ -22,7 +22,7 @@ Note that the sequence flows running out of an event-based Gateway are different The following process is an example of a process with an event-based Gateway. When the execution arrives at the event-based Gateway, process execution is suspended. Additionally, the process instance subscribes to the alert signal event and creates a timer which fires after 10 minutes. This effectively causes the process engine to wait for ten minutes for a signal event. If the signal event occurs within 10 minutes, the timer is canceled and execution continues after the signal. If the signal is not fired, execution continues after the timer and the signal subscription is canceled. -
+
The corresponding xml looks like this: diff --git a/docs/documentation/reference/bpmn20/gateways/exclusive-gateway.md b/docs/documentation/reference/bpmn20/gateways/exclusive-gateway.md index 37567f6..4ede68d 100644 --- a/docs/documentation/reference/bpmn20/gateways/exclusive-gateway.md +++ b/docs/documentation/reference/bpmn20/gateways/exclusive-gateway.md @@ -19,7 +19,7 @@ Note that only one sequence flow is selected when using the exclusive gateway. I If no sequence flow can be selected (no condition evaluates to 'true') this will result in a runtime exception, unless you have a default flow defined. One default flow can be set on the gateway itself in case no other condition matches - like an 'else' in programming languages. -
+
Note that a gateway without an icon inside it defaults to an exclusive gateway, even if we recommend to use the X within the gateway if your BPMN tool gives you that option. diff --git a/docs/documentation/reference/bpmn20/gateways/inclusive-gateway.md b/docs/documentation/reference/bpmn20/gateways/inclusive-gateway.md index 1edc7d6..1c3c250 100644 --- a/docs/documentation/reference/bpmn20/gateways/inclusive-gateway.md +++ b/docs/documentation/reference/bpmn20/gateways/inclusive-gateway.md @@ -21,7 +21,7 @@ The functionality of the inclusive gateway is based on the incoming and outgoing Note that an inclusive gateway can have both _fork_ and _join_ behavior, if there are multiple incoming and outgoing sequence flows for the same inclusive gateway. In that case, the gateway will first join all incoming sequence flows that have a process token, before splitting into multiple concurrent paths of executions for the outgoing sequence flows that have a condition that evaluates to 'true'. -
+
Defining an inclusive gateway needs one line of XML: @@ -104,20 +104,20 @@ The following examples show under which conditions an inclusive gateway will tri only two sequence flows join in the inclusive gateway. In this scenario, the inclusive gateway **will trigger** even with only two tokens since the tokens from `Task 1` and `Task 2` were joined in a single token by `Parallel Gateway 2`. -
+
1. In this scenario, `Parallel Gateway 1` creates two execution tokens, and three sequence flows join in the inclusive gateway. In this scenario, the inclusive gateway **will trigger** with three tokens since `Parallel Gateway 2` splits the single token from `Task 1` into two separate tokens for `Task 3` and `Task 4`. -
+
1. In the diagram below, the parallel gateway creates two execution tokens. The first execution token will wait at `User Task 1`, and the second will reach the `Inclusive Gateway`. The `Inclusive Gateway` will trigger immediately for the first token, and a second time, for the second token, as both tokens arrive on the same sequence flow. As a result, there will be two instances of `User Task 2` that will need to be completed. -
+
1. In the last scenario, the parallel gateway creates two execution tokens. The first execution token will wait at `User Task 1`, and the second will reach the @@ -129,7 +129,7 @@ The following examples show under which conditions an inclusive gateway will tri behavior, only one instance of `User Task 2` will need to be completed instead of the expected two. In cases like this one, it is recommended to use an [`Exclusive Gateway`](../gateways/exclusive-gateway.md) instead of the `Inclusive Gateway 1`. -
+
## Operaton Extensions diff --git a/docs/documentation/reference/bpmn20/gateways/parallel-gateway.md b/docs/documentation/reference/bpmn20/gateways/parallel-gateway.md index 16a848a..c9a2dba 100644 --- a/docs/documentation/reference/bpmn20/gateways/parallel-gateway.md +++ b/docs/documentation/reference/bpmn20/gateways/parallel-gateway.md @@ -14,7 +14,7 @@ menu: Gateways can also be used to model concurrency in a process. The most straightforward gateway to introduce concurrency in a process model is the Parallel Gateway, which allows forking into multiple paths of execution or joining multiple incoming paths of execution. -
+
The functionality of the parallel gateway is based on the incoming and outgoing sequence flow(s): @@ -84,7 +84,7 @@ When these two tasks are completed, the second parallel gateway joins the two ex Note that a parallel gateway does not need to be 'balanced' (i.e., a matching number of incoming/outgoing sequence flows for corresponding parallel gateways). A parallel gateway will simply wait for all incoming sequence flows and create a concurrent path of execution for each outgoing sequence flow, not influenced by other constructs in the process model. So, the following process is legal in BPMN 2.0: -
+
## Operaton Extensions diff --git a/docs/documentation/reference/bpmn20/gateways/sequence-flow.md b/docs/documentation/reference/bpmn20/gateways/sequence-flow.md index 3fbba5e..5f66c74 100644 --- a/docs/documentation/reference/bpmn20/gateways/sequence-flow.md +++ b/docs/documentation/reference/bpmn20/gateways/sequence-flow.md @@ -14,7 +14,7 @@ menu: A sequence flow is the connector between two elements of a process. After an element is visited during process execution, all outgoing sequence flows are followed. This means that the default nature of BPMN 2.0 is to be parallel: two outgoing sequence flows will create two separate, parallel paths of execution. -
+
## Operaton Extensions @@ -40,7 +40,7 @@ A sequence flow is the connector between two elements of a process. After an ele A sequence flow can have a condition defined on it. When a BPMN 2.0 activity is left, the default behavior is to evaluate the conditions on the outgoing sequence flows. When a condition evaluates to 'true', that outgoing sequence flow is selected. When multiple sequence flows are selected that way, multiple executions will be generated and the process is continued in a parallel way. Note: This is different for gateways. Gateways will handle sequence flows with conditions in specific ways, depending on the gateway type. -
+
A conditional sequence flow is represented in XML as a regular sequence flow, containing a conditionExpression sub-element. Note that at the moment only tFormalExpressions are supported. Omitting the xsi:type="" definition will simply default to this type of expression. @@ -115,7 +115,7 @@ All BPMN 2.0 tasks and gateways can have a default sequence flow. This sequence A default sequence flow for a certain activity is defined by the default attribute on that activity. The following example shows an exclusive gateway with a default sequence flow. Only when x is neither 1 nor 2 it will be selected as outgoing sequence flow for the gateway. -
+
Note the 'slash' marker at the beginning of the default sequence flow. The corresponding XML snippet shows how flow4 is configured as a default sequence flow. diff --git a/docs/documentation/reference/bpmn20/subprocesses/call-activity.md b/docs/documentation/reference/bpmn20/subprocesses/call-activity.md index bb3cee8..80dc8ce 100644 --- a/docs/documentation/reference/bpmn20/subprocesses/call-activity.md +++ b/docs/documentation/reference/bpmn20/subprocesses/call-activity.md @@ -17,7 +17,7 @@ The difference is that the call activity references a process that is external t When process execution arrives at the call activity, a new process instance is created, which is used to execute the subprocess, potentially creating parallel child executions as within a regular process. The main process instance waits until the subprocess is completely ended, and continues the original process afterwards. -
+
A call activity is visualized the same way as a collapsed embedded subprocess, however with a thick border. Depending on the modeling tool, a call activity can also be expanded, but the default visualization is the collapsed representation. @@ -269,7 +269,7 @@ You can pass the business key to the subprocess. The data is copied into the sub The following process diagram shows a simple handling of an order. Since, for example, the billing could be common to many other processes, it is modeled as a call activity. -
+
The XML looks as follows: diff --git a/docs/documentation/reference/bpmn20/subprocesses/embedded-subprocess.md b/docs/documentation/reference/bpmn20/subprocesses/embedded-subprocess.md index 20b7196..7447116 100644 --- a/docs/documentation/reference/bpmn20/subprocesses/embedded-subprocess.md +++ b/docs/documentation/reference/bpmn20/subprocesses/embedded-subprocess.md @@ -25,15 +25,15 @@ Using a subprocess does impose some constraints: A subprocess is visualized as a typical activity, i.e., a rounded rectangle. In case the subprocess is collapsed, only the name and a plus-sign are displayed, giving a high-level overview of the process: -
+
In case the subprocess is expanded, the steps of the subprocess are displayed within the subprocess boundaries: -
+
One of the main reasons to use a subprocess is to define a scope for an event. The following process model shows this: If we are spontaneously invited to dinner, we will cancel our cooking process. However, if we are already eating, we will not react to an invitation anymore. In more technical terms, the scope of the message event is the subprocess, so the message can only be received while the subprocess is active. -
+
A subprocess is defined by the subprocess element. All activities, gateways, events, etc. that are part of the subprocess need to be enclosed within this element. diff --git a/docs/documentation/reference/bpmn20/subprocesses/event-subprocess.md b/docs/documentation/reference/bpmn20/subprocesses/event-subprocess.md index 32a8e38..dad72e0 100644 --- a/docs/documentation/reference/bpmn20/subprocesses/event-subprocess.md +++ b/docs/documentation/reference/bpmn20/subprocesses/event-subprocess.md @@ -19,7 +19,7 @@ An event subprocess may not have any incoming or outgoing sequence flows. As an The event subprocess is visualized as an embedded subprocess with a dotted outline. -
+
It is represented using XML in the same way as an embedded subprocess. Additionally, the attribute triggeredByEvent must have the value `true`: @@ -40,7 +40,7 @@ It is represented using XML in the same way as an embedded subprocess. Additiona The following is an example of an event subprocess triggered using an Error Start Event. The event subprocess is located at the "process level", i.e., is scoped to the process instance: -
+
This is what the event subprocess looks like in XML: @@ -56,11 +56,11 @@ This is what the event subprocess looks like in XML: As already stated, an event subprocess can also be added to an embedded subprocess. If it is added to an embedded subprocess, it becomes an alternative to a boundary event. Consider the two following process diagrams. In both cases the embedded subprocess throws an error event. Both times the error is caught and handled using a user task. -
+
as opposed to: -
+
In both cases the same tasks are executed. However, there are differences between both modeling options: diff --git a/docs/documentation/reference/bpmn20/subprocesses/transaction-subprocess.md b/docs/documentation/reference/bpmn20/subprocesses/transaction-subprocess.md index 9ae2c6e..bf91984 100644 --- a/docs/documentation/reference/bpmn20/subprocesses/transaction-subprocess.md +++ b/docs/documentation/reference/bpmn20/subprocesses/transaction-subprocess.md @@ -26,7 +26,7 @@ A transaction can have three possible outcomes: The following diagram illustrates the three different outcomes: -
+
A transaction subprocess is represented in xml using the transaction element: diff --git a/docs/documentation/reference/bpmn20/tasks/task-markers.md b/docs/documentation/reference/bpmn20/tasks/task-markers.md index dd46f87..52da14f 100644 --- a/docs/documentation/reference/bpmn20/tasks/task-markers.md +++ b/docs/documentation/reference/bpmn20/tasks/task-markers.md @@ -35,7 +35,7 @@ A Gateway or Event can not become multi-instance. If an activity is multi-instance, this is indicated by three short lines at the bottom of the activity. Three vertical lines indicate that the instances will be executed in parallel, while three horizontal lines indicate **sequential** execution. -
+
As required by the specification, each parent execution of the created executions for each instance will have the following variables: @@ -145,7 +145,7 @@ In this example, parallel instances will be created for each element of the assi Since a multi-instance is a regular activity, it is possible to define a boundary event on its boundary. In case of an interrupting boundary event, when the event is caught, all instances that are still active will be destroyed. For example, take the following multi-instance subprocess: -
+
Here all instances of the subprocess will be destroyed when the timer fires, regardless of how many instances there are or which inner activities are currently not completed yet. @@ -156,7 +156,7 @@ The loop marker is not natively supported yet by the engine. For Multiple Instan To get around this limitation, the solution is to explicitly model the loop in your BPMN process: -
+
Be assured that we have the loop marker in our backlog to be added to the engine. @@ -187,7 +187,7 @@ will contain the array item. To access the value of the element, you can use `.v If an activity is used for compensating the effects of another activity, it can be declared to be a compensation handler. Compensation handlers are not contained in the regular flow and are only executed when a compensation event is thrown. -
+
Notice the compensation handler icon in the bottom center area of the "cancel hotel reservation" service task. diff --git a/docs/documentation/user-guide/process-engine/process-instance-migration.md b/docs/documentation/user-guide/process-engine/process-instance-migration.md index 877edee..1cb6e57 100644 --- a/docs/documentation/user-guide/process-engine/process-instance-migration.md +++ b/docs/documentation/user-guide/process-engine/process-instance-migration.md @@ -42,11 +42,11 @@ In the remainder of this section, the following process models are used to illus Process `exampleProcess:1`: -
+
Process `exampleProcess:2`: -
+
## Process Instance Migration by Example @@ -494,11 +494,11 @@ When mapping events, there are two configuration options: Process `timerBoundary:1`: -
+
Process `timerBoundary:2`: -
+
Specifying the instruction `migrationBuilder.mapActivities("timer", "timer").updateEventTrigger()` is going to reinitialize the timer job. In effect, the boundary event fires ten days after migration. In contrast, if `updateEventTrigger` is not used, then the @@ -548,11 +548,11 @@ This tells the migration API which compensation handler of the source process mo Consider this source process: -
+
And this target process: -
+
Assume a process instance in the following state: @@ -575,11 +575,11 @@ MigrationPlan migrationPlan = processEngine.getRuntimeService() After migration, compensation can be triggered from the same scope as before migration (or in case that scope is removed, the closest ancestor scope that migrates). For illustration, consider the following source process: -
+
And this target process: -
+
When migrating the same process instance state as in the above example, the inner compensation event is **not** going to trigger compensation of the *Archive Application* activity but only the outer compensation event. @@ -596,11 +596,11 @@ For example, consider the following two processes: Process `compensation:1`: -
+
Process `compensation:2`: -
+
Furthermore, assume that before migration a process instance is in the following state: diff --git a/docs/documentation/user-guide/process-engine/process-instance-modification.md b/docs/documentation/user-guide/process-engine/process-instance-modification.md index 005ea20..978e947 100644 --- a/docs/documentation/user-guide/process-engine/process-instance-modification.md +++ b/docs/documentation/user-guide/process-engine/process-instance-modification.md @@ -34,7 +34,7 @@ To perform such an operation, the process engine offers the *process instance mo As an example, consider the following process model: -
+
The model shows a simple process for processing a loan application. Let us assume that a loan application has arrived, the loan application has been evaluated, and it was determined to decline the application. That means, the process instance has the following activity instance state: @@ -138,7 +138,7 @@ In a JUnit test, you can assert that the processInstance is waiting at 'Accept L The following sections specify the exact semantics of process instance modification and should be read in order to understand the modification effects in varying circumstances. If not otherwise noted, the following examples refer to the following process model for illustration: -
+
### Modification Instruction Types @@ -289,7 +289,7 @@ ProcessInstance Apart from instantiating these parent scopes, the engine also ensures to register the event subscriptions and jobs in these scopes. For example, consider the following process: -
+
Starting the activity *Assess Credit Worthiness* also registers an event subscription for the message boundary event *Cancelation Notice Received* such that it is possible to cancel the sub process this way. @@ -431,7 +431,7 @@ Due to the [default ancestor selection](#ancestor-selection-for-instantiation) d Process instance modification respects any interrupting or canceling semantics of the activities to be started. In particular, starting an interrupting boundary event or an interrupting event sub process will cancel/interrupt the activity it is defined on/in. Consider the following process: -
+
Assume that the activity *Assess Credit Worthiness* is currently active. The event sub process can be started with the following code: @@ -477,7 +477,7 @@ Modification also works for multi-instance activities. We distinguish in the fol With this distinction, it is possible to start the entire multi-instance body, as well as start a single inner activity instance for a running parallel multi-instance activity. Consider the following process model: -
+
Let's assume the multi-instance activity is active and has three instances: @@ -619,7 +619,7 @@ It will be visible in [User Operation Log](../process-engine/history/user-operat Process instance modification is a very powerful tool and allows to start and cancel activities at will. Thus, it is easy to create situations that are unreachable by normal process execution. Assume the following process model: -
+
Assume that activity *Decline Loan Approval* is active. With modification, the activity *Assess Credit Worthiness* can be started. After that activity is completed, execution gets stuck at the joining parallel gateway because no token will ever arrive at the other incoming sequence flow such that the parallel gateway is activated. This is one of the most obvious situations where the process instance cannot continue execution and there are certainly many others, depending on the concrete process model. diff --git a/docs/documentation/user-guide/process-engine/transactions-in-processes.md b/docs/documentation/user-guide/process-engine/transactions-in-processes.md index b9622b5..9fcd154 100644 --- a/docs/documentation/user-guide/process-engine/transactions-in-processes.md +++ b/docs/documentation/user-guide/process-engine/transactions-in-processes.md @@ -25,7 +25,7 @@ The [Event Based Gateway](../../reference/bpmn20/gateways/event-based-gateway.md -
+
A special type of the [Service Task](../../reference/bpmn20/tasks/service-task.md): [External Task](../process-engine/external-tasks.md) diff --git a/fix-bpmn-references-live-run.log b/fix-bpmn-references-live-run.log new file mode 100644 index 0000000..f7ec41b --- /dev/null +++ b/fix-bpmn-references-live-run.log @@ -0,0 +1,26 @@ +$ node fix-bpmn-references.js +[fix-bpmn] Found 413 Markdown/MDX files +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\transactions-in-processes.md +[fix-bpmn] 6 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\process-instance-modification.md +[fix-bpmn] 10 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\user-guide\process-engine\process-instance-migration.md +[fix-bpmn] 4 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\tasks\task-markers.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\transaction-subprocess.md +[fix-bpmn] 4 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\event-subprocess.md +[fix-bpmn] 3 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\embedded-subprocess.md +[fix-bpmn] 2 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\subprocesses\call-activity.md +[fix-bpmn] 3 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\sequence-flow.md +[fix-bpmn] 2 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\parallel-gateway.md +[fix-bpmn] 5 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\inclusive-gateway.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\exclusive-gateway.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\gateways\event-based-gateway.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\timer-events.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\terminate-event.md +[fix-bpmn] 2 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\signal-events.md +[fix-bpmn] 2 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\none-events.md +[fix-bpmn] 3 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\message-events.md +[fix-bpmn] 1 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\link-events.md +[fix-bpmn] 5 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\escalation-events.md +[fix-bpmn] 4 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\error-events.md +[fix-bpmn] 3 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\conditional-events.md +[fix-bpmn] 2 reference(s) fixed in: C:\Users\mail\Development\documentation\docs\documentation\reference\bpmn20\events\cancel-and-compensation-events.md +[fix-bpmn] Done! Total replacements across all files: 67 diff --git a/fix-bpmn-references.js b/fix-bpmn-references.js index 604c1b2..ffa1b8b 100644 --- a/fix-bpmn-references.js +++ b/fix-bpmn-references.js @@ -16,7 +16,7 @@ const fs = require('fs'); const path = require('path'); const { glob } = require('glob'); -const DRY_RUN = true; // <-- set to false to actually write changes +const DRY_RUN = false; // <-- set to false to actually write changes const docsDir = path.join(__dirname, 'docs'); // Adjust if your docs folder is elsewhere async function fixBpmnReferences() {