@temporalio/core-bridge 1.13.0 → 1.13.2
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 +239 -382
- package/Cargo.toml +11 -11
- package/lib/native.d.ts +10 -3
- package/package.json +3 -3
- 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/.cargo/config.toml +71 -11
- package/sdk-core/.clippy.toml +1 -0
- package/sdk-core/.github/workflows/heavy.yml +2 -0
- package/sdk-core/.github/workflows/per-pr.yml +50 -18
- package/sdk-core/ARCHITECTURE.md +44 -48
- package/sdk-core/Cargo.toml +26 -7
- package/sdk-core/README.md +4 -0
- package/sdk-core/arch_docs/diagrams/TimerMachine_Coverage.puml +14 -0
- package/sdk-core/arch_docs/diagrams/initial_event_history.png +0 -0
- package/sdk-core/arch_docs/sdks_intro.md +299 -0
- package/sdk-core/client/Cargo.toml +8 -7
- package/sdk-core/client/src/callback_based.rs +1 -2
- package/sdk-core/client/src/lib.rs +485 -299
- package/sdk-core/client/src/metrics.rs +32 -8
- package/sdk-core/client/src/proxy.rs +124 -5
- package/sdk-core/client/src/raw.rs +598 -307
- package/sdk-core/client/src/replaceable.rs +253 -0
- package/sdk-core/client/src/retry.rs +9 -6
- package/sdk-core/client/src/worker_registry/mod.rs +19 -3
- package/sdk-core/client/src/workflow_handle/mod.rs +20 -17
- package/sdk-core/core/Cargo.toml +100 -31
- package/sdk-core/core/src/core_tests/activity_tasks.rs +55 -225
- package/sdk-core/core/src/core_tests/mod.rs +2 -8
- package/sdk-core/core/src/core_tests/queries.rs +3 -5
- package/sdk-core/core/src/core_tests/replay_flag.rs +3 -62
- package/sdk-core/core/src/core_tests/updates.rs +4 -5
- package/sdk-core/core/src/core_tests/workers.rs +4 -3
- package/sdk-core/core/src/core_tests/workflow_cancels.rs +10 -7
- package/sdk-core/core/src/core_tests/workflow_tasks.rs +28 -291
- package/sdk-core/core/src/ephemeral_server/mod.rs +15 -3
- package/sdk-core/core/src/internal_flags.rs +11 -1
- package/sdk-core/core/src/lib.rs +50 -36
- package/sdk-core/core/src/pollers/mod.rs +5 -5
- package/sdk-core/core/src/pollers/poll_buffer.rs +2 -2
- package/sdk-core/core/src/protosext/mod.rs +13 -5
- package/sdk-core/core/src/protosext/protocol_messages.rs +4 -11
- package/sdk-core/core/src/retry_logic.rs +256 -108
- package/sdk-core/core/src/telemetry/metrics.rs +1 -0
- package/sdk-core/core/src/telemetry/mod.rs +8 -2
- package/sdk-core/core/src/telemetry/prometheus_meter.rs +2 -2
- package/sdk-core/core/src/test_help/integ_helpers.rs +971 -0
- package/sdk-core/core/src/test_help/mod.rs +10 -1100
- package/sdk-core/core/src/test_help/unit_helpers.rs +218 -0
- package/sdk-core/core/src/worker/activities/activity_heartbeat_manager.rs +42 -6
- package/sdk-core/core/src/worker/activities/local_activities.rs +19 -19
- package/sdk-core/core/src/worker/activities.rs +10 -3
- package/sdk-core/core/src/worker/client/mocks.rs +3 -3
- package/sdk-core/core/src/worker/client.rs +130 -93
- package/sdk-core/core/src/worker/heartbeat.rs +12 -13
- package/sdk-core/core/src/worker/mod.rs +31 -21
- package/sdk-core/core/src/worker/nexus.rs +14 -3
- package/sdk-core/core/src/worker/slot_provider.rs +9 -0
- package/sdk-core/core/src/worker/tuner.rs +159 -0
- package/sdk-core/core/src/worker/workflow/history_update.rs +3 -265
- package/sdk-core/core/src/worker/workflow/machines/activity_state_machine.rs +1 -54
- package/sdk-core/core/src/worker/workflow/machines/cancel_external_state_machine.rs +0 -82
- package/sdk-core/core/src/worker/workflow/machines/cancel_workflow_state_machine.rs +0 -67
- package/sdk-core/core/src/worker/workflow/machines/child_workflow_state_machine.rs +1 -192
- package/sdk-core/core/src/worker/workflow/machines/continue_as_new_workflow_state_machine.rs +0 -43
- package/sdk-core/core/src/worker/workflow/machines/local_activity_state_machine.rs +6 -554
- package/sdk-core/core/src/worker/workflow/machines/modify_workflow_properties_state_machine.rs +0 -71
- package/sdk-core/core/src/worker/workflow/machines/nexus_operation_state_machine.rs +102 -3
- package/sdk-core/core/src/worker/workflow/machines/patch_state_machine.rs +10 -539
- package/sdk-core/core/src/worker/workflow/machines/signal_external_state_machine.rs +0 -139
- package/sdk-core/core/src/worker/workflow/machines/timer_state_machine.rs +1 -119
- package/sdk-core/core/src/worker/workflow/machines/upsert_search_attributes_state_machine.rs +6 -63
- package/sdk-core/core/src/worker/workflow/machines/workflow_machines.rs +9 -4
- package/sdk-core/core/src/worker/workflow/mod.rs +5 -1
- package/sdk-core/core/src/worker/workflow/workflow_stream.rs +8 -3
- package/sdk-core/core-api/Cargo.toml +4 -4
- package/sdk-core/core-api/src/envconfig.rs +153 -54
- package/sdk-core/core-api/src/lib.rs +68 -0
- package/sdk-core/core-api/src/telemetry/metrics.rs +2 -1
- package/sdk-core/core-api/src/telemetry.rs +13 -0
- package/sdk-core/core-c-bridge/Cargo.toml +13 -8
- package/sdk-core/core-c-bridge/include/temporal-sdk-core-c-bridge.h +184 -22
- package/sdk-core/core-c-bridge/src/client.rs +462 -184
- package/sdk-core/core-c-bridge/src/envconfig.rs +314 -0
- package/sdk-core/core-c-bridge/src/lib.rs +1 -0
- package/sdk-core/core-c-bridge/src/random.rs +4 -4
- package/sdk-core/core-c-bridge/src/runtime.rs +22 -23
- package/sdk-core/core-c-bridge/src/testing.rs +1 -4
- package/sdk-core/core-c-bridge/src/tests/context.rs +31 -31
- package/sdk-core/core-c-bridge/src/tests/mod.rs +32 -28
- package/sdk-core/core-c-bridge/src/tests/utils.rs +7 -7
- package/sdk-core/core-c-bridge/src/worker.rs +319 -66
- package/sdk-core/fsm/rustfsm_procmacro/src/lib.rs +6 -1
- package/sdk-core/fsm/rustfsm_procmacro/tests/trybuild/dupe_transitions_fail.stderr +5 -5
- package/sdk-core/sdk/Cargo.toml +8 -2
- package/sdk-core/sdk/src/activity_context.rs +1 -1
- package/sdk-core/sdk/src/app_data.rs +1 -1
- package/sdk-core/sdk/src/interceptors.rs +1 -4
- package/sdk-core/sdk/src/lib.rs +1 -5
- package/sdk-core/sdk/src/workflow_context/options.rs +10 -1
- package/sdk-core/sdk/src/workflow_future.rs +1 -1
- package/sdk-core/sdk-core-protos/Cargo.toml +6 -6
- package/sdk-core/sdk-core-protos/build.rs +10 -23
- package/sdk-core/sdk-core-protos/protos/api_upstream/.github/workflows/create-release.yml +9 -1
- package/sdk-core/sdk-core-protos/protos/api_upstream/openapi/openapiv2.json +254 -5
- package/sdk-core/sdk-core-protos/protos/api_upstream/openapi/openapiv3.yaml +234 -5
- package/sdk-core/sdk-core-protos/protos/api_upstream/temporal/api/common/v1/message.proto +1 -1
- package/sdk-core/sdk-core-protos/protos/api_upstream/temporal/api/deployment/v1/message.proto +6 -0
- package/sdk-core/sdk-core-protos/protos/api_upstream/temporal/api/namespace/v1/message.proto +6 -2
- package/sdk-core/sdk-core-protos/protos/api_upstream/temporal/api/workflowservice/v1/request_response.proto +60 -2
- package/sdk-core/sdk-core-protos/protos/api_upstream/temporal/api/workflowservice/v1/service.proto +30 -6
- package/sdk-core/sdk-core-protos/protos/local/temporal/sdk/core/workflow_activation/workflow_activation.proto +2 -0
- package/sdk-core/{test-utils → sdk-core-protos}/src/canned_histories.rs +5 -5
- package/sdk-core/sdk-core-protos/src/history_builder.rs +2 -2
- package/sdk-core/sdk-core-protos/src/lib.rs +25 -9
- package/sdk-core/sdk-core-protos/src/test_utils.rs +89 -0
- package/sdk-core/sdk-core-protos/src/utilities.rs +14 -5
- package/sdk-core/tests/c_bridge_smoke_test.c +10 -0
- package/sdk-core/tests/cloud_tests.rs +10 -8
- package/sdk-core/tests/common/http_proxy.rs +134 -0
- package/sdk-core/{test-utils/src/lib.rs → tests/common/mod.rs} +214 -281
- package/sdk-core/{test-utils/src → tests/common}/workflows.rs +4 -3
- package/sdk-core/tests/fuzzy_workflow.rs +1 -1
- package/sdk-core/tests/global_metric_tests.rs +8 -7
- package/sdk-core/tests/heavy_tests.rs +7 -3
- package/sdk-core/tests/integ_tests/client_tests.rs +111 -24
- package/sdk-core/tests/integ_tests/ephemeral_server_tests.rs +14 -9
- package/sdk-core/tests/integ_tests/heartbeat_tests.rs +4 -4
- package/sdk-core/tests/integ_tests/metrics_tests.rs +114 -14
- package/sdk-core/tests/integ_tests/pagination_tests.rs +273 -0
- package/sdk-core/tests/integ_tests/polling_tests.rs +311 -93
- package/sdk-core/tests/integ_tests/queries_tests.rs +4 -4
- package/sdk-core/tests/integ_tests/update_tests.rs +13 -7
- package/sdk-core/tests/integ_tests/visibility_tests.rs +26 -9
- package/sdk-core/tests/integ_tests/worker_tests.rs +668 -13
- package/sdk-core/tests/integ_tests/worker_versioning_tests.rs +40 -24
- package/sdk-core/tests/integ_tests/workflow_tests/activities.rs +244 -11
- package/sdk-core/tests/integ_tests/workflow_tests/appdata_propagation.rs +1 -1
- package/sdk-core/tests/integ_tests/workflow_tests/cancel_external.rs +78 -2
- package/sdk-core/tests/integ_tests/workflow_tests/cancel_wf.rs +61 -2
- package/sdk-core/tests/integ_tests/workflow_tests/child_workflows.rs +465 -7
- package/sdk-core/tests/integ_tests/workflow_tests/continue_as_new.rs +41 -2
- package/sdk-core/tests/integ_tests/workflow_tests/determinism.rs +315 -3
- package/sdk-core/tests/integ_tests/workflow_tests/eager.rs +1 -1
- package/sdk-core/tests/integ_tests/workflow_tests/local_activities.rs +1990 -14
- package/sdk-core/tests/integ_tests/workflow_tests/modify_wf_properties.rs +65 -2
- package/sdk-core/tests/integ_tests/workflow_tests/nexus.rs +123 -23
- package/sdk-core/tests/integ_tests/workflow_tests/patches.rs +525 -3
- package/sdk-core/tests/integ_tests/workflow_tests/replay.rs +65 -16
- package/sdk-core/tests/integ_tests/workflow_tests/resets.rs +32 -23
- package/sdk-core/tests/integ_tests/workflow_tests/signals.rs +126 -5
- package/sdk-core/tests/integ_tests/workflow_tests/stickyness.rs +1 -2
- package/sdk-core/tests/integ_tests/workflow_tests/timers.rs +124 -8
- package/sdk-core/tests/integ_tests/workflow_tests/upsert_search_attrs.rs +62 -2
- package/sdk-core/tests/integ_tests/workflow_tests.rs +67 -8
- package/sdk-core/tests/main.rs +26 -17
- package/sdk-core/tests/manual_tests.rs +5 -1
- package/sdk-core/tests/runner.rs +22 -40
- package/sdk-core/tests/shared_tests/mod.rs +1 -1
- package/sdk-core/tests/shared_tests/priority.rs +1 -1
- package/sdk-core/{core/benches/workflow_replay.rs → tests/workflow_replay_bench.rs} +10 -5
- package/src/client.rs +97 -20
- package/src/helpers/callbacks.rs +4 -4
- package/src/helpers/errors.rs +7 -1
- package/src/helpers/handles.rs +1 -0
- package/src/helpers/try_from_js.rs +4 -3
- package/src/lib.rs +3 -2
- package/src/metrics.rs +3 -0
- package/src/runtime.rs +5 -2
- package/src/worker.rs +9 -12
- package/ts/native.ts +13 -3
- package/sdk-core/arch_docs/diagrams/workflow_internals.svg +0 -1
- package/sdk-core/core/src/core_tests/child_workflows.rs +0 -281
- package/sdk-core/core/src/core_tests/determinism.rs +0 -318
- package/sdk-core/core/src/core_tests/local_activities.rs +0 -1442
- package/sdk-core/test-utils/Cargo.toml +0 -38
- package/sdk-core/test-utils/src/histfetch.rs +0 -28
- package/sdk-core/test-utils/src/interceptors.rs +0 -46
|
@@ -88,10 +88,7 @@ impl WorkerInterceptor for FailOnNondeterminismInterceptor {
|
|
|
88
88
|
activation.eviction_reason(),
|
|
89
89
|
Some(EvictionReason::Nondeterminism)
|
|
90
90
|
) {
|
|
91
|
-
bail!(
|
|
92
|
-
"Workflow is being evicted because of nondeterminism! {}",
|
|
93
|
-
activation
|
|
94
|
-
);
|
|
91
|
+
bail!("Workflow is being evicted because of nondeterminism! {activation}");
|
|
95
92
|
}
|
|
96
93
|
Ok(())
|
|
97
94
|
}
|
package/sdk-core/sdk/src/lib.rs
CHANGED
|
@@ -497,11 +497,7 @@ impl WorkflowHalf {
|
|
|
497
497
|
|
|
498
498
|
// In all other cases, we want to error as the runtime could be in an inconsistent state
|
|
499
499
|
// at this point.
|
|
500
|
-
bail!(
|
|
501
|
-
"Got activation {:?} for unknown workflow {}",
|
|
502
|
-
activation,
|
|
503
|
-
run_id
|
|
504
|
-
);
|
|
500
|
+
bail!("Got activation {activation:?} for unknown workflow {run_id}");
|
|
505
501
|
};
|
|
506
502
|
|
|
507
503
|
Ok(res)
|
|
@@ -3,6 +3,7 @@ use std::{collections::HashMap, time::Duration};
|
|
|
3
3
|
use temporal_client::{Priority, WorkflowOptions};
|
|
4
4
|
use temporal_sdk_core_protos::{
|
|
5
5
|
coresdk::{
|
|
6
|
+
AsJsonPayloadExt,
|
|
6
7
|
child_workflow::ChildWorkflowCancellationType,
|
|
7
8
|
nexus::NexusOperationCancellationType,
|
|
8
9
|
workflow_commands::{
|
|
@@ -155,6 +156,8 @@ pub struct LocalActivityOptions {
|
|
|
155
156
|
/// specified. If set, this must be <= `schedule_to_close_timeout`, if not, it will be clamped
|
|
156
157
|
/// down.
|
|
157
158
|
pub start_to_close_timeout: Option<Duration>,
|
|
159
|
+
/// Single-line summary for this activity that will appear in UI/CLI.
|
|
160
|
+
pub summary: Option<String>,
|
|
158
161
|
}
|
|
159
162
|
|
|
160
163
|
impl IntoWorkflowCommand for LocalActivityOptions {
|
|
@@ -194,7 +197,13 @@ impl IntoWorkflowCommand for LocalActivityOptions {
|
|
|
194
197
|
}
|
|
195
198
|
.into(),
|
|
196
199
|
),
|
|
197
|
-
user_metadata:
|
|
200
|
+
user_metadata: self
|
|
201
|
+
.summary
|
|
202
|
+
.and_then(|summary| summary.as_json_payload().ok())
|
|
203
|
+
.map(|summary| UserMetadata {
|
|
204
|
+
summary: Some(summary),
|
|
205
|
+
details: None,
|
|
206
|
+
}),
|
|
198
207
|
}
|
|
199
208
|
}
|
|
200
209
|
}
|
|
@@ -135,7 +135,7 @@ impl WorkflowFuture {
|
|
|
135
135
|
};
|
|
136
136
|
let unblocker = self.command_status.remove(&cmd_id);
|
|
137
137
|
let _ = unblocker
|
|
138
|
-
.ok_or_else(|| anyhow!("Command {:?} not found to unblock!"
|
|
138
|
+
.ok_or_else(|| anyhow!("Command {cmd_id:?} not found to unblock!"))?
|
|
139
139
|
.unblocker
|
|
140
140
|
.send(event);
|
|
141
141
|
Ok(())
|
|
@@ -13,25 +13,25 @@ categories = ["development-tools"]
|
|
|
13
13
|
[features]
|
|
14
14
|
history_builders = ["uuid", "rand"]
|
|
15
15
|
serde_serialize = []
|
|
16
|
+
test-utilities = ["history_builders"]
|
|
16
17
|
|
|
17
18
|
[dependencies]
|
|
18
19
|
anyhow = "1.0"
|
|
19
20
|
base64 = "0.22"
|
|
20
21
|
derive_more = { workspace = true }
|
|
21
22
|
prost = { workspace = true }
|
|
22
|
-
prost-wkt = "0.
|
|
23
|
-
prost-
|
|
23
|
+
prost-wkt = "0.7"
|
|
24
|
+
prost-types = { workspace = true }
|
|
24
25
|
rand = { version = "0.9", optional = true }
|
|
25
26
|
serde = { version = "1.0", features = ["derive"] }
|
|
26
27
|
serde_json = "1.0"
|
|
27
28
|
thiserror = { workspace = true }
|
|
28
29
|
tonic = { workspace = true }
|
|
29
|
-
|
|
30
|
+
tonic-prost = { workspace = true }
|
|
31
|
+
uuid = { version = "1.18", features = ["v4"], optional = true }
|
|
30
32
|
|
|
31
33
|
[build-dependencies]
|
|
32
|
-
tonic-build = { workspace = true }
|
|
33
|
-
prost-build = "0.13"
|
|
34
|
-
prost-wkt-build = "0.6"
|
|
34
|
+
tonic-prost-build = { workspace = true }
|
|
35
35
|
|
|
36
36
|
[lints]
|
|
37
37
|
workspace = true
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
use std::{env, path::PathBuf};
|
|
2
2
|
|
|
3
|
+
use tonic_prost_build::Config;
|
|
4
|
+
|
|
3
5
|
static ALWAYS_SERDE: &str = "#[cfg_attr(not(feature = \"serde_serialize\"), \
|
|
4
6
|
derive(::serde::Serialize, ::serde::Deserialize))]";
|
|
5
7
|
|
|
@@ -7,7 +9,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|
|
7
9
|
println!("cargo:rerun-if-changed=./protos");
|
|
8
10
|
let out = PathBuf::from(env::var("OUT_DIR").unwrap());
|
|
9
11
|
let descriptor_file = out.join("descriptors.bin");
|
|
10
|
-
|
|
12
|
+
tonic_prost_build::configure()
|
|
11
13
|
// We don't actually want to build the grpc definitions - we don't need them (for now).
|
|
12
14
|
// Just build the message structs.
|
|
13
15
|
.build_server(false)
|
|
@@ -96,29 +98,14 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|
|
96
98
|
"coresdk.external_data.LocalActivityMarkerData.backoff",
|
|
97
99
|
"#[serde(with = \"opt_duration\")]",
|
|
98
100
|
)
|
|
99
|
-
.extern_path(
|
|
100
|
-
".google.protobuf.Any",
|
|
101
|
-
"::prost_wkt_types::Any"
|
|
102
|
-
)
|
|
103
|
-
.extern_path(
|
|
104
|
-
".google.protobuf.Timestamp",
|
|
105
|
-
"::prost_wkt_types::Timestamp"
|
|
106
|
-
)
|
|
107
|
-
.extern_path(
|
|
108
|
-
".google.protobuf.Duration",
|
|
109
|
-
"::prost_wkt_types::Duration"
|
|
110
|
-
)
|
|
111
|
-
.extern_path(
|
|
112
|
-
".google.protobuf.Value",
|
|
113
|
-
"::prost_wkt_types::Value"
|
|
114
|
-
)
|
|
115
|
-
.extern_path(
|
|
116
|
-
".google.protobuf.FieldMask",
|
|
117
|
-
"::prost_wkt_types::FieldMask"
|
|
118
|
-
)
|
|
119
101
|
.file_descriptor_set_path(descriptor_file)
|
|
120
|
-
.skip_debug("temporal.api.common.v1.Payload")
|
|
121
|
-
.
|
|
102
|
+
.skip_debug(["temporal.api.common.v1.Payload"])
|
|
103
|
+
.compile_with_config(
|
|
104
|
+
{
|
|
105
|
+
let mut c = Config::new();
|
|
106
|
+
c.enable_type_names();
|
|
107
|
+
c
|
|
108
|
+
},
|
|
122
109
|
&[
|
|
123
110
|
"./protos/local/temporal/sdk/core/core_interface.proto",
|
|
124
111
|
"./protos/api_upstream/temporal/api/workflowservice/v1/service.proto",
|
|
@@ -16,8 +16,16 @@ on:
|
|
|
16
16
|
skip_sdk_check:
|
|
17
17
|
description: "Skip sdk-go compatibility check"
|
|
18
18
|
type: boolean
|
|
19
|
-
|
|
19
|
+
dispatch_id:
|
|
20
|
+
description: An ID used by external tools to identify workflow runs(can be left empty when running manually)
|
|
21
|
+
default: "none"
|
|
22
|
+
type: string
|
|
20
23
|
jobs:
|
|
24
|
+
dispatch:
|
|
25
|
+
runs-on: ubuntu-latest
|
|
26
|
+
steps:
|
|
27
|
+
- name: Dispatch ${{ inputs.dispatch_id }}
|
|
28
|
+
run: echo "Dispatch ${{ inputs.dispatch_id }}"
|
|
21
29
|
prepare-inputs:
|
|
22
30
|
name: "Prepare inputs"
|
|
23
31
|
runs-on: ubuntu-latest
|
|
@@ -2130,6 +2130,51 @@
|
|
|
2130
2130
|
]
|
|
2131
2131
|
}
|
|
2132
2132
|
},
|
|
2133
|
+
"/api/v1/namespaces/{namespace}/worker-deployments/{deploymentName}/set-manager": {
|
|
2134
|
+
"post": {
|
|
2135
|
+
"summary": "Set/unset the ManagerIdentity of a Worker Deployment.\nExperimental. This API might significantly change or be removed in a future release.",
|
|
2136
|
+
"operationId": "SetWorkerDeploymentManager2",
|
|
2137
|
+
"responses": {
|
|
2138
|
+
"200": {
|
|
2139
|
+
"description": "A successful response.",
|
|
2140
|
+
"schema": {
|
|
2141
|
+
"$ref": "#/definitions/v1SetWorkerDeploymentManagerResponse"
|
|
2142
|
+
}
|
|
2143
|
+
},
|
|
2144
|
+
"default": {
|
|
2145
|
+
"description": "An unexpected error response.",
|
|
2146
|
+
"schema": {
|
|
2147
|
+
"$ref": "#/definitions/rpcStatus"
|
|
2148
|
+
}
|
|
2149
|
+
}
|
|
2150
|
+
},
|
|
2151
|
+
"parameters": [
|
|
2152
|
+
{
|
|
2153
|
+
"name": "namespace",
|
|
2154
|
+
"in": "path",
|
|
2155
|
+
"required": true,
|
|
2156
|
+
"type": "string"
|
|
2157
|
+
},
|
|
2158
|
+
{
|
|
2159
|
+
"name": "deploymentName",
|
|
2160
|
+
"in": "path",
|
|
2161
|
+
"required": true,
|
|
2162
|
+
"type": "string"
|
|
2163
|
+
},
|
|
2164
|
+
{
|
|
2165
|
+
"name": "body",
|
|
2166
|
+
"in": "body",
|
|
2167
|
+
"required": true,
|
|
2168
|
+
"schema": {
|
|
2169
|
+
"$ref": "#/definitions/WorkflowServiceSetWorkerDeploymentManagerBody"
|
|
2170
|
+
}
|
|
2171
|
+
}
|
|
2172
|
+
],
|
|
2173
|
+
"tags": [
|
|
2174
|
+
"WorkflowService"
|
|
2175
|
+
]
|
|
2176
|
+
}
|
|
2177
|
+
},
|
|
2133
2178
|
"/api/v1/namespaces/{namespace}/worker-deployments/{deploymentName}/set-ramping-version": {
|
|
2134
2179
|
"post": {
|
|
2135
2180
|
"summary": "Set/unset the Ramping Version of a Worker Deployment and its ramp percentage. Can be used for\ngradual ramp to unversioned workers too.\nExperimental. This API might significantly change or be removed in a future release.",
|
|
@@ -2296,6 +2341,45 @@
|
|
|
2296
2341
|
]
|
|
2297
2342
|
}
|
|
2298
2343
|
},
|
|
2344
|
+
"/api/v1/namespaces/{namespace}/workers/describe/{workerInstanceKey}": {
|
|
2345
|
+
"get": {
|
|
2346
|
+
"summary": "DescribeWorker returns information about the specified worker.",
|
|
2347
|
+
"operationId": "DescribeWorker2",
|
|
2348
|
+
"responses": {
|
|
2349
|
+
"200": {
|
|
2350
|
+
"description": "A successful response.",
|
|
2351
|
+
"schema": {
|
|
2352
|
+
"$ref": "#/definitions/v1DescribeWorkerResponse"
|
|
2353
|
+
}
|
|
2354
|
+
},
|
|
2355
|
+
"default": {
|
|
2356
|
+
"description": "An unexpected error response.",
|
|
2357
|
+
"schema": {
|
|
2358
|
+
"$ref": "#/definitions/rpcStatus"
|
|
2359
|
+
}
|
|
2360
|
+
}
|
|
2361
|
+
},
|
|
2362
|
+
"parameters": [
|
|
2363
|
+
{
|
|
2364
|
+
"name": "namespace",
|
|
2365
|
+
"description": "Namespace this worker belongs to.",
|
|
2366
|
+
"in": "path",
|
|
2367
|
+
"required": true,
|
|
2368
|
+
"type": "string"
|
|
2369
|
+
},
|
|
2370
|
+
{
|
|
2371
|
+
"name": "workerInstanceKey",
|
|
2372
|
+
"description": "Worker instance key to describe.",
|
|
2373
|
+
"in": "path",
|
|
2374
|
+
"required": true,
|
|
2375
|
+
"type": "string"
|
|
2376
|
+
}
|
|
2377
|
+
],
|
|
2378
|
+
"tags": [
|
|
2379
|
+
"WorkflowService"
|
|
2380
|
+
]
|
|
2381
|
+
}
|
|
2382
|
+
},
|
|
2299
2383
|
"/api/v1/namespaces/{namespace}/workers/fetch-config": {
|
|
2300
2384
|
"post": {
|
|
2301
2385
|
"summary": "FetchWorkerConfig returns the worker configuration for a specific worker.",
|
|
@@ -2822,7 +2906,7 @@
|
|
|
2822
2906
|
},
|
|
2823
2907
|
"/api/v1/namespaces/{namespace}/workflows/{execution.workflowId}/history-reverse": {
|
|
2824
2908
|
"get": {
|
|
2825
|
-
"summary": "GetWorkflowExecutionHistoryReverse returns the history of specified workflow execution in reverse
|
|
2909
|
+
"summary": "GetWorkflowExecutionHistoryReverse returns the history of specified workflow execution in reverse\norder (starting from last event). Fails with`NotFound` if the specified workflow execution is\nunknown to the service.",
|
|
2826
2910
|
"operationId": "GetWorkflowExecutionHistoryReverse2",
|
|
2827
2911
|
"responses": {
|
|
2828
2912
|
"200": {
|
|
@@ -5871,6 +5955,51 @@
|
|
|
5871
5955
|
]
|
|
5872
5956
|
}
|
|
5873
5957
|
},
|
|
5958
|
+
"/namespaces/{namespace}/worker-deployments/{deploymentName}/set-manager": {
|
|
5959
|
+
"post": {
|
|
5960
|
+
"summary": "Set/unset the ManagerIdentity of a Worker Deployment.\nExperimental. This API might significantly change or be removed in a future release.",
|
|
5961
|
+
"operationId": "SetWorkerDeploymentManager",
|
|
5962
|
+
"responses": {
|
|
5963
|
+
"200": {
|
|
5964
|
+
"description": "A successful response.",
|
|
5965
|
+
"schema": {
|
|
5966
|
+
"$ref": "#/definitions/v1SetWorkerDeploymentManagerResponse"
|
|
5967
|
+
}
|
|
5968
|
+
},
|
|
5969
|
+
"default": {
|
|
5970
|
+
"description": "An unexpected error response.",
|
|
5971
|
+
"schema": {
|
|
5972
|
+
"$ref": "#/definitions/rpcStatus"
|
|
5973
|
+
}
|
|
5974
|
+
}
|
|
5975
|
+
},
|
|
5976
|
+
"parameters": [
|
|
5977
|
+
{
|
|
5978
|
+
"name": "namespace",
|
|
5979
|
+
"in": "path",
|
|
5980
|
+
"required": true,
|
|
5981
|
+
"type": "string"
|
|
5982
|
+
},
|
|
5983
|
+
{
|
|
5984
|
+
"name": "deploymentName",
|
|
5985
|
+
"in": "path",
|
|
5986
|
+
"required": true,
|
|
5987
|
+
"type": "string"
|
|
5988
|
+
},
|
|
5989
|
+
{
|
|
5990
|
+
"name": "body",
|
|
5991
|
+
"in": "body",
|
|
5992
|
+
"required": true,
|
|
5993
|
+
"schema": {
|
|
5994
|
+
"$ref": "#/definitions/WorkflowServiceSetWorkerDeploymentManagerBody"
|
|
5995
|
+
}
|
|
5996
|
+
}
|
|
5997
|
+
],
|
|
5998
|
+
"tags": [
|
|
5999
|
+
"WorkflowService"
|
|
6000
|
+
]
|
|
6001
|
+
}
|
|
6002
|
+
},
|
|
5874
6003
|
"/namespaces/{namespace}/worker-deployments/{deploymentName}/set-ramping-version": {
|
|
5875
6004
|
"post": {
|
|
5876
6005
|
"summary": "Set/unset the Ramping Version of a Worker Deployment and its ramp percentage. Can be used for\ngradual ramp to unversioned workers too.\nExperimental. This API might significantly change or be removed in a future release.",
|
|
@@ -6037,6 +6166,45 @@
|
|
|
6037
6166
|
]
|
|
6038
6167
|
}
|
|
6039
6168
|
},
|
|
6169
|
+
"/namespaces/{namespace}/workers/describe/{workerInstanceKey}": {
|
|
6170
|
+
"get": {
|
|
6171
|
+
"summary": "DescribeWorker returns information about the specified worker.",
|
|
6172
|
+
"operationId": "DescribeWorker",
|
|
6173
|
+
"responses": {
|
|
6174
|
+
"200": {
|
|
6175
|
+
"description": "A successful response.",
|
|
6176
|
+
"schema": {
|
|
6177
|
+
"$ref": "#/definitions/v1DescribeWorkerResponse"
|
|
6178
|
+
}
|
|
6179
|
+
},
|
|
6180
|
+
"default": {
|
|
6181
|
+
"description": "An unexpected error response.",
|
|
6182
|
+
"schema": {
|
|
6183
|
+
"$ref": "#/definitions/rpcStatus"
|
|
6184
|
+
}
|
|
6185
|
+
}
|
|
6186
|
+
},
|
|
6187
|
+
"parameters": [
|
|
6188
|
+
{
|
|
6189
|
+
"name": "namespace",
|
|
6190
|
+
"description": "Namespace this worker belongs to.",
|
|
6191
|
+
"in": "path",
|
|
6192
|
+
"required": true,
|
|
6193
|
+
"type": "string"
|
|
6194
|
+
},
|
|
6195
|
+
{
|
|
6196
|
+
"name": "workerInstanceKey",
|
|
6197
|
+
"description": "Worker instance key to describe.",
|
|
6198
|
+
"in": "path",
|
|
6199
|
+
"required": true,
|
|
6200
|
+
"type": "string"
|
|
6201
|
+
}
|
|
6202
|
+
],
|
|
6203
|
+
"tags": [
|
|
6204
|
+
"WorkflowService"
|
|
6205
|
+
]
|
|
6206
|
+
}
|
|
6207
|
+
},
|
|
6040
6208
|
"/namespaces/{namespace}/workers/fetch-config": {
|
|
6041
6209
|
"post": {
|
|
6042
6210
|
"summary": "FetchWorkerConfig returns the worker configuration for a specific worker.",
|
|
@@ -6563,7 +6731,7 @@
|
|
|
6563
6731
|
},
|
|
6564
6732
|
"/namespaces/{namespace}/workflows/{execution.workflowId}/history-reverse": {
|
|
6565
6733
|
"get": {
|
|
6566
|
-
"summary": "GetWorkflowExecutionHistoryReverse returns the history of specified workflow execution in reverse
|
|
6734
|
+
"summary": "GetWorkflowExecutionHistoryReverse returns the history of specified workflow execution in reverse\norder (starting from last event). Fails with`NotFound` if the specified workflow execution is\nunknown to the service.",
|
|
6567
6735
|
"operationId": "GetWorkflowExecutionHistoryReverse",
|
|
6568
6736
|
"responses": {
|
|
6569
6737
|
"200": {
|
|
@@ -7861,7 +8029,7 @@
|
|
|
7861
8029
|
},
|
|
7862
8030
|
"type": {
|
|
7863
8031
|
"type": "string",
|
|
7864
|
-
"description": "Pause all running activities of this type."
|
|
8032
|
+
"description": "Pause all running activities of this type.\nNote: Experimental - the behavior of pause by activity type might change in a future release."
|
|
7865
8033
|
},
|
|
7866
8034
|
"reason": {
|
|
7867
8035
|
"type": "string",
|
|
@@ -8314,10 +8482,37 @@
|
|
|
8314
8482
|
"ignoreMissingTaskQueues": {
|
|
8315
8483
|
"type": "boolean",
|
|
8316
8484
|
"description": "Optional. By default this request would be rejected if not all the expected Task Queues are\nbeing polled by the new Version, to protect against accidental removal of Task Queues, or\nworker health issues. Pass `true` here to bypass this protection.\nThe set of expected Task Queues is the set of all the Task Queues that were ever poller by\nthe existing Current Version of the Deployment, with the following exclusions:\n - Task Queues that are not used anymore (inferred by having empty backlog and a task\n add_rate of 0.)\n - Task Queues that are moved to another Worker Deployment (inferred by the Task Queue\n having a different Current Version than the Current Version of this deployment.)\nWARNING: Do not set this flag unless you are sure that the missing task queue pollers are not\nneeded. If the request is unexpectedly rejected due to missing pollers, then that means the\npollers have not reached to the server yet. Only set this if you expect those pollers to\nnever arrive."
|
|
8485
|
+
},
|
|
8486
|
+
"allowNoPollers": {
|
|
8487
|
+
"type": "boolean",
|
|
8488
|
+
"description": "Optional. By default this request will be rejected if no pollers have been seen for the proposed\nCurrent Version, in order to protect users from routing tasks to pollers that do not exist, leading\nto possible timeouts. Pass `true` here to bypass this protection."
|
|
8317
8489
|
}
|
|
8318
8490
|
},
|
|
8319
8491
|
"description": "Set/unset the Current Version of a Worker Deployment."
|
|
8320
8492
|
},
|
|
8493
|
+
"WorkflowServiceSetWorkerDeploymentManagerBody": {
|
|
8494
|
+
"type": "object",
|
|
8495
|
+
"properties": {
|
|
8496
|
+
"managerIdentity": {
|
|
8497
|
+
"type": "string",
|
|
8498
|
+
"description": "Arbitrary value for `manager_identity`.\nEmpty will unset the field."
|
|
8499
|
+
},
|
|
8500
|
+
"self": {
|
|
8501
|
+
"type": "boolean",
|
|
8502
|
+
"description": "True will set `manager_identity` to `identity`."
|
|
8503
|
+
},
|
|
8504
|
+
"conflictToken": {
|
|
8505
|
+
"type": "string",
|
|
8506
|
+
"format": "byte",
|
|
8507
|
+
"description": "Optional. This can be the value of conflict_token from a Describe, or another Worker\nDeployment API. Passing a non-nil conflict token will cause this request to fail if the\nDeployment's configuration has been modified between the API call that generated the\ntoken and this one."
|
|
8508
|
+
},
|
|
8509
|
+
"identity": {
|
|
8510
|
+
"type": "string",
|
|
8511
|
+
"description": "Required. The identity of the client who initiated this request."
|
|
8512
|
+
}
|
|
8513
|
+
},
|
|
8514
|
+
"description": "Update the ManagerIdentity of a Worker Deployment."
|
|
8515
|
+
},
|
|
8321
8516
|
"WorkflowServiceSetWorkerDeploymentRampingVersionBody": {
|
|
8322
8517
|
"type": "object",
|
|
8323
8518
|
"properties": {
|
|
@@ -8346,6 +8541,10 @@
|
|
|
8346
8541
|
"ignoreMissingTaskQueues": {
|
|
8347
8542
|
"type": "boolean",
|
|
8348
8543
|
"description": "Optional. By default this request would be rejected if not all the expected Task Queues are\nbeing polled by the new Version, to protect against accidental removal of Task Queues, or\nworker health issues. Pass `true` here to bypass this protection.\nThe set of expected Task Queues equals to all the Task Queues ever polled from the existing\nCurrent Version of the Deployment, with the following exclusions:\n - Task Queues that are not used anymore (inferred by having empty backlog and a task\n add_rate of 0.)\n - Task Queues that are moved to another Worker Deployment (inferred by the Task Queue\n having a different Current Version than the Current Version of this deployment.)\nWARNING: Do not set this flag unless you are sure that the missing task queue poller are not\nneeded. If the request is unexpectedly rejected due to missing pollers, then that means the\npollers have not reached to the server yet. Only set this if you expect those pollers to\nnever arrive.\nNote: this check only happens when the ramping version is about to change, not every time\nthat the percentage changes. Also note that the check is against the deployment's Current\nVersion, not the previous Ramping Version."
|
|
8544
|
+
},
|
|
8545
|
+
"allowNoPollers": {
|
|
8546
|
+
"type": "boolean",
|
|
8547
|
+
"description": "Optional. By default this request will be rejected if no pollers have been seen for the proposed\nCurrent Version, in order to protect users from routing tasks to pollers that do not exist, leading\nto possible timeouts. Pass `true` here to bypass this protection."
|
|
8349
8548
|
}
|
|
8350
8549
|
},
|
|
8351
8550
|
"description": "Set/unset the Ramping Version of a Worker Deployment and its ramp percentage."
|
|
@@ -8643,6 +8842,10 @@
|
|
|
8643
8842
|
"priority": {
|
|
8644
8843
|
"$ref": "#/definitions/v1Priority",
|
|
8645
8844
|
"title": "Priority metadata"
|
|
8845
|
+
},
|
|
8846
|
+
"eagerWorkerDeploymentOptions": {
|
|
8847
|
+
"$ref": "#/definitions/v1WorkerDeploymentOptions",
|
|
8848
|
+
"description": "Deployment Options of the worker who will process the eager task. Passed when `request_eager_execution=true`."
|
|
8646
8849
|
}
|
|
8647
8850
|
}
|
|
8648
8851
|
},
|
|
@@ -10875,6 +11078,14 @@
|
|
|
10875
11078
|
}
|
|
10876
11079
|
}
|
|
10877
11080
|
},
|
|
11081
|
+
"v1DescribeWorkerResponse": {
|
|
11082
|
+
"type": "object",
|
|
11083
|
+
"properties": {
|
|
11084
|
+
"workerInfo": {
|
|
11085
|
+
"$ref": "#/definitions/v1WorkerInfo"
|
|
11086
|
+
}
|
|
11087
|
+
}
|
|
11088
|
+
},
|
|
10878
11089
|
"v1DescribeWorkflowExecutionResponse": {
|
|
10879
11090
|
"type": "object",
|
|
10880
11091
|
"properties": {
|
|
@@ -11198,6 +11409,14 @@
|
|
|
11198
11409
|
},
|
|
11199
11410
|
"visibilityStore": {
|
|
11200
11411
|
"type": "string"
|
|
11412
|
+
},
|
|
11413
|
+
"initialFailoverVersion": {
|
|
11414
|
+
"type": "string",
|
|
11415
|
+
"format": "int64"
|
|
11416
|
+
},
|
|
11417
|
+
"failoverVersionIncrement": {
|
|
11418
|
+
"type": "string",
|
|
11419
|
+
"format": "int64"
|
|
11201
11420
|
}
|
|
11202
11421
|
},
|
|
11203
11422
|
"description": "GetClusterInfoResponse contains information about Temporal cluster."
|
|
@@ -12167,6 +12386,14 @@
|
|
|
12167
12386
|
"asyncUpdate": {
|
|
12168
12387
|
"type": "boolean",
|
|
12169
12388
|
"title": "True if the namespace supports async update"
|
|
12389
|
+
},
|
|
12390
|
+
"workerHeartbeats": {
|
|
12391
|
+
"type": "boolean",
|
|
12392
|
+
"title": "True if the namespace supports worker heartbeats"
|
|
12393
|
+
},
|
|
12394
|
+
"reportedProblemsSearchAttribute": {
|
|
12395
|
+
"type": "boolean",
|
|
12396
|
+
"title": "True if the namespace supports reported problems search attribute"
|
|
12170
12397
|
}
|
|
12171
12398
|
},
|
|
12172
12399
|
"description": "Namespace capability details. Should contain what features are enabled in a namespace."
|
|
@@ -13154,7 +13381,7 @@
|
|
|
13154
13381
|
"priorityKey": {
|
|
13155
13382
|
"type": "integer",
|
|
13156
13383
|
"format": "int32",
|
|
13157
|
-
"description": "Priority key is a positive integer from 1 to n, where smaller integers\ncorrespond to higher priorities (tasks run sooner). In general, tasks in\na queue should be processed in close to priority order, although small\ndeviations are possible.\n\nThe maximum priority value (minimum priority) is determined by server\nconfiguration, and defaults to 5.\n\nIf priority is not present (or zero), then the effective priority will be\nthe default priority, which is
|
|
13384
|
+
"description": "Priority key is a positive integer from 1 to n, where smaller integers\ncorrespond to higher priorities (tasks run sooner). In general, tasks in\na queue should be processed in close to priority order, although small\ndeviations are possible.\n\nThe maximum priority value (minimum priority) is determined by server\nconfiguration, and defaults to 5.\n\nIf priority is not present (or zero), then the effective priority will be\nthe default priority, which is calculated by (min+max)/2. With the\ndefault max of 5, and min of 1, that comes out to 3."
|
|
13158
13385
|
},
|
|
13159
13386
|
"fairnessKey": {
|
|
13160
13387
|
"type": "string",
|
|
@@ -14343,6 +14570,20 @@
|
|
|
14343
14570
|
}
|
|
14344
14571
|
}
|
|
14345
14572
|
},
|
|
14573
|
+
"v1SetWorkerDeploymentManagerResponse": {
|
|
14574
|
+
"type": "object",
|
|
14575
|
+
"properties": {
|
|
14576
|
+
"conflictToken": {
|
|
14577
|
+
"type": "string",
|
|
14578
|
+
"format": "byte",
|
|
14579
|
+
"description": "This value is returned so that it can be optionally passed to APIs\nthat write to the Worker Deployment state to ensure that the state\ndid not change between this API call and a future write."
|
|
14580
|
+
},
|
|
14581
|
+
"previousManagerIdentity": {
|
|
14582
|
+
"type": "string",
|
|
14583
|
+
"description": "What the `manager_identity` field was before this change."
|
|
14584
|
+
}
|
|
14585
|
+
}
|
|
14586
|
+
},
|
|
14346
14587
|
"v1SetWorkerDeploymentRampingVersionResponse": {
|
|
14347
14588
|
"type": "object",
|
|
14348
14589
|
"properties": {
|
|
@@ -14891,6 +15132,10 @@
|
|
|
14891
15132
|
"priority": {
|
|
14892
15133
|
"$ref": "#/definitions/v1Priority",
|
|
14893
15134
|
"title": "Priority metadata"
|
|
15135
|
+
},
|
|
15136
|
+
"eagerWorkerDeploymentOptions": {
|
|
15137
|
+
"$ref": "#/definitions/v1WorkerDeploymentOptions",
|
|
15138
|
+
"description": "Deployment Options of the worker who will process the eager task. Passed when `request_eager_execution=true`."
|
|
14894
15139
|
}
|
|
14895
15140
|
}
|
|
14896
15141
|
},
|
|
@@ -15453,7 +15698,7 @@
|
|
|
15453
15698
|
"additionalProperties": {
|
|
15454
15699
|
"type": "string"
|
|
15455
15700
|
},
|
|
15456
|
-
"description": "A key-value map for any customized purpose.\nIf data already exists on the namespace
|
|
15701
|
+
"description": "A key-value map for any customized purpose.\nIf data already exists on the namespace,\nthis will merge with the existing key values."
|
|
15457
15702
|
},
|
|
15458
15703
|
"state": {
|
|
15459
15704
|
"$ref": "#/definitions/v1NamespaceState",
|
|
@@ -15812,6 +16057,10 @@
|
|
|
15812
16057
|
"lastModifierIdentity": {
|
|
15813
16058
|
"type": "string",
|
|
15814
16059
|
"description": "Identity of the last client who modified the configuration of this Deployment. Set to the\n`identity` value sent by APIs such as `SetWorkerDeploymentCurrentVersion` and\n`SetWorkerDeploymentRampingVersion`."
|
|
16060
|
+
},
|
|
16061
|
+
"managerIdentity": {
|
|
16062
|
+
"type": "string",
|
|
16063
|
+
"description": "Identity of the client that has the exclusive right to make changes to this Worker Deployment.\nEmpty by default.\nIf this is set, clients whose identity does not match `manager_identity` will not be able to make changes\nto this Worker Deployment. They can either set their own identity as the manager or unset the field to proceed."
|
|
15815
16064
|
}
|
|
15816
16065
|
},
|
|
15817
16066
|
"description": "A Worker Deployment (Deployment, for short) represents all workers serving \na shared set of Task Queues. Typically, a Deployment represents one service or \napplication.\nA Deployment contains multiple Deployment Versions, each representing a different \nversion of workers. (see documentation of WorkerDeploymentVersionInfo)\nDeployment records are created in Temporal server automatically when their\nfirst poller arrives to the server.\nExperimental. Worker Deployments are experimental and might significantly change in the future."
|