Repository navigation
Validate the workflow tutorials in CI with one runner script - #1396
Merged
Merged
Conversation
This was referenced Oct 29, 2026
…orkflow tutorials Add dapr-sqlite.yaml to the .NET history propagation and versioning tutorials, in the shape of the other .NET tutorials: it is the same as dapr.yaml with the resources-sqlite folder, so both tutorials run without Docker and Redis. Add versioning.http to the .NET versioning tutorial. It starts the workflow and reads its status from the Dapr workflow API. Remove the sentence in the .NET tutorials README that says these two tutorials have no dapr-sqlite.yaml. The combined-patterns tutorials use Redis for pub/sub and no SQLite pub/sub component exists, so they keep dapr.yaml only. Signed-off-by: Nelson Parente <nelson_parente@live.com.pt> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tutorials/workflow/validate.sh <lang> <topic> builds and starts a workflow tutorial (dapr run -f for Python, .NET and Go, mvn spring-boot:test-run for Java), sends the requests of its .http file in order, and checks every workflow instance that a request started through GET /v1.0/workflows/dapr/<id>. It exits 0 only when each instance reaches COMPLETED, or is gone after the .http file purges it. A tutorial with no .http file that runs its scenarios and exits is checked on its output. The script stops everything that it started. The .http parser reads @var lines, ### request blocks, # @name names, {{var}}, {{$guid}} and {{name.response.headers.X}} or {{name.response.body.path}} references. Signed-off-by: Nelson Parente <nelson_parente@live.com.pt> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replace the commented-out .NET workflow steps with a matrix job over the Python, .NET, Go and Java workflow tutorials. Each entry runs tutorials/workflow/validate.sh on ubuntu-latest with the Dapr versions of global.env. Python, .NET and Go entries use dapr init --slim and start the Scheduler and Placement services as processes. Java entries use Testcontainers. The combined-patterns tutorials for Python and .NET run in a second job with a Redis service container. challenges-tips is not in the matrix because it holds code snippets only. Signed-off-by: Nelson Parente <nelson_parente@live.com.pt> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Nelson Parente <nelson_parente@live.com.pt> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
nelson-parente
force-pushed
the
tutorials-ci
branch
from
November 6, 2026 11:31
a947e54 to
6658e3a
Compare
nelson-parente
marked this pull request as ready for review
November 6, 2026 11:33
JoshVanL
previously approved these changes
Nov 6, 2026
…o its run validate.sh gave PASS for a purged instance in two cases where the tutorial did not work: - The instance was FAILED before the purge. The check before the purge accepted any final status. - No daprd answered after the purge. The script read a connection error as "the instance is gone". Now the instance must be COMPLETED before the purge, or TERMINATED when the .http file terminates it first. After the purge, at least one daprd must answer, and no daprd must know the instance. Other changes: - The Java cleanup removes only the Testcontainers containers that this run created. It no longer removes the containers of other projects. - The Java combined-patterns run puts back the user's ~/.testcontainers.properties at exit. - macOS has no setsid command. There, python3 starts the new session. - Only history-propagation can run without a .http file, because the expected output lines belong to that topic. Any other topic without a .http file fails at once with a clear message. - The daprHost port lookup reads the variable directly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Nelson Parente <nelson_parente@live.com.pt>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This pull request does not need #1394. It applies to
masteron its own.The workflow tutorials have no CI today. The steps in
validate_tutorials.yamlare commented out, because mechanical-markdown cannot drive their long-running services.Changes
tutorials/workflow/validate.sh <lang> <topic>: one runner for every language. It starts the tutorial, sends the requests of its.httpfile in order, and checks each workflow instance throughGET /v1.0/workflows/dapr/<id>. It exits 0 only when each instance reachesCOMPLETED, or is gone after the.httpfile purges it. For the Python, .NET and Go history propagation tutorials, which have no.httpfile, it checks the app output. It stops everything that it started.validate_tutorials.yaml: a matrix job over the Python, .NET, Go and Java tutorials onubuntu-latest, with the Dapr versions ofglobal.env. Python, .NET and Go usedapr init --slim. Java uses Testcontainers. A second job runscombined-patternswith a Redis service container. The two jobs have 34 entries.dapr-sqlite.yamlfor history propagation and versioning, andversioning.http.CLAUDE.md: describe the new validation.Tests
Each topic ran in a container with Dapr CLI and runtime 1.19.0. The only command was
bash tutorials/workflow/validate.sh <lang> <topic>.combined-patternson Redis).combined-patternson Redis).bash -n tutorials/workflow/validate.shpasses.🤖 Generated with Claude Code