Skip to content

docs(jsdoc): annotate workflow runtime and client APIs#819

Open
Jeevansm25 wants to merge 3 commits into
dapr:mainfrom
Jeevansm25:docs-jsdoc-workflow
Open

docs(jsdoc): annotate workflow runtime and client APIs#819
Jeevansm25 wants to merge 3 commits into
dapr:mainfrom
Jeevansm25:docs-jsdoc-workflow

Conversation

@Jeevansm25
Copy link
Copy Markdown
Contributor

Description

Closes #796

This PR adds comprehensive JSDoc annotations across the Dapr Workflow subsystem, covering workflow clients, orchestration runtime APIs, workflow state models, orchestration primitives, and workflow-related type definitions.

The goal is to improve IntelliSense, IDE hover documentation, discoverability, and onboarding experience for developers building durable workflows with the Dapr JavaScript SDK.

Covered Areas

Workflow Client

  • DaprWorkflowClient
  • WorkflowState
  • WorkflowFailureDetails

Workflow Runtime

  • WorkflowRuntime
  • WorkflowContext
  • WorkflowActivityContext
  • WorkflowRuntimeStatus

Workflow Type Definitions

  • Activity and workflow function signatures
  • Workflow client/runtime option types
  • Workflow start and event-raise options
  • Workflow runtime status types
  • Input/output helper types

Documentation Added

This PR adds:

  • Class-level and method-level JSDoc
  • Constructor documentation
  • Property-level documentation
  • Workflow orchestration primitive documentation
  • Usage examples for common workflow patterns
  • Replay-safe orchestration guidance
  • Durable timer documentation
  • External event correlation examples
  • Fan-out/fan-in orchestration examples
  • Child workflow orchestration examples
  • Continue-as-new / eternal workflow guidance
  • Dapr Workflow reference links where relevant

WorkflowContext Coverage

The orchestration APIs in WorkflowContext were documented in detail, including:

  • callActivity
  • callChildWorkflow
  • createTimer
  • waitForExternalEvent
  • continueAsNew
  • whenAll
  • whenAny

The documentation explains deterministic workflow execution requirements, replay-safe orchestration behavior, and durable execution semantics.

Notes

  • Documentation-only changes
  • No runtime logic changes
  • No API or behavioral changes
  • No generated/proto changes included
  • Build and TypeScript compilation pass successfully

Signed-off-by: JEEVAN S M IIIT Dharwad <22bcs049@iiitdwd.ac.in>
@Jeevansm25 Jeevansm25 requested review from a team as code owners May 21, 2026 13:30
@codecov
Copy link
Copy Markdown

codecov Bot commented May 21, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 31.30%. Comparing base (d1bf38a) to head (dd603f0).
⚠️ Report is 90 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##              main     #819       +/-   ##
============================================
- Coverage   100.00%   31.30%   -68.70%     
============================================
  Files            1      138      +137     
  Lines            6     3725     +3719     
  Branches         1      564      +563     
============================================
+ Hits             6     1166     +1160     
- Misses           0     2511     +2511     
- Partials         0       48       +48     

☔ View full report in Codecov by Sentry.
📢 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Jeevansm25
Copy link
Copy Markdown
Contributor Author

follow up on this PR. The branch is rebased and checks are passing. Would appreciate a review whenever the maintainers hav bandwidth

Copy link
Copy Markdown
Contributor

@WhitWaldo WhitWaldo left a comment

Choose a reason for hiding this comment

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

Looks great - thank you for putting this one together as well. Excellent work!

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.

docs(jsdoc): Phase 5 — Annotate Workflow client and runtime classes

2 participants