uber-go / cadence-client

Framework for authoring workflows and activities running on top of the Cadence orchestration engine.

Home Page:https://cadenceworkflow.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allows pass context into ReplayPartialWorkflowHistoryFromJSONFile

longquanzheng opened this issue · comments

Because some workflows expect to use the context to get some values for their business logic.

As a workaround, people could use this one for now.

func ReplayWorkflowExecution(ctx context.Context, service workflowserviceclient.Interface, logger *zap.Logger, domain string, execution workflow.Execution) error {

This allows you to pass in context.
But they need to implement a mock workflowserviceclient.Interface for getting history.