Skip to content

Commit ccb8b29

Browse files
committed
Evolve documentation of update polling parameters
1 parent 8ad3751 commit ccb8b29

File tree

4 files changed

+21
-37
lines changed

4 files changed

+21
-37
lines changed

openapi/openapiv2.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -3457,7 +3457,7 @@
34573457
},
34583458
"waitPolicy": {
34593459
"$ref": "#/definitions/v1WaitPolicy",
3460-
"description": "Describes when this request should return - basically whether the\nupdate is synchronous, asynchronous, or somewhere in between."
3460+
"description": "How long to wait before returning control to the caller."
34613461
},
34623462
"request": {
34633463
"type": "object",
@@ -6775,7 +6775,7 @@
67756775
},
67766776
"stage": {
67776777
"$ref": "#/definitions/v1UpdateWorkflowExecutionLifecycleStage",
6778-
"description": "The most advanced lifecycle stage that the Update is known to have\nreached, where lifecycle stages are ordered\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_UNSPECIFIED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.\nUNSPECIFIED will be returned if and only if the server's maximum wait\ntime was reached before the Update reached the stage specified in the\nrequest WaitPolicy, and before the context deadline expired; clients may\nmay then retry the call as needed."
6778+
"description": "The most advanced lifecycle stage that the Update is known to have\nreached, where lifecycle stages are ordered\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.\nIf the server's maximum wait time was reached before the stage requested by the client, then\nthe returned stage may be less than the requested stage. Clients may then retry the call as\nneeded."
67796779
},
67806780
"updateRef": {
67816781
"$ref": "#/definitions/v1UpdateRef",
@@ -8907,7 +8907,7 @@
89078907
},
89088908
"waitPolicy": {
89098909
"$ref": "#/definitions/v1WaitPolicy",
8910-
"description": "Describes when this request should return - basically whether the\nupdate is synchronous, asynchronous, or somewhere in between."
8910+
"description": "How long to wait before returning control to the caller."
89118911
},
89128912
"request": {
89138913
"$ref": "#/definitions/apiupdatev1Request",
@@ -8928,7 +8928,7 @@
89288928
},
89298929
"stage": {
89308930
"$ref": "#/definitions/v1UpdateWorkflowExecutionLifecycleStage",
8931-
"description": "The most advanced lifecycle stage that the Update is known to have\nreached, where lifecycle stages are ordered\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_UNSPECIFIED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.\nUNSPECIFIED will be returned if and only if the server's maximum wait\ntime was reached before the Update reached the stage specified in the\nrequest WaitPolicy, and before the context deadline expired; clients may\nmay then retry the call as needed."
8931+
"description": "The most advanced lifecycle stage that the Update is known to have\nreached, where lifecycle stages are ordered\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <\nUPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.\nIf the server's maximum wait time was reached before the stage requested by the client, then\nthe returned stage may be less than the requested stage. Clients may then retry the call as\nneeded."
89328932
}
89338933
}
89348934
},
@@ -8984,10 +8984,10 @@
89848984
"properties": {
89858985
"lifecycleStage": {
89868986
"$ref": "#/definitions/v1UpdateWorkflowExecutionLifecycleStage",
8987-
"description": "Indicates the update lifecycle stage that the gRPC call should wait for\nbefore returning."
8987+
"description": "The update stage that this request should attempt to wait for."
89888988
}
89898989
},
8990-
"description": "Specifies to the gRPC server how long the client wants the an update-related\nRPC call to wait before returning control to the caller."
8990+
"description": "How long the client wants an update-related RPC call to wait before returning control to the caller."
89918991
},
89928992
"v1WorkerVersionCapabilities": {
89938993
"type": "object",

openapi/openapiv3.yaml

+6-14
Original file line numberDiff line numberDiff line change
@@ -6648,9 +6648,7 @@ components:
66486648
waitPolicy:
66496649
allOf:
66506650
- $ref: '#/components/schemas/WaitPolicy'
6651-
description: |-
6652-
Describes when this request should return - basically whether the
6653-
update is synchronous, asynchronous, or somewhere in between.
6651+
description: How long to wait before returning control to the caller.
66546652
request:
66556653
allOf:
66566654
- $ref: '#/components/schemas/Request'
@@ -6684,14 +6682,12 @@ components:
66846682
description: |-
66856683
The most advanced lifecycle stage that the Update is known to have
66866684
reached, where lifecycle stages are ordered
6687-
UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_UNSPECIFIED <
66886685
UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <
66896686
UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <
66906687
UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.
6691-
UNSPECIFIED will be returned if and only if the server's maximum wait
6692-
time was reached before the Update reached the stage specified in the
6693-
request WaitPolicy, and before the context deadline expired; clients may
6694-
may then retry the call as needed.
6688+
If the server's maximum wait time was reached before the stage requested by the client, then
6689+
the returned stage may be less than the requested stage. Clients may then retry the call as
6690+
needed.
66956691
format: enum
66966692
UpsertWorkflowSearchAttributesEventAttributes:
66976693
type: object
@@ -6728,13 +6724,9 @@ components:
67286724
- UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED
67296725
- UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED
67306726
type: string
6731-
description: |-
6732-
Indicates the update lifecycle stage that the gRPC call should wait for
6733-
before returning.
6727+
description: The update stage that this request should attempt to wait for.
67346728
format: enum
6735-
description: |-
6736-
Specifies to the gRPC server how long the client wants the an update-related
6737-
RPC call to wait before returning control to the caller.
6729+
description: How long the client wants an update-related RPC call to wait before returning control to the caller.
67386730
WorkerVersionCapabilities:
67396731
type: object
67406732
properties:

temporal/api/update/v1/message.proto

+2-5
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,9 @@ import "temporal/api/common/v1/message.proto";
3535
import "temporal/api/enums/v1/update.proto";
3636
import "temporal/api/failure/v1/message.proto";
3737

38-
// Specifies to the gRPC server how long the client wants the an update-related
39-
// RPC call to wait before returning control to the caller.
38+
// How long the client wants an update-related RPC call to wait before returning control to the caller.
4039
message WaitPolicy {
41-
42-
// Indicates the update lifecycle stage that the gRPC call should wait for
43-
// before returning.
40+
// The update stage that this request should attempt to wait for.
4441
temporal.api.enums.v1.UpdateWorkflowExecutionLifecycleStage lifecycle_stage = 1;
4542
}
4643

temporal/api/workflowservice/v1/request_response.proto

+7-12
Original file line numberDiff line numberDiff line change
@@ -1389,8 +1389,7 @@ message UpdateWorkflowExecutionRequest {
13891389
// part of the same execution chain as this id.
13901390
string first_execution_run_id = 3;
13911391

1392-
// Describes when this request should return - basically whether the
1393-
// update is synchronous, asynchronous, or somewhere in between.
1392+
// How long to wait before returning control to the caller.
13941393
temporal.api.update.v1.WaitPolicy wait_policy = 4;
13951394

13961395
// The request information that will be delivered all the way down to the
@@ -1409,14 +1408,12 @@ message UpdateWorkflowExecutionResponse {
14091408

14101409
// The most advanced lifecycle stage that the Update is known to have
14111410
// reached, where lifecycle stages are ordered
1412-
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_UNSPECIFIED <
14131411
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <
14141412
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <
14151413
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.
1416-
// UNSPECIFIED will be returned if and only if the server's maximum wait
1417-
// time was reached before the Update reached the stage specified in the
1418-
// request WaitPolicy, and before the context deadline expired; clients may
1419-
// may then retry the call as needed.
1414+
// If the server's maximum wait time was reached before the stage requested by the client, then
1415+
// the returned stage may be less than the requested stage. Clients may then retry the call as
1416+
// needed.
14201417
temporal.api.enums.v1.UpdateWorkflowExecutionLifecycleStage stage = 3;
14211418
}
14221419

@@ -1535,14 +1532,12 @@ message PollWorkflowExecutionUpdateResponse {
15351532
temporal.api.update.v1.Outcome outcome = 1;
15361533
// The most advanced lifecycle stage that the Update is known to have
15371534
// reached, where lifecycle stages are ordered
1538-
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_UNSPECIFIED <
15391535
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ADMITTED <
15401536
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_ACCEPTED <
15411537
// UPDATE_WORKFLOW_EXECUTION_LIFECYCLE_STAGE_COMPLETED.
1542-
// UNSPECIFIED will be returned if and only if the server's maximum wait
1543-
// time was reached before the Update reached the stage specified in the
1544-
// request WaitPolicy, and before the context deadline expired; clients may
1545-
// may then retry the call as needed.
1538+
// If the server's maximum wait time was reached before the stage requested by the client, then
1539+
// the returned stage may be less than the requested stage. Clients may then retry the call as
1540+
// needed.
15461541
temporal.api.enums.v1.UpdateWorkflowExecutionLifecycleStage stage = 2;
15471542
// Sufficient information to address this update.
15481543
temporal.api.update.v1.UpdateRef update_ref = 3;

0 commit comments

Comments
 (0)