Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions openapi/openapiv2.json
Original file line number Diff line number Diff line change
Expand Up @@ -18389,6 +18389,10 @@
},
"queryRejected": {
"$ref": "#/definitions/v1QueryRejected"
},
"link": {
"$ref": "#/definitions/v1Link",
"description": "Holds the link to the Workflow execution that processed the Query."
}
}
},
Expand Down
4 changes: 4 additions & 0 deletions openapi/openapiv3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14905,6 +14905,10 @@ components:
$ref: '#/components/schemas/Payloads'
queryRejected:
$ref: '#/components/schemas/QueryRejected'
link:
allOf:
- $ref: '#/components/schemas/Link'
description: Holds the link to the Workflow execution that processed the Query.
RampByPercentage:
type: object
properties:
Expand Down
2 changes: 2 additions & 0 deletions temporal/api/workflowservice/v1/request_response.proto
Original file line number Diff line number Diff line change
Expand Up @@ -1187,6 +1187,8 @@ message QueryWorkflowRequest {
message QueryWorkflowResponse {
temporal.api.common.v1.Payloads query_result = 1;
temporal.api.query.v1.QueryRejected query_rejected = 2;
// Holds the link to the Workflow execution that processed the Query.
temporal.api.common.v1.Link link = 3;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

JFYI, I asked Claude if it was common to have a singular link in a -Response field vs. a repeated links for some hypothetical future where you would want multiple links back.

As it turns out, a singular link is the way to go. 👍


Five -Response messages have a temporal.api.common.v1.Link field, and all five are singular — none are repeated:

┌──────────────────────────────────────────┬──────────────────────┬─────────────────────────────┐
│                 Message                  │        Field         │            Line             │
├──────────────────────────────────────────┼──────────────────────┼─────────────────────────────┤
│ StartWorkflowExecutionResponse           │ Link link = 4        │ request_response.proto:238  │
├──────────────────────────────────────────┼──────────────────────┼─────────────────────────────┤
│ SignalWorkflowExecutionResponse          │ Link link = 1        │ request_response.proto:874  │
├──────────────────────────────────────────┼──────────────────────┼─────────────────────────────┤
│ SignalWithStartWorkflowExecutionResponse │ Link signal_link = 3 │ request_response.proto:952  │
├──────────────────────────────────────────┼──────────────────────┼─────────────────────────────┤
│ UpdateWorkflowExecutionResponse          │ Link link = 4        │ request_response.proto:1862 │
├──────────────────────────────────────────┼──────────────────────┼─────────────────────────────┤
│ StartActivityExecutionResponse           │ Link link = 3        │ request_response.proto:3258 │
└──────────────────────────────────────────┴──────────────────────┴─────────────────────────────┘

So: 5 singular, 0 repeated.

For contrast, the repeated links pattern shows up only on the request side — StartWorkflowExecutionRequest, RequestCancelWorkflowExecutionRequest, SignalWorkflowExecutionRequest, SignalWithStartWorkflowExecutionRequest, TerminateWorkflowExecutionRequest, and StartActivityExecutionRequest. Requests accept N inbound links; responses return the one link identifying the event they produced.

}

message DescribeWorkflowExecutionRequest {
Expand Down
Loading