-
Notifications
You must be signed in to change notification settings - Fork 190
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(play): add scenarios section #4737
Open
huygur
wants to merge
7
commits into
main
Choose a base branch
from
play-scenarios
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+50
−2
Open
Changes from 5 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
fd57dba
docs(play): add scenarios section
huygur 5fd23bf
chore: include additional limitation
huygur 012f3e4
refactor: use custom anchor links
huygur 3550ba6
refactor: apply review suggestions
huygur 4724680
refactor: use relative url
huygur 0f449c9
TW edits
mesellings fa0ec83
Fix link
mesellings File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file removed
BIN
-155 KB
docs/components/modeler/web-modeler/img/play-cluster-configuration.png
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-155 KB
(34%)
docs/components/modeler/web-modeler/img/play-example-data.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-31.8 KB
(68%)
docs/components/modeler/web-modeler/img/play-modifications.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,6 +92,40 @@ Play's rewind operation currently does not support the following elements: | |
- Play rewinds to an element, not to an element instance. For example, if you wanted to rewind your process to a sequential multi-instance service task which ran five times, it will rewind your process to the first instance of that service task. | ||
- Play rewinds processes by initiating a new instance and executing each element. However, if any element behaves differently from the previous execution, such as a Connector returning a different result, the rewind may fail. | ||
|
||
## Scenarios | ||
|
||
Scenarios accelerate manual testing by providing a no-code way of quickly re-running processes while tracking your test coverage. | ||
|
||
You can validate your process by creating and rerunning scenarios for different paths, ensuring that it continues to function as expected after any changes to your diagram. Scenarios let you replay and confirm that the process completes correctly with the pre-defined actions and variables. Although scenarios are quick to develop and use for non-developers, our [best practices](/components/best-practices/development/testing-process-definitions) suggest using specialized test libraries in your CI/CD pipeline. | ||
|
||
### Saving a scenario | ||
|
||
After executing a path in your process, you can save it as a scenario by clicking the **Save scenario** button in the process instance header. To view your saved scenarios, navigate to the process definition page by clicking the **View all** button under the Scenarios column in the process instance header. | ||
|
||
![save scenario](img/play-save-scenario.png) | ||
|
||
### Scenario coverage | ||
|
||
Scenario coverage is calculated as the percentage of flow nodes in your process that are covered. This includes all elements, events, and gateways. For example, if 8 out of 10 flow nodes are covered, the coverage will be 80%. | ||
On the process definition page, covered paths are highlighted in blue. You can also click on individual scenarios to view their specific coverage. | ||
|
||
![save scenario](img/play-coverage.png) | ||
|
||
Once a process instance is completed, the process instance header will display how much your process scenario coverage would increase if this path were saved as a scenario. | ||
|
||
### Running a scenario | ||
|
||
Scenarios can be run from the process definition page using the **Run all scenarios** button, or by clicking the **Run scenario** button with the play icon for each individual scenario. The result of a scenario execution will be marked as **Completed** or **Failed.** Failed scenarios must be manually updated by clicking the **manually complete and update the scenario** button, especially when changes are made to your diagram that require further user input—such as when a new flow node is added to a previously saved scenario path. | ||
|
||
![save scenario](img/play-scenario-runs.png) | ||
|
||
### Limitations {#scenarios-limitations} | ||
|
||
- Scenarios are stored in the browser's local storage, making them accessible only in the current browser and not usable outside of Play, in a different browser, or by a collaborator. | ||
- Call activities are not supported; therefore, scenarios containing them cannot be executed successfully. | ||
- Scenario paths that include process modifications are not supported. | ||
- Similar to process instances, scenarios do not run in isolation. For instance, if two scenario paths are defined for a process and both contain the same message event or signal event, running these scenarios simultaneously may lead to unintended consequences. Publishing a scenario or broadcasting a signal could inadvertently impact the other scenario, resulting in the failure of both. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💭 It could be nice to include a link to the documentation for the nature of message events and signal events, where the issue with global publish/broadcast is mentioned. However, I am not aware of such a link at this moment. |
||
|
||
## Modify a process instance | ||
|
||
There are two main reasons to modify a process instance in Play: | ||
|
@@ -111,7 +145,7 @@ Unlike in [Operate](/components/operate/userguide/process-instance-modification. | |
|
||
![modify process instance](img/play-modifications.png) | ||
|
||
### Limitations | ||
### Limitations {#modifications-limitations} | ||
|
||
Rewinding a process instance that has modifications applied to is currently not supported. Additionally, some elements do not support specific modifications: | ||
|
||
|
@@ -177,7 +211,7 @@ Prior to the 8.6 release, Play can be accessed by installing the 8.6.0-alpha [He | |
|
||
After selecting the **Play** tab in Self-Managed, you are prompted to select from the clusters defined in your Web Modeler [configuration](/self-managed/modeler/web-modeler/configuration/configuration.md#clusters). The Camunda 8 Helm and Docker Compose distributions provide one cluster configured by default. | ||
|
||
### Limitations | ||
### Limitations {#self-managed-limitations} | ||
|
||
- Play does not support multi-tenancy. | ||
- The environment variables `CAMUNDA_CUSTOM_CERT_CHAIN_PATH`, `CAMUNDA_CUSTOM_PRIVATE_KEY_PATH`, `CAMUNDA_CUSTOM_ROOT_CERT_PATH`, and `CAMUNDA_CUSTOM_ROOT_CERT_STRING` can be set in Docker or Helm chart setups. However, these configurations have not been tested with Play's behavior, and therefore are not supported when used with Play. | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
variable changes are actually supported
scenarios cover everything rewind feature does