Skip to content
Open
12 changes: 10 additions & 2 deletions openapi/openapiv2.json
Original file line number Diff line number Diff line change
Expand Up @@ -12173,6 +12173,10 @@
"startDelay": {
"type": "string",
"description": "Time to wait before dispatching the first activity task. This delay is not applied to retry attempts."
},
"idReusePolicyReturnExistingOutcomeOnReject": {
"type": "boolean",
"description": "Include the outcome in a success response if the activity has completed, and\nid_reuse_policy would have caused a failure response otherwise.\nThis is applicable only when the id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_REJECT_DUPLICATE,\nor the activity succeeded and id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_ALLOW_DUPLICATE_FAILED_ONLY."
}
}
},
Expand Down Expand Up @@ -18946,15 +18950,19 @@
"properties": {
"runId": {
"type": "string",
"description": "The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING)."
"description": "The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING),\nor was already completed when request's id_reuse_policy_return_existing_outcome_on_reject\ncauses an outcome to be included in this response."
},
"started": {
"type": "boolean",
"description": "If true, a new activity was started."
},
"link": {
"$ref": "#/definitions/v1Link",
"description": "Link to the started activity."
"description": "Link to the started activity - or an already completed activity when request's\nid_reuse_policy_return_existing_outcome_on_reject causes an outcome to be included in this."
},
"outcome": {
"$ref": "#/definitions/v1ActivityExecutionOutcome",
"description": "Only set if the activity is already completed and id_reuse_policy_return_existing_outcome_on_reject\nwas true in the request. In that case it also populates the run_id and link for that activity."
}
}
},
Expand Down
22 changes: 20 additions & 2 deletions openapi/openapiv3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16377,19 +16377,37 @@ components:
pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
type: string
description: Time to wait before dispatching the first activity task. This delay is not applied to retry attempts.
idReusePolicyReturnExistingOutcomeOnReject:
type: boolean
description: |-
Include the outcome in a success response if the activity has completed, and
id_reuse_policy would have caused a failure response otherwise.
This is applicable only when the id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_REJECT_DUPLICATE,
or the activity succeeded and id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_ALLOW_DUPLICATE_FAILED_ONLY.
StartActivityExecutionResponse:
type: object
properties:
runId:
type: string
description: The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING).
description: |-
The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING),
or was already completed when request's id_reuse_policy_return_existing_outcome_on_reject
causes an outcome to be included in this response.
started:
type: boolean
description: If true, a new activity was started.
link:
allOf:
- $ref: '#/components/schemas/Link'
description: Link to the started activity.
description: |-
Link to the started activity - or an already completed activity when request's
id_reuse_policy_return_existing_outcome_on_reject causes an outcome to be included in this.
outcome:
allOf:
- $ref: '#/components/schemas/ActivityExecutionOutcome'
description: |-
Only set if the activity is already completed and id_reuse_policy_return_existing_outcome_on_reject
was true in the request. In that case it also populates the run_id and link for that activity.
StartBatchOperationRequest:
type: object
properties:
Expand Down
16 changes: 14 additions & 2 deletions temporal/api/workflowservice/v1/request_response.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3169,15 +3169,27 @@ message StartActivityExecutionRequest {
temporal.api.common.v1.OnConflictOptions on_conflict_options = 21;
// Time to wait before dispatching the first activity task. This delay is not applied to retry attempts.
google.protobuf.Duration start_delay = 22;

// Include the outcome in a success response if the activity has completed, and
// id_reuse_policy would have caused a failure response otherwise.
// This is applicable only when the id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_REJECT_DUPLICATE,
Comment thread
ks-temporal marked this conversation as resolved.
// or the activity succeeded and id_reuse_policy is ACTIVITY_ID_REUSE_POLICY_ALLOW_DUPLICATE_FAILED_ONLY.
bool id_reuse_policy_return_existing_outcome_on_reject = 23;
}

message StartActivityExecutionResponse {
// The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING).
// The run ID of the activity that was started - or used (via ACTIVITY_ID_CONFLICT_POLICY_USE_EXISTING),
// or was already completed when request's id_reuse_policy_return_existing_outcome_on_reject
// causes an outcome to be included in this response.
string run_id = 1;
// If true, a new activity was started.
bool started = 2;
// Link to the started activity.
// Link to the started activity - or an already completed activity when request's
// id_reuse_policy_return_existing_outcome_on_reject causes an outcome to be included in this.
temporal.api.common.v1.Link link = 3;
// Only set if the activity is already completed and id_reuse_policy_return_existing_outcome_on_reject
// was true in the request. In that case it also populates the run_id and link for that activity.
temporal.api.activity.v1.ActivityExecutionOutcome outcome = 4;
Comment thread
ks-temporal marked this conversation as resolved.
}

message DescribeActivityExecutionRequest {
Expand Down
Loading