@temporalio/core-bridge 1.5.2 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Cargo.lock +304 -112
- package/lib/index.d.ts +8 -6
- package/lib/index.js.map +1 -1
- package/package.json +9 -4
- package/releases/aarch64-apple-darwin/index.node +0 -0
- package/releases/aarch64-unknown-linux-gnu/index.node +0 -0
- package/releases/x86_64-apple-darwin/index.node +0 -0
- package/releases/x86_64-pc-windows-msvc/index.node +0 -0
- package/releases/x86_64-unknown-linux-gnu/index.node +0 -0
- package/sdk-core/.buildkite/docker/Dockerfile +2 -2
- package/sdk-core/.buildkite/docker/docker-compose.yaml +1 -1
- package/sdk-core/.buildkite/pipeline.yml +2 -4
- package/sdk-core/.cargo/config.toml +5 -2
- package/sdk-core/.github/workflows/heavy.yml +29 -0
- package/sdk-core/Cargo.toml +1 -1
- package/sdk-core/README.md +20 -10
- package/sdk-core/client/src/lib.rs +215 -39
- package/sdk-core/client/src/metrics.rs +17 -8
- package/sdk-core/client/src/raw.rs +4 -4
- package/sdk-core/client/src/retry.rs +32 -20
- package/sdk-core/core/Cargo.toml +25 -12
- package/sdk-core/core/src/abstractions/take_cell.rs +28 -0
- package/sdk-core/core/src/abstractions.rs +204 -14
- package/sdk-core/core/src/core_tests/activity_tasks.rs +143 -50
- package/sdk-core/core/src/core_tests/child_workflows.rs +6 -5
- package/sdk-core/core/src/core_tests/determinism.rs +165 -2
- package/sdk-core/core/src/core_tests/local_activities.rs +431 -43
- package/sdk-core/core/src/core_tests/queries.rs +34 -16
- package/sdk-core/core/src/core_tests/workers.rs +8 -5
- package/sdk-core/core/src/core_tests/workflow_tasks.rs +588 -55
- package/sdk-core/core/src/ephemeral_server/mod.rs +113 -12
- package/sdk-core/core/src/internal_flags.rs +155 -0
- package/sdk-core/core/src/lib.rs +16 -9
- package/sdk-core/core/src/protosext/mod.rs +1 -1
- package/sdk-core/core/src/replay/mod.rs +16 -27
- package/sdk-core/core/src/telemetry/log_export.rs +1 -1
- package/sdk-core/core/src/telemetry/metrics.rs +69 -35
- package/sdk-core/core/src/telemetry/mod.rs +60 -21
- package/sdk-core/core/src/telemetry/prometheus_server.rs +19 -13
- package/sdk-core/core/src/test_help/mod.rs +73 -14
- package/sdk-core/core/src/worker/activities/activity_heartbeat_manager.rs +119 -160
- package/sdk-core/core/src/worker/activities/activity_task_poller_stream.rs +89 -0
- package/sdk-core/core/src/worker/activities/local_activities.rs +379 -129
- package/sdk-core/core/src/worker/activities.rs +350 -175
- package/sdk-core/core/src/worker/client/mocks.rs +22 -2
- package/sdk-core/core/src/worker/client.rs +18 -2
- package/sdk-core/core/src/worker/mod.rs +183 -64
- package/sdk-core/core/src/worker/workflow/bridge.rs +1 -3
- package/sdk-core/core/src/worker/workflow/driven_workflow.rs +3 -5
- package/sdk-core/core/src/worker/workflow/history_update.rs +916 -277
- package/sdk-core/core/src/worker/workflow/machines/activity_state_machine.rs +216 -183
- package/sdk-core/core/src/worker/workflow/machines/cancel_external_state_machine.rs +9 -12
- package/sdk-core/core/src/worker/workflow/machines/cancel_workflow_state_machine.rs +7 -9
- package/sdk-core/core/src/worker/workflow/machines/child_workflow_state_machine.rs +160 -87
- package/sdk-core/core/src/worker/workflow/machines/complete_workflow_state_machine.rs +13 -14
- package/sdk-core/core/src/worker/workflow/machines/continue_as_new_workflow_state_machine.rs +7 -9
- package/sdk-core/core/src/worker/workflow/machines/fail_workflow_state_machine.rs +14 -17
- package/sdk-core/core/src/worker/workflow/machines/local_activity_state_machine.rs +242 -110
- package/sdk-core/core/src/worker/workflow/machines/mod.rs +27 -19
- package/sdk-core/core/src/worker/workflow/machines/modify_workflow_properties_state_machine.rs +9 -11
- package/sdk-core/core/src/worker/workflow/machines/patch_state_machine.rs +321 -206
- package/sdk-core/core/src/worker/workflow/machines/signal_external_state_machine.rs +13 -18
- package/sdk-core/core/src/worker/workflow/machines/timer_state_machine.rs +20 -29
- package/sdk-core/core/src/worker/workflow/machines/transition_coverage.rs +2 -2
- package/sdk-core/core/src/worker/workflow/machines/upsert_search_attributes_state_machine.rs +257 -51
- package/sdk-core/core/src/worker/workflow/machines/workflow_machines/local_acts.rs +6 -17
- package/sdk-core/core/src/worker/workflow/machines/workflow_machines.rs +310 -150
- package/sdk-core/core/src/worker/workflow/machines/workflow_task_state_machine.rs +17 -20
- package/sdk-core/core/src/worker/workflow/managed_run/managed_wf_test.rs +31 -15
- package/sdk-core/core/src/worker/workflow/managed_run.rs +1052 -380
- package/sdk-core/core/src/worker/workflow/mod.rs +598 -390
- package/sdk-core/core/src/worker/workflow/run_cache.rs +40 -57
- package/sdk-core/core/src/worker/workflow/wft_extraction.rs +137 -0
- package/sdk-core/core/src/worker/workflow/wft_poller.rs +1 -4
- package/sdk-core/core/src/worker/workflow/workflow_stream/saved_wf_inputs.rs +117 -0
- package/sdk-core/core/src/worker/workflow/workflow_stream/tonic_status_serde.rs +24 -0
- package/sdk-core/core/src/worker/workflow/workflow_stream.rs +469 -718
- package/sdk-core/core-api/Cargo.toml +2 -1
- package/sdk-core/core-api/src/errors.rs +1 -34
- package/sdk-core/core-api/src/lib.rs +19 -9
- package/sdk-core/core-api/src/telemetry.rs +4 -6
- package/sdk-core/core-api/src/worker.rs +19 -1
- package/sdk-core/etc/deps.svg +115 -140
- package/sdk-core/etc/regen-depgraph.sh +5 -0
- package/sdk-core/fsm/rustfsm_procmacro/src/lib.rs +86 -61
- package/sdk-core/fsm/rustfsm_trait/src/lib.rs +29 -71
- package/sdk-core/histories/ends_empty_wft_complete.bin +0 -0
- package/sdk-core/histories/evict_while_la_running_no_interference-16_history.bin +0 -0
- package/sdk-core/histories/old_change_marker_format.bin +0 -0
- package/sdk-core/protos/api_upstream/.github/CODEOWNERS +2 -1
- package/sdk-core/protos/api_upstream/Makefile +6 -6
- package/sdk-core/protos/api_upstream/build/go.mod +7 -0
- package/sdk-core/protos/api_upstream/build/go.sum +5 -0
- package/sdk-core/protos/api_upstream/build/tools.go +29 -0
- package/sdk-core/protos/api_upstream/go.mod +6 -0
- package/sdk-core/protos/api_upstream/temporal/api/batch/v1/message.proto +9 -2
- package/sdk-core/protos/api_upstream/temporal/api/command/v1/message.proto +7 -26
- package/sdk-core/protos/api_upstream/temporal/api/common/v1/message.proto +13 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/batch_operation.proto +3 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/command_type.proto +3 -7
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/common.proto +3 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/event_type.proto +8 -8
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/failed_cause.proto +25 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/namespace.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/query.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/reset.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/schedule.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/task_queue.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/update.proto +24 -19
- package/sdk-core/protos/api_upstream/temporal/api/enums/v1/workflow.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/errordetails/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/failure/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/filter/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/history/v1/message.proto +49 -26
- package/sdk-core/protos/api_upstream/temporal/api/namespace/v1/message.proto +4 -2
- package/sdk-core/protos/api_upstream/temporal/api/operatorservice/v1/request_response.proto +5 -2
- package/sdk-core/protos/api_upstream/temporal/api/operatorservice/v1/service.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/protocol/v1/message.proto +57 -0
- package/sdk-core/protos/api_upstream/temporal/api/query/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/replication/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/schedule/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/sdk/v1/task_complete_metadata.proto +63 -0
- package/sdk-core/protos/api_upstream/temporal/api/taskqueue/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/update/v1/message.proto +71 -6
- package/sdk-core/protos/api_upstream/temporal/api/version/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/workflow/v1/message.proto +2 -2
- package/sdk-core/protos/api_upstream/temporal/api/workflowservice/v1/request_response.proto +64 -28
- package/sdk-core/protos/api_upstream/temporal/api/workflowservice/v1/service.proto +4 -4
- package/sdk-core/protos/local/temporal/sdk/core/activity_result/activity_result.proto +7 -8
- package/sdk-core/protos/local/temporal/sdk/core/activity_task/activity_task.proto +10 -7
- package/sdk-core/protos/local/temporal/sdk/core/child_workflow/child_workflow.proto +19 -30
- package/sdk-core/protos/local/temporal/sdk/core/common/common.proto +1 -0
- package/sdk-core/protos/local/temporal/sdk/core/core_interface.proto +1 -0
- package/sdk-core/protos/local/temporal/sdk/core/external_data/external_data.proto +8 -0
- package/sdk-core/protos/local/temporal/sdk/core/workflow_activation/workflow_activation.proto +67 -60
- package/sdk-core/protos/local/temporal/sdk/core/workflow_commands/workflow_commands.proto +85 -84
- package/sdk-core/protos/local/temporal/sdk/core/workflow_completion/workflow_completion.proto +9 -3
- package/sdk-core/protos/testsrv_upstream/temporal/api/testservice/v1/request_response.proto +2 -2
- package/sdk-core/protos/testsrv_upstream/temporal/api/testservice/v1/service.proto +2 -2
- package/sdk-core/sdk/Cargo.toml +5 -4
- package/sdk-core/sdk/src/lib.rs +108 -26
- package/sdk-core/sdk/src/workflow_context/options.rs +7 -1
- package/sdk-core/sdk/src/workflow_context.rs +24 -17
- package/sdk-core/sdk/src/workflow_future.rs +16 -15
- package/sdk-core/sdk-core-protos/Cargo.toml +5 -2
- package/sdk-core/sdk-core-protos/build.rs +36 -2
- package/sdk-core/sdk-core-protos/src/history_builder.rs +138 -106
- package/sdk-core/sdk-core-protos/src/history_info.rs +10 -1
- package/sdk-core/sdk-core-protos/src/lib.rs +272 -87
- package/sdk-core/sdk-core-protos/src/task_token.rs +12 -2
- package/sdk-core/test-utils/Cargo.toml +3 -1
- package/sdk-core/test-utils/src/canned_histories.rs +106 -296
- package/sdk-core/test-utils/src/histfetch.rs +1 -1
- package/sdk-core/test-utils/src/lib.rs +82 -23
- package/sdk-core/test-utils/src/wf_input_saver.rs +50 -0
- package/sdk-core/test-utils/src/workflows.rs +29 -0
- package/sdk-core/tests/fuzzy_workflow.rs +130 -0
- package/sdk-core/tests/{load_tests.rs → heavy_tests.rs} +125 -51
- package/sdk-core/tests/integ_tests/ephemeral_server_tests.rs +25 -3
- package/sdk-core/tests/integ_tests/heartbeat_tests.rs +10 -5
- package/sdk-core/tests/integ_tests/metrics_tests.rs +218 -16
- package/sdk-core/tests/integ_tests/polling_tests.rs +4 -47
- package/sdk-core/tests/integ_tests/queries_tests.rs +5 -128
- package/sdk-core/tests/integ_tests/visibility_tests.rs +83 -25
- package/sdk-core/tests/integ_tests/workflow_tests/activities.rs +161 -72
- package/sdk-core/tests/integ_tests/workflow_tests/cancel_external.rs +1 -0
- package/sdk-core/tests/integ_tests/workflow_tests/cancel_wf.rs +6 -13
- package/sdk-core/tests/integ_tests/workflow_tests/child_workflows.rs +80 -3
- package/sdk-core/tests/integ_tests/workflow_tests/continue_as_new.rs +6 -2
- package/sdk-core/tests/integ_tests/workflow_tests/determinism.rs +3 -10
- package/sdk-core/tests/integ_tests/workflow_tests/local_activities.rs +94 -200
- package/sdk-core/tests/integ_tests/workflow_tests/modify_wf_properties.rs +2 -4
- package/sdk-core/tests/integ_tests/workflow_tests/patches.rs +34 -28
- package/sdk-core/tests/integ_tests/workflow_tests/replay.rs +76 -7
- package/sdk-core/tests/integ_tests/workflow_tests/resets.rs +1 -0
- package/sdk-core/tests/integ_tests/workflow_tests/signals.rs +18 -14
- package/sdk-core/tests/integ_tests/workflow_tests/stickyness.rs +6 -20
- package/sdk-core/tests/integ_tests/workflow_tests/timers.rs +10 -21
- package/sdk-core/tests/integ_tests/workflow_tests/upsert_search_attrs.rs +7 -8
- package/sdk-core/tests/integ_tests/workflow_tests.rs +13 -14
- package/sdk-core/tests/main.rs +3 -13
- package/sdk-core/tests/runner.rs +75 -36
- package/sdk-core/tests/wf_input_replay.rs +32 -0
- package/src/conversions.rs +14 -8
- package/src/runtime.rs +9 -8
- package/ts/index.ts +8 -6
- package/sdk-core/bridge-ffi/Cargo.toml +0 -24
- package/sdk-core/bridge-ffi/LICENSE.txt +0 -23
- package/sdk-core/bridge-ffi/build.rs +0 -25
- package/sdk-core/bridge-ffi/include/sdk-core-bridge.h +0 -224
- package/sdk-core/bridge-ffi/src/lib.rs +0 -746
- package/sdk-core/bridge-ffi/src/wrappers.rs +0 -221
- package/sdk-core/protos/local/temporal/sdk/core/bridge/bridge.proto +0 -210
- package/sdk-core/sdk/src/conversions.rs +0 -8
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/replication/v1;replication";
|
|
|
28
28
|
option java_package = "io.temporal.api.replication.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "MessageProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::Replication::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.Replication.V1";
|
|
33
33
|
|
|
34
34
|
import "google/protobuf/timestamp.proto";
|
|
35
35
|
|
|
@@ -33,8 +33,8 @@ option go_package = "go.temporal.io/api/schedule/v1;schedule";
|
|
|
33
33
|
option java_package = "io.temporal.api.schedule.v1";
|
|
34
34
|
option java_multiple_files = true;
|
|
35
35
|
option java_outer_classname = "MessageProto";
|
|
36
|
-
option ruby_package = "
|
|
37
|
-
option csharp_namespace = "
|
|
36
|
+
option ruby_package = "Temporalio::Api::Schedule::V1";
|
|
37
|
+
option csharp_namespace = "Temporalio.Api.Schedule.V1";
|
|
38
38
|
|
|
39
39
|
import "google/protobuf/duration.proto";
|
|
40
40
|
import "google/protobuf/timestamp.proto";
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
// The MIT License
|
|
2
|
+
//
|
|
3
|
+
// Copyright (c) 2020 Temporal Technologies Inc. All rights reserved.
|
|
4
|
+
//
|
|
5
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
// in the Software without restriction, including without limitation the rights
|
|
8
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
// furnished to do so, subject to the following conditions:
|
|
11
|
+
//
|
|
12
|
+
// The above copyright notice and this permission notice shall be included in
|
|
13
|
+
// all copies or substantial portions of the Software.
|
|
14
|
+
//
|
|
15
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
21
|
+
// THE SOFTWARE.
|
|
22
|
+
|
|
23
|
+
syntax = "proto3";
|
|
24
|
+
|
|
25
|
+
package temporal.api.sdk.v1;
|
|
26
|
+
|
|
27
|
+
option go_package = "go.temporal.io/api/sdk/v1;sdk";
|
|
28
|
+
option java_package = "io.temporal.api.sdk.v1";
|
|
29
|
+
option java_multiple_files = true;
|
|
30
|
+
option java_outer_classname = "TaskCompleteMetadataProto";
|
|
31
|
+
option ruby_package = "Temporalio::Api::Sdk::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.Sdk.V1";
|
|
33
|
+
|
|
34
|
+
message WorkflowTaskCompletedMetadata {
|
|
35
|
+
// Internal flags used by the core SDK. SDKs using flags must comply with the following behavior:
|
|
36
|
+
//
|
|
37
|
+
// During replay:
|
|
38
|
+
// * If a flag is not recognized (value is too high or not defined), it must fail the workflow
|
|
39
|
+
// task.
|
|
40
|
+
// * If a flag is recognized, it is stored in a set of used flags for the run. Code checks for
|
|
41
|
+
// that flag during and after this WFT are allowed to assume that the flag is present.
|
|
42
|
+
// * If a code check for a flag does not find the flag in the set of used flags, it must take
|
|
43
|
+
// the branch corresponding to the absence of that flag.
|
|
44
|
+
//
|
|
45
|
+
// During non-replay execution of new WFTs:
|
|
46
|
+
// * The SDK is free to use all flags it knows about. It must record any newly-used (IE: not
|
|
47
|
+
// previously recorded) flags when completing the WFT.
|
|
48
|
+
//
|
|
49
|
+
// SDKs which are too old to even know about this field at all are considered to produce
|
|
50
|
+
// undefined behavior if they replay workflows which used this mechanism.
|
|
51
|
+
//
|
|
52
|
+
// (-- api-linter: core::0141::forbidden-types=disabled
|
|
53
|
+
// aip.dev/not-precedent: These really shouldn't have negative values. --)
|
|
54
|
+
repeated uint32 core_used_flags = 1;
|
|
55
|
+
|
|
56
|
+
// Flags used by the SDK lang. No attempt is made to distinguish between different SDK languages
|
|
57
|
+
// here as processing a workflow with a different language than the one which authored it is
|
|
58
|
+
// already undefined behavior. See `core_used_patches` for more.
|
|
59
|
+
//
|
|
60
|
+
// (-- api-linter: core::0141::forbidden-types=disabled
|
|
61
|
+
// aip.dev/not-precedent: These really shouldn't have negative values. --)
|
|
62
|
+
repeated uint32 lang_used_flags = 2;
|
|
63
|
+
}
|
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/taskqueue/v1;taskqueue";
|
|
|
28
28
|
option java_package = "io.temporal.api.taskqueue.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "MessageProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::TaskQueue::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.TaskQueue.V1";
|
|
33
33
|
|
|
34
34
|
import "google/protobuf/duration.proto";
|
|
35
35
|
import "google/protobuf/timestamp.proto";
|
|
@@ -28,19 +28,84 @@ option go_package = "go.temporal.io/api/update/v1;update";
|
|
|
28
28
|
option java_package = "io.temporal.api.update.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "MessageProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::Update::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.Update.V1";
|
|
33
33
|
|
|
34
34
|
import "temporal/api/common/v1/message.proto";
|
|
35
|
+
import "temporal/api/enums/v1/update.proto";
|
|
36
|
+
import "temporal/api/failure/v1/message.proto";
|
|
35
37
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
+
// Sepcifies to the gRPC server how the client wants the UpdateWorkflowExecution
|
|
39
|
+
// call to wait before returning control to the caller.
|
|
40
|
+
message WaitPolicy {
|
|
41
|
+
|
|
42
|
+
// Indicates the update lifecycle stage that the gRPC call should wait for
|
|
43
|
+
// before returning.
|
|
44
|
+
temporal.api.enums.v1.UpdateWorkflowExecutionLifecycleStage lifecycle_stage = 1;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// The data needed by a client to refer to an previously invoked workflow
|
|
48
|
+
// execution update process.
|
|
49
|
+
message UpdateRef {
|
|
50
|
+
temporal.api.common.v1.WorkflowExecution workflow_execution = 1;
|
|
51
|
+
string update_id = 2;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// The outcome of a workflow update - success or failure.
|
|
55
|
+
message Outcome {
|
|
56
|
+
oneof value {
|
|
57
|
+
temporal.api.common.v1.Payloads success = 1;
|
|
58
|
+
temporal.api.failure.v1.Failure failure = 2;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
// Metadata about a workflow execution update.
|
|
63
|
+
message Meta {
|
|
64
|
+
// An ID with workflow-scoped uniqueness for this update
|
|
65
|
+
string update_id = 1;
|
|
66
|
+
|
|
67
|
+
// A string identifying the agent that requested this update.
|
|
68
|
+
string identity = 2;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
message Input {
|
|
72
|
+
// Headers that are passed with the update from the requesting entity.
|
|
38
73
|
// These can include things like auth or tracing tokens.
|
|
39
74
|
temporal.api.common.v1.Header header = 1;
|
|
40
75
|
|
|
41
|
-
// The name of the
|
|
76
|
+
// The name of the input handler to invoke on the target workflow
|
|
42
77
|
string name = 2;
|
|
43
78
|
|
|
44
|
-
// The arguments to pass to the named
|
|
79
|
+
// The arguments to pass to the named handler.
|
|
45
80
|
temporal.api.common.v1.Payloads args = 3;
|
|
46
81
|
}
|
|
82
|
+
|
|
83
|
+
// The client request that triggers a workflow execution update
|
|
84
|
+
message Request {
|
|
85
|
+
Meta meta = 1;
|
|
86
|
+
Input input = 2;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
// An update protocol message indicating that a workflow execution update has
|
|
90
|
+
// been rejected.
|
|
91
|
+
message Rejection {
|
|
92
|
+
string rejected_request_message_id = 1;
|
|
93
|
+
int64 rejected_request_sequencing_event_id = 2;
|
|
94
|
+
Request rejected_request = 3;
|
|
95
|
+
temporal.api.failure.v1.Failure failure = 4;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// An update protocol message indicating that a workflow execution update has
|
|
99
|
+
// been accepted (i.e. passed the worker-side validation phase).
|
|
100
|
+
message Acceptance {
|
|
101
|
+
string accepted_request_message_id = 1;
|
|
102
|
+
int64 accepted_request_sequencing_event_id = 2;
|
|
103
|
+
Request accepted_request = 3;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
// An update protocol message indicating that a workflow execution update has
|
|
107
|
+
// completed with the contained outcome.
|
|
108
|
+
message Response {
|
|
109
|
+
Meta meta = 1;
|
|
110
|
+
Outcome outcome = 2;
|
|
111
|
+
}
|
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/version/v1;version";
|
|
|
28
28
|
option java_package = "io.temporal.api.version.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "MessageProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::Version::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.Version.V1";
|
|
33
33
|
|
|
34
34
|
import "google/protobuf/timestamp.proto";
|
|
35
35
|
import "dependencies/gogoproto/gogo.proto";
|
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/workflow/v1;workflow";
|
|
|
28
28
|
option java_package = "io.temporal.api.workflow.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "MessageProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::Workflow::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.Workflow.V1";
|
|
33
33
|
|
|
34
34
|
import "google/protobuf/duration.proto";
|
|
35
35
|
import "google/protobuf/timestamp.proto";
|
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/workflowservice/v1;workflowservice";
|
|
|
28
28
|
option java_package = "io.temporal.api.workflowservice.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "RequestResponseProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::WorkflowService::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.WorkflowService.V1";
|
|
33
33
|
|
|
34
34
|
import "temporal/api/enums/v1/batch_operation.proto";
|
|
35
35
|
import "temporal/api/enums/v1/workflow.proto";
|
|
@@ -39,13 +39,13 @@ import "temporal/api/enums/v1/common.proto";
|
|
|
39
39
|
import "temporal/api/enums/v1/query.proto";
|
|
40
40
|
import "temporal/api/enums/v1/reset.proto";
|
|
41
41
|
import "temporal/api/enums/v1/task_queue.proto";
|
|
42
|
-
import "temporal/api/enums/v1/update.proto";
|
|
43
42
|
import "temporal/api/common/v1/message.proto";
|
|
44
43
|
import "temporal/api/history/v1/message.proto";
|
|
45
44
|
import "temporal/api/workflow/v1/message.proto";
|
|
46
45
|
import "temporal/api/command/v1/message.proto";
|
|
47
46
|
import "temporal/api/failure/v1/message.proto";
|
|
48
47
|
import "temporal/api/filter/v1/message.proto";
|
|
48
|
+
import "temporal/api/protocol/v1/message.proto";
|
|
49
49
|
import "temporal/api/namespace/v1/message.proto";
|
|
50
50
|
import "temporal/api/query/v1/message.proto";
|
|
51
51
|
import "temporal/api/replication/v1/message.proto";
|
|
@@ -54,6 +54,7 @@ import "temporal/api/taskqueue/v1/message.proto";
|
|
|
54
54
|
import "temporal/api/update/v1/message.proto";
|
|
55
55
|
import "temporal/api/version/v1/message.proto";
|
|
56
56
|
import "temporal/api/batch/v1/message.proto";
|
|
57
|
+
import "temporal/api/sdk/v1/task_complete_metadata.proto";
|
|
57
58
|
|
|
58
59
|
import "google/protobuf/duration.proto";
|
|
59
60
|
import "google/protobuf/timestamp.proto";
|
|
@@ -168,10 +169,25 @@ message StartWorkflowExecutionRequest {
|
|
|
168
169
|
temporal.api.common.v1.Memo memo = 14;
|
|
169
170
|
temporal.api.common.v1.SearchAttributes search_attributes = 15;
|
|
170
171
|
temporal.api.common.v1.Header header = 16;
|
|
172
|
+
// Request to get the first workflow task inline in the response bypassing matching service and worker polling.
|
|
173
|
+
// If set to `true` the caller is expected to have a worker available and capable of processing the task.
|
|
174
|
+
// The returned task will be marked as started and is expected to be completed by the specified
|
|
175
|
+
// `workflow_task_timeout`.
|
|
176
|
+
bool request_eager_execution = 17;
|
|
177
|
+
// These values will be available as ContinuedFailure and LastCompletionResult in the
|
|
178
|
+
// WorkflowExecutionStarted event and through SDKs. The are currently only used by the
|
|
179
|
+
// server itself (for the schedules feature) and are not intended to be exposed in
|
|
180
|
+
// StartWorkflowExecution.
|
|
181
|
+
temporal.api.failure.v1.Failure continued_failure = 18;
|
|
182
|
+
temporal.api.common.v1.Payloads last_completion_result = 19;
|
|
171
183
|
}
|
|
172
184
|
|
|
173
185
|
message StartWorkflowExecutionResponse {
|
|
174
186
|
string run_id = 1;
|
|
187
|
+
// When `request_eager_execution` is set on the `StartWorkflowExecutionRequest`, the server - if supported - will
|
|
188
|
+
// return the first workflow task to be eagerly executed.
|
|
189
|
+
// The caller is expected to have a worker available to process the task.
|
|
190
|
+
PollWorkflowTaskQueueResponse eager_workflow_task = 2;
|
|
175
191
|
}
|
|
176
192
|
|
|
177
193
|
message GetWorkflowExecutionHistoryRequest {
|
|
@@ -267,6 +283,8 @@ message PollWorkflowTaskQueueResponse {
|
|
|
267
283
|
// Queries that should be executed after applying the history in this task. Responses should be
|
|
268
284
|
// attached to `RespondWorkflowTaskCompletedRequest::query_results`
|
|
269
285
|
map<string, temporal.api.query.v1.WorkflowQuery> queries = 14;
|
|
286
|
+
// Protocol messages piggybacking on a WFT as a transport
|
|
287
|
+
repeated temporal.api.protocol.v1.Message messages = 15;
|
|
270
288
|
}
|
|
271
289
|
|
|
272
290
|
message RespondWorkflowTaskCompletedRequest {
|
|
@@ -297,6 +315,13 @@ message RespondWorkflowTaskCompletedRequest {
|
|
|
297
315
|
// When `worker_versioning_id` has a `worker_build_id`, and `binary_checksum` is not
|
|
298
316
|
// set, that value should also be considered as the `binary_checksum`.
|
|
299
317
|
temporal.api.taskqueue.v1.VersionId worker_versioning_id = 10;
|
|
318
|
+
// Protocol messages piggybacking on a WFT as a transport
|
|
319
|
+
repeated temporal.api.protocol.v1.Message messages = 11;
|
|
320
|
+
// Data the SDK wishes to record for itself, but server need not interpret, and does not
|
|
321
|
+
// directly impact workflow state.
|
|
322
|
+
temporal.api.sdk.v1.WorkflowTaskCompletedMetadata sdk_metadata = 12;
|
|
323
|
+
// Local usage data collected for metering
|
|
324
|
+
temporal.api.common.v1.MeteringMetadata metering_metadata = 13;
|
|
300
325
|
}
|
|
301
326
|
|
|
302
327
|
message RespondWorkflowTaskCompletedResponse {
|
|
@@ -304,6 +329,8 @@ message RespondWorkflowTaskCompletedResponse {
|
|
|
304
329
|
PollWorkflowTaskQueueResponse workflow_task = 1;
|
|
305
330
|
// See `ScheduleActivityTaskCommandAttributes::request_start`
|
|
306
331
|
repeated PollActivityTaskQueueResponse activity_tasks = 2;
|
|
332
|
+
|
|
333
|
+
int64 reset_history_event_id = 3;
|
|
307
334
|
}
|
|
308
335
|
|
|
309
336
|
message RespondWorkflowTaskFailedRequest {
|
|
@@ -319,6 +346,8 @@ message RespondWorkflowTaskFailedRequest {
|
|
|
319
346
|
// Worker process' unique binary id
|
|
320
347
|
string binary_checksum = 5;
|
|
321
348
|
string namespace = 6;
|
|
349
|
+
// Protocol messages piggybacking on a WFT as a transport
|
|
350
|
+
repeated temporal.api.protocol.v1.Message messages = 7;
|
|
322
351
|
}
|
|
323
352
|
|
|
324
353
|
message RespondWorkflowTaskFailedResponse {
|
|
@@ -847,6 +876,13 @@ message GetSystemInfoResponse {
|
|
|
847
876
|
|
|
848
877
|
// True if server supports upserting workflow memo
|
|
849
878
|
bool upsert_memo = 7;
|
|
879
|
+
|
|
880
|
+
// True if server supports eager workflow task dispatching for the StartWorkflowExecution API
|
|
881
|
+
bool eager_workflow_start = 8;
|
|
882
|
+
|
|
883
|
+
// True if the server knows about the sdk metadata field on WFT completions and will record
|
|
884
|
+
// it in history
|
|
885
|
+
bool sdk_metadata = 9;
|
|
850
886
|
}
|
|
851
887
|
}
|
|
852
888
|
|
|
@@ -1047,56 +1083,56 @@ message GetWorkerBuildIdOrderingResponse {
|
|
|
1047
1083
|
|
|
1048
1084
|
// (-- api-linter: core::0134=disabled
|
|
1049
1085
|
// aip.dev/not-precedent: Update RPCs don't follow Google API format. --)
|
|
1050
|
-
message
|
|
1051
|
-
// A unique ID for this logical request
|
|
1052
|
-
string request_id = 1;
|
|
1053
|
-
|
|
1054
|
-
// The manner in which the update result will be accessed.
|
|
1055
|
-
// This field requires a non-default value; the default value of the enum
|
|
1056
|
-
// will result in an error.
|
|
1057
|
-
temporal.api.enums.v1.WorkflowUpdateResultAccessStyle result_access_style = 2;
|
|
1058
|
-
|
|
1086
|
+
message UpdateWorkflowExecutionRequest {
|
|
1059
1087
|
// The namespace name of the target workflow
|
|
1060
|
-
string namespace =
|
|
1088
|
+
string namespace = 1;
|
|
1061
1089
|
// The target workflow id and (optionally) a specific run thereof
|
|
1062
1090
|
// (-- api-linter: core::0203::optional=disabled
|
|
1063
1091
|
// aip.dev/not-precedent: false positive triggered by the word "optional" --)
|
|
1064
|
-
temporal.api.common.v1.WorkflowExecution workflow_execution =
|
|
1092
|
+
temporal.api.common.v1.WorkflowExecution workflow_execution = 2;
|
|
1065
1093
|
// If set, this call will error if the most recent (if no run id is set on
|
|
1066
1094
|
// `workflow_execution`), or specified (if it is) workflow execution is not
|
|
1067
1095
|
// part of the same execution chain as this id.
|
|
1068
|
-
string first_execution_run_id =
|
|
1096
|
+
string first_execution_run_id = 3;
|
|
1069
1097
|
|
|
1070
|
-
//
|
|
1071
|
-
//
|
|
1072
|
-
temporal.api.update.v1.
|
|
1098
|
+
// Describes when this request should return - basically whether the
|
|
1099
|
+
// update is synchronous, asynchronous, or somewhere in between.
|
|
1100
|
+
temporal.api.update.v1.WaitPolicy wait_policy = 4;
|
|
1101
|
+
|
|
1102
|
+
// The request information that will be delivered all the way down to the
|
|
1103
|
+
// workflow execution.
|
|
1104
|
+
temporal.api.update.v1.Request request = 5;
|
|
1073
1105
|
}
|
|
1074
1106
|
|
|
1075
|
-
message
|
|
1076
|
-
//
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
// The
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
}
|
|
1107
|
+
message UpdateWorkflowExecutionResponse {
|
|
1108
|
+
// Enough information for subsequent poll calls if needed. Never null.
|
|
1109
|
+
temporal.api.update.v1.UpdateRef update_ref = 1;
|
|
1110
|
+
|
|
1111
|
+
// The outcome of the update if and only if the workflow execution update
|
|
1112
|
+
// has completed. If this response is being returned before the update has
|
|
1113
|
+
// completed then this field will not be set.
|
|
1114
|
+
temporal.api.update.v1.Outcome outcome = 2;
|
|
1084
1115
|
}
|
|
1085
1116
|
|
|
1086
1117
|
message StartBatchOperationRequest {
|
|
1087
1118
|
// Namespace that contains the batch operation
|
|
1088
1119
|
string namespace = 1;
|
|
1089
|
-
// Visibility query defines the the group of workflow to
|
|
1120
|
+
// Visibility query defines the the group of workflow to apply the batch operation
|
|
1121
|
+
// This field and Executions are mutually exclusive
|
|
1090
1122
|
string visibility_query = 2;
|
|
1091
1123
|
// Job ID defines the unique ID for the batch job
|
|
1092
1124
|
string job_id = 3;
|
|
1093
1125
|
// Reason to perform the batch operation
|
|
1094
1126
|
string reason = 4;
|
|
1127
|
+
// Executions to apply the batch operation
|
|
1128
|
+
// This field and VisibilityQuery are mutually exclusive
|
|
1129
|
+
repeated temporal.api.common.v1.WorkflowExecution executions = 5;
|
|
1095
1130
|
// Operation input
|
|
1096
1131
|
oneof operation {
|
|
1097
1132
|
temporal.api.batch.v1.BatchOperationTermination termination_operation = 10;
|
|
1098
1133
|
temporal.api.batch.v1.BatchOperationSignal signal_operation = 11;
|
|
1099
1134
|
temporal.api.batch.v1.BatchOperationCancellation cancellation_operation = 12;
|
|
1135
|
+
temporal.api.batch.v1.BatchOperationDeletion deletion_operation = 13;
|
|
1100
1136
|
}
|
|
1101
1137
|
}
|
|
1102
1138
|
|
|
@@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/workflowservice/v1;workflowservice";
|
|
|
28
28
|
option java_package = "io.temporal.api.workflowservice.v1";
|
|
29
29
|
option java_multiple_files = true;
|
|
30
30
|
option java_outer_classname = "ServiceProto";
|
|
31
|
-
option ruby_package = "
|
|
32
|
-
option csharp_namespace = "
|
|
31
|
+
option ruby_package = "Temporalio::Api::WorkflowService::V1";
|
|
32
|
+
option csharp_namespace = "Temporalio.Api.WorkflowService.V1";
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
import "temporal/api/workflowservice/v1/request_response.proto";
|
|
@@ -393,8 +393,8 @@ service WorkflowService {
|
|
|
393
393
|
|
|
394
394
|
// Invokes the specified update function on user workflow code.
|
|
395
395
|
// (-- api-linter: core::0134=disabled
|
|
396
|
-
// aip.dev/not-precedent:
|
|
397
|
-
rpc
|
|
396
|
+
// aip.dev/not-precedent: UpdateWorkflowExecution doesn't follow Google API format --)
|
|
397
|
+
rpc UpdateWorkflowExecution(UpdateWorkflowExecutionRequest) returns (UpdateWorkflowExecutionResponse) {
|
|
398
398
|
}
|
|
399
399
|
|
|
400
400
|
// StartBatchOperation starts a new batch operation
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
syntax = "proto3";
|
|
2
2
|
|
|
3
3
|
package coresdk.activity_result;
|
|
4
|
+
option ruby_package = "Temporalio::Bridge::Api::ActivityResult";
|
|
4
5
|
|
|
5
6
|
import "google/protobuf/duration.proto";
|
|
6
7
|
import "google/protobuf/timestamp.proto";
|
|
7
8
|
import "temporal/api/common/v1/message.proto";
|
|
8
9
|
import "temporal/api/failure/v1/message.proto";
|
|
9
10
|
|
|
10
|
-
|
|
11
|
-
* Used to report activity completions to core
|
|
12
|
-
*/
|
|
11
|
+
// Used to report activity completions to core
|
|
13
12
|
message ActivityExecutionResult {
|
|
14
13
|
oneof status {
|
|
15
14
|
Success completed = 1;
|
|
@@ -30,17 +29,17 @@ message ActivityResolution {
|
|
|
30
29
|
}
|
|
31
30
|
}
|
|
32
31
|
|
|
33
|
-
|
|
32
|
+
// Used to report successful completion either when executing or resolving
|
|
34
33
|
message Success {
|
|
35
34
|
temporal.api.common.v1.Payload result = 1;
|
|
36
35
|
}
|
|
37
36
|
|
|
38
|
-
|
|
37
|
+
// Used to report activity failure either when executing or resolving
|
|
39
38
|
message Failure {
|
|
40
39
|
temporal.api.failure.v1.Failure failure = 1;
|
|
41
40
|
}
|
|
42
41
|
|
|
43
|
-
|
|
42
|
+
/*
|
|
44
43
|
* Used to report cancellation from both Core and Lang.
|
|
45
44
|
* When Lang reports a cancelled activity, it must put a CancelledFailure in the failure field.
|
|
46
45
|
* When Core reports a cancelled activity, it must put an ActivityFailure with CancelledFailure
|
|
@@ -50,14 +49,14 @@ message Cancellation {
|
|
|
50
49
|
temporal.api.failure.v1.Failure failure = 1;
|
|
51
50
|
}
|
|
52
51
|
|
|
53
|
-
|
|
52
|
+
/*
|
|
54
53
|
* Used in ActivityExecutionResult to notify Core that this Activity will complete asynchronously.
|
|
55
54
|
* Core will forget about this Activity and free up resources used to track this Activity.
|
|
56
55
|
*/
|
|
57
56
|
message WillCompleteAsync {
|
|
58
57
|
}
|
|
59
58
|
|
|
60
|
-
|
|
59
|
+
/*
|
|
61
60
|
* Issued when a local activity needs to retry but also wants to back off more than would be
|
|
62
61
|
* reasonable to WFT heartbeat for. Lang is expected to schedule a timer for the duration
|
|
63
62
|
* and then start a local activity of the same type & same inputs with the provided attempt number
|
|
@@ -4,6 +4,7 @@ syntax = "proto3";
|
|
|
4
4
|
* Definitions of the different activity tasks returned from [crate::Core::poll_task].
|
|
5
5
|
*/
|
|
6
6
|
package coresdk.activity_task;
|
|
7
|
+
option ruby_package = "Temporalio::Bridge::Api::ActivityTask";
|
|
7
8
|
|
|
8
9
|
import "google/protobuf/duration.proto";
|
|
9
10
|
import "google/protobuf/timestamp.proto";
|
|
@@ -11,12 +12,12 @@ import "temporal/api/common/v1/message.proto";
|
|
|
11
12
|
import "temporal/sdk/core/common/common.proto";
|
|
12
13
|
|
|
13
14
|
message ActivityTask {
|
|
14
|
-
|
|
15
|
+
// A unique identifier for this task
|
|
15
16
|
bytes task_token = 1;
|
|
16
17
|
oneof variant {
|
|
17
|
-
|
|
18
|
+
// Start activity execution.
|
|
18
19
|
Start start = 3;
|
|
19
|
-
|
|
20
|
+
// Attempt to cancel activity execution.
|
|
20
21
|
Cancel cancel = 4;
|
|
21
22
|
}
|
|
22
23
|
}
|
|
@@ -62,18 +63,20 @@ message Start {
|
|
|
62
63
|
bool is_local = 17;
|
|
63
64
|
}
|
|
64
65
|
|
|
65
|
-
|
|
66
|
+
// Attempt to cancel a running activity
|
|
66
67
|
message Cancel {
|
|
67
68
|
ActivityCancelReason reason = 1;
|
|
68
69
|
}
|
|
69
70
|
|
|
70
71
|
enum ActivityCancelReason {
|
|
71
|
-
|
|
72
|
+
// The activity no longer exists according to server (may be already completed)
|
|
72
73
|
NOT_FOUND = 0;
|
|
73
|
-
|
|
74
|
+
// Activity was explicitly cancelled
|
|
74
75
|
CANCELLED = 1;
|
|
75
|
-
|
|
76
|
+
// Activity timed out
|
|
76
77
|
TIMED_OUT = 2;
|
|
78
|
+
// Core is shutting down and the graceful timeout has elapsed
|
|
79
|
+
WORKER_SHUTDOWN = 3;
|
|
77
80
|
}
|
|
78
81
|
|
|
79
82
|
|
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
syntax = "proto3";
|
|
2
2
|
|
|
3
3
|
package coresdk.child_workflow;
|
|
4
|
+
option ruby_package = "Temporalio::Bridge::Api::ChildWorkflow";
|
|
4
5
|
|
|
5
6
|
import "temporal/api/common/v1/message.proto";
|
|
6
7
|
import "temporal/api/failure/v1/message.proto";
|
|
7
8
|
import "temporal/sdk/core/common/common.proto";
|
|
8
9
|
|
|
9
|
-
|
|
10
|
-
* Used by core to resolve child workflow executions.
|
|
11
|
-
*/
|
|
10
|
+
// Used by core to resolve child workflow executions.
|
|
12
11
|
message ChildWorkflowResult {
|
|
13
12
|
oneof status {
|
|
14
13
|
Success completed = 1;
|
|
@@ -17,61 +16,51 @@ message ChildWorkflowResult {
|
|
|
17
16
|
}
|
|
18
17
|
}
|
|
19
18
|
|
|
20
|
-
|
|
21
|
-
* Used in ChildWorkflowResult to report successful completion.
|
|
22
|
-
*/
|
|
19
|
+
// Used in ChildWorkflowResult to report successful completion.
|
|
23
20
|
message Success {
|
|
24
21
|
temporal.api.common.v1.Payload result = 1;
|
|
25
22
|
}
|
|
26
23
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
* application failures, timeouts, terminations, and cancellations.
|
|
30
|
-
*/
|
|
24
|
+
// Used in ChildWorkflowResult to report non successful outcomes such as
|
|
25
|
+
// application failures, timeouts, terminations, and cancellations.
|
|
31
26
|
message Failure {
|
|
32
27
|
temporal.api.failure.v1.Failure failure = 1;
|
|
33
28
|
}
|
|
34
29
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
* Failure should be ChildWorkflowFailure with a CanceledFailure cause.
|
|
38
|
-
*/
|
|
30
|
+
// Used in ChildWorkflowResult to report cancellation.
|
|
31
|
+
// Failure should be ChildWorkflowFailure with a CanceledFailure cause.
|
|
39
32
|
message Cancellation {
|
|
40
33
|
temporal.api.failure.v1.Failure failure = 1;
|
|
41
34
|
}
|
|
42
35
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
* in case its parent is closed.
|
|
46
|
-
*/
|
|
36
|
+
// Used by the service to determine the fate of a child workflow
|
|
37
|
+
// in case its parent is closed.
|
|
47
38
|
enum ParentClosePolicy {
|
|
48
|
-
|
|
39
|
+
// Let's the server set the default.
|
|
49
40
|
PARENT_CLOSE_POLICY_UNSPECIFIED = 0;
|
|
50
|
-
|
|
41
|
+
// Terminate means terminating the child workflow.
|
|
51
42
|
PARENT_CLOSE_POLICY_TERMINATE = 1;
|
|
52
|
-
|
|
43
|
+
// Abandon means not doing anything on the child workflow.
|
|
53
44
|
PARENT_CLOSE_POLICY_ABANDON = 2;
|
|
54
|
-
|
|
45
|
+
// Cancel means requesting cancellation on the child workflow.
|
|
55
46
|
PARENT_CLOSE_POLICY_REQUEST_CANCEL = 3;
|
|
56
47
|
}
|
|
57
48
|
|
|
58
|
-
|
|
49
|
+
// Possible causes of failure to start a child workflow
|
|
59
50
|
enum StartChildWorkflowExecutionFailedCause {
|
|
60
51
|
START_CHILD_WORKFLOW_EXECUTION_FAILED_CAUSE_UNSPECIFIED = 0;
|
|
61
52
|
START_CHILD_WORKFLOW_EXECUTION_FAILED_CAUSE_WORKFLOW_ALREADY_EXISTS = 1;
|
|
62
53
|
}
|
|
63
54
|
|
|
64
|
-
|
|
65
|
-
* Controls at which point to report back to lang when a child workflow is cancelled
|
|
66
|
-
*/
|
|
55
|
+
// Controls at which point to report back to lang when a child workflow is cancelled
|
|
67
56
|
enum ChildWorkflowCancellationType {
|
|
68
|
-
|
|
57
|
+
// Do not request cancellation of the child workflow if already scheduled
|
|
69
58
|
ABANDON = 0;
|
|
70
|
-
|
|
59
|
+
// Initiate a cancellation request and immediately report cancellation to the parent.
|
|
71
60
|
TRY_CANCEL = 1;
|
|
72
|
-
|
|
61
|
+
// Wait for child cancellation completion.
|
|
73
62
|
WAIT_CANCELLATION_COMPLETED = 2;
|
|
74
|
-
|
|
63
|
+
// Request cancellation of the child and wait for confirmation that the request was received.
|
|
75
64
|
WAIT_CANCELLATION_REQUESTED = 3;
|
|
76
65
|
}
|
|
77
66
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
syntax = "proto3";
|
|
2
2
|
|
|
3
3
|
package coresdk;
|
|
4
|
+
option ruby_package = "Temporalio::Bridge::Api::CoreInterface";
|
|
4
5
|
|
|
5
6
|
// Note: Intellij will think the Google imports don't work because of the slightly odd nature of
|
|
6
7
|
// the include paths. You can make it work by going to the "Protobuf Support" settings section
|