Skip to content

Add a workflow schedule example and bump durabletask-go - #864

Open
JoshVanL wants to merge 3 commits into
dapr:mainfrom
JoshVanL:workflow-schedules
Open

JoshVanL wants to merge 3 commits into
dapr:mainfrom
JoshVanL:workflow-schedules

Conversation

@JoshVanL

Copy link
Copy Markdown
Member

Bump durabletask-go to 98658f3 in the root and examples modules, which brings the workflow schedule client (dapr/dapr#11095). client.NewWorkflowClient returns that client, so the schedule API needs no wrapper here.

Add examples/workflow-schedule: create a schedule with repeats, wait for it to complete, list its runs by instance ID prefix, trigger a second schedule, then delete both and purge the runs.

Validate it in a new validate-example-dapr-master job, which runs against a daprd built from dapr master, because no release has workflow schedules yet. The release jobs are unchanged.

Bump durabletask-go to 98658f3 in the root and examples modules, which
brings the workflow schedule client (dapr/dapr#11095).
client.NewWorkflowClient returns that client, so the schedule API needs
no wrapper here.

Add examples/workflow-schedule: create a schedule with repeats, wait
for it to complete, list its runs by instance ID prefix, trigger a
second schedule, then delete both and purge the runs.

Validate it in a new validate-example-dapr-master job, which runs
against a daprd built from dapr master, because no release has workflow
schedules yet. The release jobs are unchanged.

Signed-off-by: joshvanl <me@joshvanl.dev>
@JoshVanL
JoshVanL requested review from a team as code owners November 13, 2026 14:20
Copilot AI balanced review requested due to automatic review settings November 13, 2026 14:21
@codecov

codecov Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 57.38%. Comparing base (e28f61c) to head (d92c604).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #864   +/-   ##
=======================================
  Coverage   57.38%   57.38%           
=======================================
  Files          53       53           
  Lines        3888     3888           
=======================================
  Hits         2231     2231           
  Misses       1503     1503           
  Partials      154      154           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Incomplete pagination can omit runs and schedules or cause a nil-pointer panic, while rerun cleanup leaves previously triggered manual runs unpurged.

3 open issues
What changed in this PR

Adds a workflow scheduling example using the schedule APIs exposed directly by client.NewWorkflowClient(), with validation against Dapr master until a supporting runtime release is available.

Changes:

  • Updates durabletask-go to commit 98658f3 in the root and examples modules.
  • Adds an example covering repeated runs, manual triggering, schedule inspection, deletion, and run cleanup.
  • Adds a master-runtime validation job while leaving release validation jobs unchanged.
File Description
go.sum Updates durabletask-go checksums.
go.mod Upgrades the SDK’s durabletask-go dependency.
examples/​workflow-schedule/​README.md Documents prerequisites, execution, expected output, and schedule behavior.
examples/​workflow-schedule/​main.go Demonstrates workflow scheduling and cleanup APIs.
examples/​workflow-schedule/​config/​redis.yaml Configures Redis as the workflow actor state store.
examples/​go.sum Updates the examples’ dependency checksums.
examples/​go.mod Aligns examples with the upgraded durabletask-go dependency.
.github/​workflows/​validate_examples.yaml Adds schedule-example validation against a source-built Dapr runtime.

Review effort: Balanced

Comment thread examples/workflow-schedule/main.go Resolved
Comment thread examples/workflow-schedule/main.go Resolved
Comment thread examples/workflow-schedule/main.go Resolved
Signed-off-by: joshvanl <me@joshvanl.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants