-
Notifications
You must be signed in to change notification settings - Fork 50
Expose Activity and Workflow instance from context #593
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
base: master
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
a629c3d
to
cd807a3
Compare
// Initialize workflow instance | ||
// | ||
// Resolve arguments if #[WorkflowInit] is used |
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.
Something we do in the other SDKs is we actually run the init method in a special "readonly" context that will throw errors if the user attempts to issue any commands during init. I dunno if that's something that you can readily enforce, but if possible it's a nice bit of safety.
What was changed
Activity::getInstance()
andWorkflow::getInstance()
#[WorkflowInit]
attribute is present, the arguments are resolved.WorkflowInboundCallInterceptor::execute()
is calledWorkflowInboundCallInterceptor::execute()
are recorded in the Workflow history.Tests:
Why?
Checklist