问题
We develop processes in jBPM Business Central. And we create two branches for two developers, and every developer make some changes. After that, I try to merge changes, but get a lot of conflicts like this:
<<<<<<< HEAD
<bpsim:ElementParameters xsi:type="bpsim:ElementParameters" elementRef="_B522FC25-C305-43A2-B22B-CF9D2280A47B" id="_rucp8h2REeqUr8GsL--YmA">
=======
<bpsim:ElementParameters xsi:type="bpsim:ElementParameters" elementRef="_B522FC25-C305-43A2-B22B-CF9D2280A47B" id="_ouptgR2QEeqUr8GsL--YmA">
>>>>>>> origin/some-branch
How to merge bpmn files properly? May be some special software exists?
回答1:
You can use BPMN Sketch Miner to represent your processes as text.
Then you can do the diff and merge conflict resolution directly on the source text.
回答2:
To my knowledge, there is no tool yet which helps you to merge BPMN's XML-files, other than actual comparing the BPMN graphical display by naked eye if you have a merge conflict.
In order to automatize merge conflict resolution, you would need a format which is relatively easy to be understand by humans - the XML as which normal BPMN are stored does not fulfill that boundary condition, simply because slight changes in the layout which do not affect the logic lead to different XML files.
A way forward towards an easy-readable BPMN representation could be to use some meta language which is translated to BPMN-XML automatically. The advantage of an non-XML representation of BPMN is also that GIT's internal merge-conflict resolution processes would work right out of the box.
There are at least two different meta-languages for BPMN on the market:
There is a master thesis which is a master thesis trying to develop a plain text representation of BPMN:
However, so far for BPMN only graphical modelling tools exist. In this thesis, a textual representation of BPMN process models is devised and implemented. The notation considers usability aspects that emanate from studies on existing textual modelling languages, especially of UML diagrams. In order to support users of the language, a dedicated editor for the language is provided and in order to also allow using the created "plantBPMN" language in combination with other tools, a transformation from the textual model to the standardized XML-based BPMN model exchange format is implemented.
- There is also a rudimentary YAML implementation of BPMN, but this is not widely used either, see https://docs.zeebe.io/yaml-workflows/index.html
来源:https://stackoverflow.com/questions/59348647/merging-two-versions-of-bpmn-xml-files