Skip to content

Commit

Permalink
docs: improve description of binding type 'latest' + fix XML examples (
Browse files Browse the repository at this point in the history
  • Loading branch information
jfriedenstab authored Aug 22, 2024
1 parent e19f0e5 commit 7aee766
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,51 @@ For example, for a call activity this would be the version of the called process

Camunda 8 supports the following binding types:

| Type | Description |
| :----------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `latest` | <p>Resolves to the **latest deployed version** of the target resource at the moment the process element is activated.</p><p><ul><li><p>This can lead to unexpected behavior if you deploy a new version of the target resource without ensuring backwards compatibility with every deployed process that depends on it.</p></li><li><p>Therefore, using `latest` might not be suited for production environments that require stability and a predictable behavior.</p></li></ul></p> |
| `deployment` | <p>Resolves to the specific version of the target resource that was **deployed together** with the currently running version of the process in the **same deployment**.</p><p><ul><li><p>This option ensures predictable behavior by tying the two versions together, and allows you to deploy future versions of the target resource without disrupting ongoing process instances.</p></li><li><p>This option is ideal for self-contained projects without external or shared dependencies.</p></li><li><p>To use the `deployment` binding option, create and deploy a [process application in Web Modeler](/docs/components/modeler/web-modeler/process-applications.md#deploy-and-run-a-process-application), or deploy multiple resources together via the [Zeebe API](/docs/apis-tools/zeebe-api/gateway-service.md#deployresource-rpc).</p></li></ul></p> |
<table>
<thead>
<tr>
<th align="left">Type</th>
<th align="left">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>latest</code></td>
<td>
<p>Resolves to the <strong>latest deployed version</strong> of the target resource at the moment the process element is activated.</p>
<ul>
<li>
<p>
You can use this option to easily change the target resource at runtime by deploying a new version of the resource.
This allows for fast, iterative development, and easy hot fixes in production:
</p>
<ul>
<li><p>Process instances that have not yet reached the process element use the newly deployed version of the target resource once the element is activated.</p></li>
<li><p>If the process element has already been reached, you can use <a href="../../../concepts/process-instance-modification">process instance modification</a> to reactivate and relink it to the newly deployed target resource version.</p></li>
</ul>
</li>
<li><p>Be aware that using <code>latest</code> can lead to unexpected behavior if you deploy a new version of the target resource without ensuring backwards compatibility with every deployed process that depends on it.</p><p>This might not be suited for production environments that require stability and a predictable behavior.</p></li>
</ul>
</td>
</tr>
<tr>
<td><code>deployment</code></td>
<td>
<p>Resolves to the specific version of the target resource that was <strong>deployed together</strong> with the currently running version of the process in the <strong>same deployment</strong>.</p>
<ul>
<li><p>This option ensures predictable behavior by tying the two versions together, and allows you to deploy future versions of the target resource without disrupting ongoing process instances.</p></li>
<li><p>It is ideal for self-contained projects without external or shared dependencies.</p></li>
<li>
<p>To use the <code>deployment</code> binding option, create and deploy a <a href="../../../modeler/web-modeler/process-applications/#deploy-and-run-a-process-application">process application in Web Modeler</a>,
or deploy multiple resources together via the <a href="../../../../apis-tools/zeebe-api/gateway-service/#deployresource-rpc"> Zeebe API</a>.
</p>
</li>
</ul>
</td>
</tr>
</tbody>
</table>

:::note

If the binding type is not explicitly specified in your BPMN diagram, `latest` is used as the default.

:::
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ A business rule task with a called decision that uses `deployment` binding:
```xml
<bpmn:businessRuleTask id="determine-box-size" name="Determine shipping box size">
<bpmn:extensionElements>
<zeebe:calledDecision decisionId="shipping_box_size" resultVariable="boxSize" bindingType="deployment" />
<zeebe:calledDecision decisionId="shipping_box_size" bindingType="deployment"
resultVariable="boxSize" />
</bpmn:extensionElements>
</bpmn:businessRuleTask>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ A call activity with static process id, propagation of all child variables turne
```xml
<bpmn:callActivity id="Call_Activity" name="Call Process A">
<bpmn:extensionElements>
<zeebe:calledElement processId="child-process-a" propagateAllChildVariables="true" bindingType="deployment" />
<zeebe:calledElement processId="child-process-a" bindingType="deployment"
propagateAllChildVariables="true" />
</bpmn:extensionElements>
</bpmn:callActivity>
```
Expand Down

0 comments on commit 7aee766

Please sign in to comment.