Skip to content

Fix newExternalWorkflowStub on a interfaces without a WorkflowMethod #2531

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Quinn-With-Two-Ns
Copy link
Contributor

Fix a bug causing newExternalWorkflowStub to fail on interfaces without WorkflowMethod

closes #2180

Fix a bug causing newExternalWorkflowStub to fail on interfaces without WorkflowMethod
@Quinn-With-Two-Ns Quinn-With-Two-Ns requested a review from a team as a code owner May 17, 2025 07:02
@@ -20,7 +20,7 @@ public ExternalWorkflowInvocationHandler(
WorkflowExecution execution,
WorkflowOutboundCallsInterceptor workflowOutboundCallsInterceptor,
Functions.Proc1<String> assertReadOnly) {
this.workflowMetadata = POJOWorkflowInterfaceMetadata.newInstance(workflowInterface);
this.workflowMetadata = POJOWorkflowInterfaceMetadata.newInstance(workflowInterface, false);
Copy link
Member

Choose a reason for hiding this comment

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

Got a bit confused on this trailing param reading:

if true, methods of the {@code anInterface} that are
annotated with {@link WorkflowMethod}, {@link QueryMethod}, {@link UpdateMethod}, {@link
UpdateValidatorMethod} or {@link SignalMethod} are processed like {@code current} is a
workflow interface even if it is not annotated with {@link WorkflowInterface} itself.

That'd make me think the default of true should work with non-workflow interfaces. But maybe I'm misunderstanding what was meant there.

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.

Workflow.newExternalWorkflowStub
2 participants