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
25 changes: 8 additions & 17 deletions openapi/openapiv2.json
Original file line number Diff line number Diff line change
Expand Up @@ -13511,9 +13511,14 @@
"type": "string",
"description": "If the state is BLOCKED, blocked reason provides additional information."
},
"outcome": {
"$ref": "#/definitions/v1CallbackOutcome",
"description": "Result of the callback's execution, only set when the callback reaches a terminal state."
"success": {
"type": "object",
"properties": {},
"title": "The callback completed successfully. (Which may include delivering a \"failed\" result successfully.)"
},
"failure": {
"$ref": "#/definitions/v1Failure",
"description": "The failure if the callback was not able to complete successfully. e.g. timed out, received an\nunretriable error, etc."
}
},
"description": "Common callback information. Specific CallbackInfo messages should embed this and may include additional fields."
Expand Down Expand Up @@ -14751,20 +14756,6 @@
},
"description": "Callback to attach to various events in the system, e.g. workflow run completion."
},
"v1CallbackOutcome": {
"type": "object",
"properties": {
"success": {
"type": "object",
"properties": {},
"title": "The callback completed successfully. (Which may include delivering a \"failed\" result successfully.)"
},
"failure": {
"$ref": "#/definitions/v1Failure",
"description": "The failure if the callback was not able to complete successfully. e.g. timed out, received an\nunretriable error, etc."
}
}
},
"v1CallbackState": {
"type": "string",
"enum": [
Expand Down
9 changes: 1 addition & 8 deletions openapi/openapiv3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10905,20 +10905,13 @@ components:
blockedReason:
type: string
description: If the state is BLOCKED, blocked reason provides additional information.
outcome:
allOf:
- $ref: '#/components/schemas/CallbackOutcome'
description: Result of the callback's execution, only set when the callback reaches a terminal state.
description: Common callback information. Specific CallbackInfo messages should embed this and may include additional fields.
CallbackOutcome:
type: object
properties:
failure:
allOf:
- $ref: '#/components/schemas/Failure'
description: |-
The failure if the callback was not able to complete successfully. e.g. timed out, received an
unretriable error, etc.
description: Common callback information. Specific CallbackInfo messages should embed this and may include additional fields.
Callback_Internal:
type: object
properties:
Expand Down
10 changes: 3 additions & 7 deletions temporal/api/callback/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,11 @@ message CallbackInfo {
string blocked_reason = 8;

// Result of the callback's execution, only set when the callback reaches a terminal state.
CallbackOutcome outcome = 9;
}

message CallbackOutcome {
oneof value {
oneof result {
// The callback completed successfully. (Which may include delivering a "failed" result successfully.)
google.protobuf.Empty success = 1;
google.protobuf.Empty success = 9;
// The failure if the callback was not able to complete successfully. e.g. timed out, received an
// unretriable error, etc.
temporal.api.failure.v1.Failure failure = 2;
temporal.api.failure.v1.Failure failure = 10;
}
}
17 changes: 7 additions & 10 deletions temporal/api/notificationservice/v1/request_response.proto
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,16 @@ import "temporal/api/failure/v1/message.proto";
// sent to the worker callback. (In addition to this OnCompleteRequest.)
message OnCompleteRequest {

// The outcome of the source operation.
message Outcome {
oneof result {
// The operation was successful, and resulted in the given payload(s).
temporal.api.common.v1.Payloads success = 1;
// The operation failed. Includes timeout, cancellation, and application errors.
temporal.api.failure.v1.Failure failure = 2;
}
// The result of the source operation.
oneof result {
// The operation was successful, and resulted in the given payload.
temporal.api.common.v1.Payload success = 1;
// The operation failed. Includes timeout, cancellation, and application errors.
temporal.api.failure.v1.Failure failure = 2;
}
Outcome outcome = 1;

// User-supplied data which was added to the source invocation. (As applicable.)
temporal.api.common.v1.Payload source_context = 2;
temporal.api.common.v1.Payload source_context = 3;
}

// OnCompleteResponse is the return type of the OnComplete operation.
Expand Down
Loading