temporalio 0.3.0 → 0.4.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.
- checksums.yaml +4 -4
- data/Cargo.lock +503 -395
- data/Gemfile +4 -0
- data/README.md +183 -10
- data/Rakefile +1 -1
- data/ext/Cargo.toml +1 -0
- data/lib/temporalio/activity/context.rb +13 -0
- data/lib/temporalio/activity/definition.rb +22 -5
- data/lib/temporalio/activity/info.rb +3 -0
- data/lib/temporalio/api/batch/v1/message.rb +6 -1
- data/lib/temporalio/api/command/v1/message.rb +1 -1
- data/lib/temporalio/api/common/v1/message.rb +2 -1
- data/lib/temporalio/api/deployment/v1/message.rb +38 -0
- data/lib/temporalio/api/enums/v1/batch_operation.rb +1 -1
- data/lib/temporalio/api/enums/v1/common.rb +1 -1
- data/lib/temporalio/api/enums/v1/deployment.rb +23 -0
- data/lib/temporalio/api/enums/v1/event_type.rb +1 -1
- data/lib/temporalio/api/enums/v1/failed_cause.rb +1 -1
- data/lib/temporalio/api/enums/v1/nexus.rb +21 -0
- data/lib/temporalio/api/enums/v1/reset.rb +1 -1
- data/lib/temporalio/api/enums/v1/workflow.rb +2 -1
- data/lib/temporalio/api/errordetails/v1/message.rb +3 -1
- data/lib/temporalio/api/failure/v1/message.rb +3 -1
- data/lib/temporalio/api/history/v1/message.rb +3 -1
- data/lib/temporalio/api/nexus/v1/message.rb +2 -1
- data/lib/temporalio/api/payload_visitor.rb +75 -7
- data/lib/temporalio/api/query/v1/message.rb +2 -1
- data/lib/temporalio/api/taskqueue/v1/message.rb +4 -1
- data/lib/temporalio/api/workflow/v1/message.rb +9 -1
- data/lib/temporalio/api/workflowservice/v1/request_response.rb +40 -11
- data/lib/temporalio/api/workflowservice/v1/service.rb +1 -1
- data/lib/temporalio/api.rb +1 -0
- data/lib/temporalio/client/connection/workflow_service.rb +238 -28
- data/lib/temporalio/client/interceptor.rb +39 -0
- data/lib/temporalio/client/schedule.rb +25 -1
- data/lib/temporalio/client/with_start_workflow_operation.rb +115 -0
- data/lib/temporalio/client/workflow_execution.rb +19 -0
- data/lib/temporalio/client/workflow_handle.rb +3 -3
- data/lib/temporalio/client.rb +125 -2
- data/lib/temporalio/contrib/open_telemetry.rb +470 -0
- data/lib/temporalio/error.rb +1 -0
- data/lib/temporalio/internal/bridge/api/activity_task/activity_task.rb +1 -1
- data/lib/temporalio/internal/bridge/api/common/common.rb +2 -1
- data/lib/temporalio/internal/bridge/api/workflow_activation/workflow_activation.rb +1 -1
- data/lib/temporalio/internal/bridge/api/workflow_commands/workflow_commands.rb +1 -1
- data/lib/temporalio/internal/bridge/api/workflow_completion/workflow_completion.rb +2 -1
- data/lib/temporalio/internal/bridge/runtime.rb +3 -0
- data/lib/temporalio/internal/bridge/testing.rb +3 -0
- data/lib/temporalio/internal/client/implementation.rb +232 -10
- data/lib/temporalio/internal/proto_utils.rb +34 -2
- data/lib/temporalio/internal/worker/activity_worker.rb +20 -8
- data/lib/temporalio/internal/worker/multi_runner.rb +2 -2
- data/lib/temporalio/internal/worker/workflow_instance/context.rb +57 -3
- data/lib/temporalio/internal/worker/workflow_instance/details.rb +4 -2
- data/lib/temporalio/internal/worker/workflow_instance/outbound_implementation.rb +11 -26
- data/lib/temporalio/internal/worker/workflow_instance/scheduler.rb +22 -2
- data/lib/temporalio/internal/worker/workflow_instance.rb +76 -32
- data/lib/temporalio/internal/worker/workflow_worker.rb +62 -19
- data/lib/temporalio/runtime/metric_buffer.rb +94 -0
- data/lib/temporalio/runtime.rb +48 -10
- data/lib/temporalio/search_attributes.rb +13 -0
- data/lib/temporalio/testing/activity_environment.rb +42 -14
- data/lib/temporalio/testing/workflow_environment.rb +26 -3
- data/lib/temporalio/version.rb +1 -1
- data/lib/temporalio/worker/interceptor.rb +3 -0
- data/lib/temporalio/worker/thread_pool.rb +5 -5
- data/lib/temporalio/worker/tuner.rb +38 -0
- data/lib/temporalio/worker/workflow_executor/thread_pool.rb +13 -8
- data/lib/temporalio/worker/workflow_executor.rb +1 -1
- data/lib/temporalio/worker/workflow_replayer.rb +350 -0
- data/lib/temporalio/worker.rb +58 -52
- data/lib/temporalio/workflow/definition.rb +40 -8
- data/lib/temporalio/workflow/future.rb +2 -2
- data/lib/temporalio/workflow/info.rb +22 -0
- data/lib/temporalio/workflow.rb +60 -8
- data/lib/temporalio/workflow_history.rb +26 -1
- data/temporalio.gemspec +2 -1
- metadata +26 -5
data/Gemfile
CHANGED
@@ -12,6 +12,10 @@ group :development do
|
|
12
12
|
gem 'grpc', '~> 1.69'
|
13
13
|
gem 'grpc-tools', '~> 1.69'
|
14
14
|
gem 'minitest'
|
15
|
+
# We are intentionally not pinning OTel versions here so that CI tests the latest. This also means that the OTel
|
16
|
+
# contrib library also does not require specific versions, we are relying on the compatibility rigor of OTel.
|
17
|
+
gem 'opentelemetry-api'
|
18
|
+
gem 'opentelemetry-sdk'
|
15
19
|
gem 'rake'
|
16
20
|
gem 'rake-compiler'
|
17
21
|
gem 'rbs', '~> 3.5.3'
|
data/README.md
CHANGED
@@ -11,15 +11,20 @@ execute asynchronous, long-running business logic in a scalable and resilient wa
|
|
11
11
|
|
12
12
|
Also see:
|
13
13
|
|
14
|
+
* [Ruby SDK](https://github.com/temporalio/sdk-ruby)
|
14
15
|
* [Ruby Samples](https://github.com/temporalio/samples-ruby)
|
15
|
-
* [API Documentation](https://
|
16
|
+
* [API Documentation](https://ruby.temporal.io)
|
17
|
+
|
18
|
+
**NOTE: This README is for the current branch and not necessarily what's released on RubyGems.**
|
16
19
|
|
17
20
|
⚠️ UNDER ACTIVE DEVELOPMENT
|
18
21
|
|
19
22
|
This SDK is under active development and has not released a stable version yet. APIs may change in incompatible ways
|
20
23
|
until the SDK is marked stable.
|
21
24
|
|
22
|
-
|
25
|
+
During this time, we are requesting any/all feedback from early adopters. We welcome all forms of suggestions or
|
26
|
+
opinions. Please communicate with us on [Slack](https://t.mp/slack) in the `#ruby-sdk` channel or via email at
|
27
|
+
`sdk@temporal.io`.
|
23
28
|
|
24
29
|
---
|
25
30
|
|
@@ -62,6 +67,11 @@ until the SDK is marked stable.
|
|
62
67
|
- [Activity Worker Shutdown](#activity-worker-shutdown)
|
63
68
|
- [Activity Concurrency and Executors](#activity-concurrency-and-executors)
|
64
69
|
- [Activity Testing](#activity-testing)
|
70
|
+
- [Telemetry](#telemetry)
|
71
|
+
- [Metrics](#metrics)
|
72
|
+
- [OpenTelemetry Tracing](#opentelemetry-tracing)
|
73
|
+
- [OpenTelemetry Tracing in Workflows](#opentelemetry-tracing-in-workflows)
|
74
|
+
- [Ractors](#ractors)
|
65
75
|
- [Platform Support](#platform-support)
|
66
76
|
- [Development](#development)
|
67
77
|
- [Build](#build)
|
@@ -92,8 +102,8 @@ gem install temporalio
|
|
92
102
|
|
93
103
|
**NOTE**: Only macOS ARM/x64 and Linux ARM/x64 are supported, and the platform-specific gem chosen is based on when the
|
94
104
|
gem/bundle install is performed. A source gem is published but cannot be used directly and will fail to build if tried.
|
95
|
-
MinGW-based Windows
|
96
|
-
information.
|
105
|
+
MinGW-based Windows is not currently supported. There are caveats with the Google Protobuf dependency on musl-based
|
106
|
+
Linux. See the [Platform Support](#platform-support) section for more information.
|
97
107
|
|
98
108
|
**NOTE**: Due to [an issue](https://github.com/temporalio/sdk-ruby/issues/162), fibers (and `async` gem) are only
|
99
109
|
supported on Ruby versions 3.3 and newer.
|
@@ -608,7 +618,7 @@ Or, say, to wait on the first of 5 activities or a timeout to complete:
|
|
608
618
|
# Start 5 activities
|
609
619
|
act_futs = 5.times.map do |i|
|
610
620
|
Temporalio::Workflow::Future.new do
|
611
|
-
Temporalio::Workflow.execute_activity(MyActivity, "my-arg-#{i}" schedule_to_close_timeout: 300)
|
621
|
+
Temporalio::Workflow.execute_activity(MyActivity, "my-arg-#{i}", schedule_to_close_timeout: 300)
|
612
622
|
end
|
613
623
|
end
|
614
624
|
# Start a timer
|
@@ -853,7 +863,48 @@ the mock activity class to make it appear as the real name.
|
|
853
863
|
|
854
864
|
#### Workflow Replay
|
855
865
|
|
856
|
-
|
866
|
+
Given a workflow's history, it can be replayed locally to check for things like non-determinism errors. For example,
|
867
|
+
assuming the `history_json` parameter below is given a JSON string of history exported from the CLI or web UI, the
|
868
|
+
following function will replay it:
|
869
|
+
|
870
|
+
```ruby
|
871
|
+
def replay_from_json(history_json)
|
872
|
+
replayer = Temporalio::Worker::WorkflowReplayer.new(workflows: [MyWorkflow])
|
873
|
+
replayer.replay_workflow(Temporalio::WorkflowHistory.from_history_json(history_json))
|
874
|
+
end
|
875
|
+
```
|
876
|
+
|
877
|
+
If there is a non-determinism, this will raise an exception by default.
|
878
|
+
|
879
|
+
Workflow history can be loaded from more than just JSON. It can be fetched individually from a workflow handle, or even
|
880
|
+
in a list. For example, the following code will check that all workflow histories for a certain workflow type (i.e.
|
881
|
+
workflow class) are safe with the current workflow code.
|
882
|
+
|
883
|
+
```ruby
|
884
|
+
def check_past_histories(client)
|
885
|
+
replayer = Temporalio::Worker::WorkflowReplayer.new(workflows: [MyWorkflow])
|
886
|
+
results = replayer.replay_workflows(client.list_workflows("WorkflowType = 'MyWorkflow'").map do |desc|
|
887
|
+
client.workflow_handle(desc.id, run_id: desc.run_id).fetch_history
|
888
|
+
end)
|
889
|
+
results.each { |res| raise res.replay_failure if res.replay_failure }
|
890
|
+
end
|
891
|
+
```
|
892
|
+
|
893
|
+
But this only raises at the end because by default `replay_workflows` does not raise on failure like `replay_workflow`
|
894
|
+
does. The `raise_on_replay_failure: true` parameter could be set, or the replay worker can be used to process each one
|
895
|
+
like so:
|
896
|
+
|
897
|
+
```ruby
|
898
|
+
def check_past_histories(client)
|
899
|
+
Temporalio::Worker::WorkflowReplayer.new(workflows: [MyWorkflow]) do |worker|
|
900
|
+
client.list_workflows("WorkflowType = 'MyWorkflow'").each do |desc|
|
901
|
+
worker.replay_workflow(client.workflow_handle(desc.id, run_id: desc.run_id).fetch_history)
|
902
|
+
end
|
903
|
+
end
|
904
|
+
end
|
905
|
+
```
|
906
|
+
|
907
|
+
See the `WorkflowReplayer` API documentation for more details.
|
857
908
|
|
858
909
|
### Activities
|
859
910
|
|
@@ -987,6 +1038,122 @@ it will raise the error raised in the activity.
|
|
987
1038
|
The constructor of the environment has multiple keyword arguments that can be set to affect the activity context for the
|
988
1039
|
activity.
|
989
1040
|
|
1041
|
+
### Telemetry
|
1042
|
+
|
1043
|
+
#### Metrics
|
1044
|
+
|
1045
|
+
Metrics can be configured on a `Temporalio::Runtime`. Only one runtime is expected to be created for the entire
|
1046
|
+
application and it should be created before any clients are created. For example, this configures Prometheus to export
|
1047
|
+
metrics at `http://127.0.0.1:9000/metrics`:
|
1048
|
+
|
1049
|
+
```ruby
|
1050
|
+
require 'temporalio/runtime'
|
1051
|
+
|
1052
|
+
Temporalio::Runtime.default = Temporalio::Runtime.new(
|
1053
|
+
telemetry: Temporalio::Runtime::TelemetryOptions.new(
|
1054
|
+
metrics: Temporalio::Runtime::MetricsOptions.new(
|
1055
|
+
prometheus: Temporalio::Runtime::PrometheusMetricsOptions.new(
|
1056
|
+
bind_address: '127.0.0.1:9000'
|
1057
|
+
)
|
1058
|
+
)
|
1059
|
+
)
|
1060
|
+
)
|
1061
|
+
```
|
1062
|
+
|
1063
|
+
Now every client created will use this runtime. Setting the default will fail if a runtime has already been requested or
|
1064
|
+
a default already set. Technically a runtime can be created without setting the default and be set on each client via
|
1065
|
+
the `runtime` parameter, but this is discouraged because a runtime represents a heavy internal engine not meant to be
|
1066
|
+
created multiple times.
|
1067
|
+
|
1068
|
+
OpenTelemetry metrics can be configured instead by passing `Temporalio::Runtime::OpenTelemetryMetricsOptions` as the
|
1069
|
+
`opentelemetry` parameter to the metrics options. See API documentation for details.
|
1070
|
+
|
1071
|
+
#### OpenTelemetry Tracing
|
1072
|
+
|
1073
|
+
OpenTelemetry tracing for clients, activities, and workflows can be enabled using the
|
1074
|
+
`Temporalio::Contrib::OpenTelemetry::TracingInterceptor`. Specifically, when creating a client, set the interceptor like
|
1075
|
+
so:
|
1076
|
+
|
1077
|
+
```ruby
|
1078
|
+
require 'opentelemetry/api'
|
1079
|
+
require 'opentelemetry/sdk'
|
1080
|
+
require 'temporalio/client'
|
1081
|
+
require 'temporalio/contrib/open_telemetry'
|
1082
|
+
|
1083
|
+
# ... assumes my_otel_tracer_provider is a tracer provider created by the user
|
1084
|
+
my_tracer = my_otel_tracer_provider.tracer('my-otel-tracer')
|
1085
|
+
|
1086
|
+
my_client = Temporalio::Client.connect(
|
1087
|
+
'localhost:7233', 'my-namespace',
|
1088
|
+
interceptors: [Temporalio::Contrib::OpenTelemetry::TracingInterceptor.new(my_tracer)]
|
1089
|
+
)
|
1090
|
+
```
|
1091
|
+
|
1092
|
+
Now many high-level client calls and activities/workflows on workers using this client will have spans created on that
|
1093
|
+
OpenTelemetry tracer.
|
1094
|
+
|
1095
|
+
##### OpenTelemetry Tracing in Workflows
|
1096
|
+
|
1097
|
+
OpenTelemetry works by creating spans as necessary and in some cases serializing them to Temporal headers to be
|
1098
|
+
deserialized by workflows/activities to be set on the context. However, OpenTelemetry requires spans to be finished
|
1099
|
+
where they start, so spans cannot be resumed. This is fine for client calls and activity attempts, but Temporal
|
1100
|
+
workflows are resumable functions that may start on a different machine than they complete. Due to this, spans created
|
1101
|
+
by workflows are immediately closed since there is no way for the span to actually span machines. They are also not
|
1102
|
+
created during replay. The spans still become the proper parents of other spans if they are created.
|
1103
|
+
|
1104
|
+
Custom spans can be created inside of workflows using class methods on the
|
1105
|
+
`Temporalio::Contrib::OpenTelemetry::Workflow` module. For example:
|
1106
|
+
|
1107
|
+
```ruby
|
1108
|
+
class MyWorkflow < Temporalio::Workflow::Definition
|
1109
|
+
def execute
|
1110
|
+
# Sleep for a bit
|
1111
|
+
Temporalio::Workflow.sleep(10)
|
1112
|
+
# Run activity in span
|
1113
|
+
Temporalio::Contrib::OpenTelemetry::Workflow.with_completed_span(
|
1114
|
+
'my-span',
|
1115
|
+
attributes: { 'my-attr' => 'some val' }
|
1116
|
+
) do
|
1117
|
+
# Execute an activity
|
1118
|
+
Temporalio::Workflow.execute_activity(MyActivity, start_to_close_timeout: 10)
|
1119
|
+
end
|
1120
|
+
end
|
1121
|
+
end
|
1122
|
+
```
|
1123
|
+
|
1124
|
+
If this all executes on one worker (because Temporal has a concept of stickiness that caches instances), the span tree
|
1125
|
+
may look like:
|
1126
|
+
|
1127
|
+
```
|
1128
|
+
StartWorkflow:MyWorkflow <-- created by client outbound
|
1129
|
+
RunWorkflow:MyWorkflow <-- created inside workflow on first task
|
1130
|
+
my-span <-- created inside workflow by code
|
1131
|
+
StartActivity:MyActivity <-- created inside workflow when first called
|
1132
|
+
RunActivity:MyActivity <-- created inside activity attempt 1
|
1133
|
+
CompleteWorkflow:MyWorkflow <-- created inside workflow on last task
|
1134
|
+
```
|
1135
|
+
|
1136
|
+
However if, say, the worker crashed during the 10s sleep and the workflow was resumed (i.e. replayed) on another worker,
|
1137
|
+
the span tree may look like:
|
1138
|
+
|
1139
|
+
```
|
1140
|
+
StartWorkflow:MyWorkflow <-- created by client outbound
|
1141
|
+
RunWorkflow:MyWorkflow <-- created by workflow inbound on first task
|
1142
|
+
my-span <-- created inside the workflow
|
1143
|
+
StartActivity:MyActivity <-- created by workflow outbound
|
1144
|
+
RunActivity:MyActivity <-- created by activity attempt 1 inbound
|
1145
|
+
CompleteWorkflow:MyWorkflow <-- created by workflow inbound on last task
|
1146
|
+
```
|
1147
|
+
|
1148
|
+
Notice how the spans are no longer under `RunWorkflow`. This is because spans inside the workflow are not created on
|
1149
|
+
replay, so there is no parent on replay. But there are no orphans because we still have the overarching parent of
|
1150
|
+
`StartWorkflow` that was created by the client and is serialized into Temporal headers so it can always be the parent.
|
1151
|
+
|
1152
|
+
And reminder that `StartWorkflow` and `RunActivity` spans do last the length of their calls (so time to start the
|
1153
|
+
workflow and time to run the activity attempt respectively), but the other spans have no measurable time because they
|
1154
|
+
are created in workflows and closed immediately since long-lived spans cannot work for durable software that may resume
|
1155
|
+
on other machines.
|
1156
|
+
|
990
1157
|
### Ractors
|
991
1158
|
|
992
1159
|
It was an original goal to have workflows actually be Ractors for deterministic state isolation and have the library
|
@@ -1000,21 +1167,27 @@ This SDK is backed by a Ruby C extension written in Rust leveraging the
|
|
1000
1167
|
[Temporal Rust Core](https://github.com/temporalio/sdk-core). Gems are currently published for the following platforms:
|
1001
1168
|
|
1002
1169
|
* `aarch64-linux`
|
1170
|
+
* `aarch64-linux-musl`
|
1003
1171
|
* `x86_64-linux`
|
1172
|
+
* `x86_64-linux-musl`
|
1004
1173
|
* `arm64-darwin`
|
1005
1174
|
* `x86_64-darwin`
|
1006
1175
|
|
1007
|
-
This means Linux and macOS for ARM and x64 have published gems.
|
1008
|
-
`aarch64-linux-musl` so Alpine Linux users may need to build from scratch or use a libc-based distro.
|
1176
|
+
This means Linux and macOS for ARM and x64 have published gems.
|
1009
1177
|
|
1010
1178
|
Due to [an issue](https://github.com/temporalio/sdk-ruby/issues/172) with Windows and multi-threaded Rust, MinGW-based
|
1011
1179
|
Windows (i.e. `x64-mingw-ucrt`) is not supported. But WSL is supported using the normal Linux gem.
|
1012
1180
|
|
1181
|
+
Due to [an issue](https://github.com/protocolbuffers/protobuf/issues/16853) with Google Protobuf, latest Linux versions
|
1182
|
+
of Google Protobuf gems will not work in musl-based environments. Instead use the pure "ruby" platform which will build
|
1183
|
+
the Google Protobuf gem on install (e.g.
|
1184
|
+
`gem 'google-protobuf', force_ruby_platform: RUBY_PLATFORM.include?('linux-musl')` in the `Gemfile`).
|
1185
|
+
|
1013
1186
|
At this time a pure source gem is published for documentation reasons, but it cannot be built and will fail if tried.
|
1014
1187
|
Building from source requires many files across submodules and requires Rust to be installed. See the [Build](#build)
|
1015
1188
|
section for how to build a the repository.
|
1016
1189
|
|
1017
|
-
The SDK works on Ruby 3.
|
1190
|
+
The SDK works on Ruby 3.2+, but due to [an issue](https://github.com/temporalio/sdk-ruby/issues/162), fibers (and
|
1018
1191
|
`async` gem) are only supported on Ruby versions 3.3 and newer.
|
1019
1192
|
|
1020
1193
|
## Development
|
@@ -1023,7 +1196,7 @@ The SDK works on Ruby 3.1+, but due to [an issue](https://github.com/temporalio/
|
|
1023
1196
|
|
1024
1197
|
Prerequisites:
|
1025
1198
|
|
1026
|
-
* [Ruby](https://www.ruby-lang.org/) >= 3.
|
1199
|
+
* [Ruby](https://www.ruby-lang.org/) >= 3.2 (i.e. `ruby` and `bundle` on the `PATH`)
|
1027
1200
|
* [Rust](https://www.rust-lang.org/) latest stable (i.e. `cargo` on the `PATH`)
|
1028
1201
|
* This repository, cloned recursively
|
1029
1202
|
* Change to the `temporalio/` directory
|
data/Rakefile
CHANGED
data/ext/Cargo.toml
CHANGED
@@ -20,6 +20,7 @@ temporal-sdk-core = { version = "0.1.0", path = "./sdk-core/core", features = ["
|
|
20
20
|
temporal-sdk-core-api = { version = "0.1.0", path = "./sdk-core/core-api" }
|
21
21
|
temporal-sdk-core-protos = { version = "0.1.0", path = "./sdk-core/sdk-core-protos" }
|
22
22
|
tokio = "1.26"
|
23
|
+
tokio-stream = "0.1"
|
23
24
|
tokio-util = "0.7"
|
24
25
|
tonic = "0.12"
|
25
26
|
tracing = "0.1"
|
@@ -48,6 +48,12 @@ module Temporalio
|
|
48
48
|
raise NotImplementedError
|
49
49
|
end
|
50
50
|
|
51
|
+
# @return [Object, nil] Activity class instance. This should always be present except for advanced cases where the
|
52
|
+
# definition was manually created without any instance getter/creator.
|
53
|
+
def instance
|
54
|
+
raise NotImplementedError
|
55
|
+
end
|
56
|
+
|
51
57
|
# Record a heartbeat on the activity.
|
52
58
|
#
|
53
59
|
# Heartbeats should be used for all non-immediately-returning, non-local activities and they are required to
|
@@ -102,9 +108,16 @@ module Temporalio
|
|
102
108
|
end
|
103
109
|
|
104
110
|
# @return [Metric::Meter] Metric meter to create metrics on, with some activity-specific attributes already set.
|
111
|
+
# @raise [RuntimeError] Called within a {Testing::ActivityEnvironment} and it was not set.
|
105
112
|
def metric_meter
|
106
113
|
raise NotImplementedError
|
107
114
|
end
|
115
|
+
|
116
|
+
# @return [Client] Temporal client this activity worker is running in.
|
117
|
+
# @raise [RuntimeError] Called within a {Testing::ActivityEnvironment} and it was not set.
|
118
|
+
def client
|
119
|
+
raise NotImplementedError
|
120
|
+
end
|
108
121
|
end
|
109
122
|
end
|
110
123
|
end
|
@@ -1,5 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require 'temporalio/internal/proto_utils'
|
4
|
+
|
3
5
|
module Temporalio
|
4
6
|
module Activity
|
5
7
|
# Base class for all activities.
|
@@ -88,7 +90,7 @@ module Temporalio
|
|
88
90
|
{
|
89
91
|
activity_name:,
|
90
92
|
activity_executor: @activity_executor || :default,
|
91
|
-
activity_cancel_raise: @activity_cancel_raise.nil?
|
93
|
+
activity_cancel_raise: @activity_cancel_raise.nil? || @activity_cancel_raise,
|
92
94
|
activity_raw_args: @activity_raw_args.nil? ? false : @activity_raw_args
|
93
95
|
}
|
94
96
|
end
|
@@ -105,7 +107,10 @@ module Temporalio
|
|
105
107
|
# @return [String, Symbol, nil] Name of the activity, or nil if the activity is dynamic.
|
106
108
|
attr_reader :name
|
107
109
|
|
108
|
-
# @return [Proc]
|
110
|
+
# @return [Object, Proc, nil] The pre-created instance or the proc to create/return it.
|
111
|
+
attr_reader :instance
|
112
|
+
|
113
|
+
# @return [Proc] Proc for the activity. Should use {Context#instance} to access the instance.
|
109
114
|
attr_reader :proc
|
110
115
|
|
111
116
|
# @return [Symbol] Name of the executor. Default is `:default`.
|
@@ -134,18 +139,20 @@ module Temporalio
|
|
134
139
|
details = activity._activity_definition_details
|
135
140
|
new(
|
136
141
|
name: details[:activity_name],
|
142
|
+
instance: proc { activity.new },
|
137
143
|
executor: details[:activity_executor],
|
138
144
|
cancel_raise: details[:activity_cancel_raise],
|
139
145
|
raw_args: details[:activity_raw_args]
|
140
|
-
) { |*args|
|
146
|
+
) { |*args| Context.current.instance&.execute(*args) }
|
141
147
|
when Definition
|
142
148
|
details = activity.class._activity_definition_details
|
143
149
|
new(
|
144
150
|
name: details[:activity_name],
|
151
|
+
instance: activity,
|
145
152
|
executor: details[:activity_executor],
|
146
153
|
cancel_raise: details[:activity_cancel_raise],
|
147
154
|
raw_args: details[:activity_raw_args]
|
148
|
-
) { |*args|
|
155
|
+
) { |*args| Context.current.instance&.execute(*args) }
|
149
156
|
when Info
|
150
157
|
activity
|
151
158
|
else
|
@@ -156,18 +163,28 @@ module Temporalio
|
|
156
163
|
# Manually create activity definition info. Most users will use an instance/class of {Definition}.
|
157
164
|
#
|
158
165
|
# @param name [String, Symbol, nil] Name of the activity or nil for dynamic activity.
|
166
|
+
# @param instance [Object, Proc, nil] The pre-created instance or the proc to create/return it.
|
159
167
|
# @param executor [Symbol] Name of the executor.
|
160
168
|
# @param cancel_raise [Boolean] Whether to raise in thread/fiber on cancellation.
|
161
169
|
# @param raw_args [Boolean] Whether to use {Converters::RawValue}s as arguments.
|
162
170
|
# @yield Use this block as the activity.
|
163
|
-
def initialize(
|
171
|
+
def initialize(
|
172
|
+
name:,
|
173
|
+
instance: nil,
|
174
|
+
executor: :default,
|
175
|
+
cancel_raise: true,
|
176
|
+
raw_args: false,
|
177
|
+
&block
|
178
|
+
)
|
164
179
|
@name = name
|
180
|
+
@instance = instance
|
165
181
|
raise ArgumentError, 'Must give block' unless block_given?
|
166
182
|
|
167
183
|
@proc = block
|
168
184
|
@executor = executor
|
169
185
|
@cancel_raise = cancel_raise
|
170
186
|
@raw_args = raw_args
|
187
|
+
Internal::ProtoUtils.assert_non_reserved_name(name)
|
171
188
|
end
|
172
189
|
end
|
173
190
|
end
|
@@ -59,6 +59,9 @@ module Temporalio
|
|
59
59
|
# @return [String] Workflow run ID that started this activity.
|
60
60
|
# @!attribute workflow_type
|
61
61
|
# @return [String] Workflow type name that started this activity.
|
62
|
+
#
|
63
|
+
# @note WARNING: This class may have required parameters added to its constructor. Users should not instantiate this
|
64
|
+
# class or it may break in incompatible ways.
|
62
65
|
class Info; end # rubocop:disable Lint/EmptyClass
|
63
66
|
end
|
64
67
|
end
|
@@ -4,13 +4,16 @@
|
|
4
4
|
|
5
5
|
require 'google/protobuf'
|
6
6
|
|
7
|
+
require 'google/protobuf/duration_pb'
|
8
|
+
require 'google/protobuf/field_mask_pb'
|
7
9
|
require 'google/protobuf/timestamp_pb'
|
8
10
|
require 'temporalio/api/common/v1/message'
|
9
11
|
require 'temporalio/api/enums/v1/batch_operation'
|
10
12
|
require 'temporalio/api/enums/v1/reset'
|
13
|
+
require 'temporalio/api/workflow/v1/message'
|
11
14
|
|
12
15
|
|
13
|
-
descriptor_data = "\n#temporal/api/batch/v1/message.proto\x12\x15temporal.api.batch.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a$temporal/api/common/v1/message.proto\x1a+temporal/api/enums/v1/batch_operation.proto\x1a!temporal/api/enums/v1/reset.proto\"\xbf\x01\n\x12\x42\x61tchOperationInfo\x12\x0e\n\x06job_id\x18\x01 \x01(\t\x12\x39\n\x05state\x18\x02 \x01(\x0e\x32*.temporal.api.enums.v1.BatchOperationState\x12.\n\nstart_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12.\n\nclose_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"`\n\x19\x42\x61tchOperationTermination\x12\x31\n\x07\x64\x65tails\x18\x01 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12\x10\n\x08identity\x18\x02 \x01(\t\"\x99\x01\n\x14\x42\x61tchOperationSignal\x12\x0e\n\x06signal\x18\x01 \x01(\t\x12/\n\x05input\x18\x02 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12.\n\x06header\x18\x03 \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12\x10\n\x08identity\x18\x04 \x01(\t\".\n\x1a\x42\x61tchOperationCancellation\x12\x10\n\x08identity\x18\x01 \x01(\t\"*\n\x16\x42\x61tchOperationDeletion\x12\x10\n\x08identity\x18\x01 \x01(\t\"\xd9\x01\n\x13\x42\x61tchOperationReset\x12\x10\n\x08identity\x18\x03 \x01(\t\x12\x35\n\x07options\x18\x04 \x01(\x0b\x32$.temporal.api.common.v1.ResetOptions\x12\x34\n\nreset_type\x18\x01 \x01(\x0e\x32 .temporal.api.enums.v1.ResetType\x12\x43\n\x12reset_reapply_type\x18\x02 \x01(\x0e\x32\'.temporal.api.enums.v1.
|
16
|
+
descriptor_data = "\n#temporal/api/batch/v1/message.proto\x12\x15temporal.api.batch.v1\x1a\x1egoogle/protobuf/duration.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a$temporal/api/common/v1/message.proto\x1a+temporal/api/enums/v1/batch_operation.proto\x1a!temporal/api/enums/v1/reset.proto\x1a&temporal/api/workflow/v1/message.proto\"\xbf\x01\n\x12\x42\x61tchOperationInfo\x12\x0e\n\x06job_id\x18\x01 \x01(\t\x12\x39\n\x05state\x18\x02 \x01(\x0e\x32*.temporal.api.enums.v1.BatchOperationState\x12.\n\nstart_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12.\n\nclose_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"`\n\x19\x42\x61tchOperationTermination\x12\x31\n\x07\x64\x65tails\x18\x01 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12\x10\n\x08identity\x18\x02 \x01(\t\"\x99\x01\n\x14\x42\x61tchOperationSignal\x12\x0e\n\x06signal\x18\x01 \x01(\t\x12/\n\x05input\x18\x02 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12.\n\x06header\x18\x03 \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12\x10\n\x08identity\x18\x04 \x01(\t\".\n\x1a\x42\x61tchOperationCancellation\x12\x10\n\x08identity\x18\x01 \x01(\t\"*\n\x16\x42\x61tchOperationDeletion\x12\x10\n\x08identity\x18\x01 \x01(\t\"\xd9\x01\n\x13\x42\x61tchOperationReset\x12\x10\n\x08identity\x18\x03 \x01(\t\x12\x35\n\x07options\x18\x04 \x01(\x0b\x32$.temporal.api.common.v1.ResetOptions\x12\x34\n\nreset_type\x18\x01 \x01(\x0e\x32 .temporal.api.enums.v1.ResetType\x12\x43\n\x12reset_reapply_type\x18\x02 \x01(\x0e\x32\'.temporal.api.enums.v1.ResetReapplyType\"\xc9\x01\n,BatchOperationUpdateWorkflowExecutionOptions\x12\x10\n\x08identity\x18\x01 \x01(\t\x12V\n\x1aworkflow_execution_options\x18\x02 \x01(\x0b\x32\x32.temporal.api.workflow.v1.WorkflowExecutionOptions\x12/\n\x0bupdate_mask\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.FieldMask\"\xc0\x01\n\x1f\x42\x61tchOperationUnpauseActivities\x12\x10\n\x08identity\x18\x01 \x01(\t\x12\x0e\n\x04type\x18\x02 \x01(\tH\x00\x12\x13\n\tmatch_all\x18\x03 \x01(\x08H\x00\x12\x16\n\x0ereset_attempts\x18\x04 \x01(\x08\x12\x17\n\x0freset_heartbeat\x18\x05 \x01(\x08\x12)\n\x06jitter\x18\x06 \x01(\x0b\x32\x19.google.protobuf.DurationB\n\n\x08\x61\x63tivityB\x84\x01\n\x18io.temporal.api.batch.v1B\x0cMessageProtoP\x01Z!go.temporal.io/api/batch/v1;batch\xaa\x02\x17Temporalio.Api.Batch.V1\xea\x02\x1aTemporalio::Api::Batch::V1b\x06proto3"
|
14
17
|
|
15
18
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
16
19
|
pool.add_serialized_file(descriptor_data)
|
@@ -25,6 +28,8 @@ module Temporalio
|
|
25
28
|
BatchOperationCancellation = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.batch.v1.BatchOperationCancellation").msgclass
|
26
29
|
BatchOperationDeletion = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.batch.v1.BatchOperationDeletion").msgclass
|
27
30
|
BatchOperationReset = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.batch.v1.BatchOperationReset").msgclass
|
31
|
+
BatchOperationUpdateWorkflowExecutionOptions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.batch.v1.BatchOperationUpdateWorkflowExecutionOptions").msgclass
|
32
|
+
BatchOperationUnpauseActivities = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.batch.v1.BatchOperationUnpauseActivities").msgclass
|
28
33
|
end
|
29
34
|
end
|
30
35
|
end
|
@@ -13,7 +13,7 @@ require 'temporalio/api/taskqueue/v1/message'
|
|
13
13
|
require 'temporalio/api/sdk/v1/user_metadata'
|
14
14
|
|
15
15
|
|
16
|
-
descriptor_data = "\n%temporal/api/command/v1/message.proto\x12\x17temporal.api.command.v1\x1a\x1egoogle/protobuf/duration.proto\x1a$temporal/api/enums/v1/workflow.proto\x1a(temporal/api/enums/v1/command_type.proto\x1a$temporal/api/common/v1/message.proto\x1a%temporal/api/failure/v1/message.proto\x1a\'temporal/api/taskqueue/v1/message.proto\x1a\'temporal/api/sdk/v1/user_metadata.proto\"\
|
16
|
+
descriptor_data = "\n%temporal/api/command/v1/message.proto\x12\x17temporal.api.command.v1\x1a\x1egoogle/protobuf/duration.proto\x1a$temporal/api/enums/v1/workflow.proto\x1a(temporal/api/enums/v1/command_type.proto\x1a$temporal/api/common/v1/message.proto\x1a%temporal/api/failure/v1/message.proto\x1a\'temporal/api/taskqueue/v1/message.proto\x1a\'temporal/api/sdk/v1/user_metadata.proto\"\xb6\x05\n%ScheduleActivityTaskCommandAttributes\x12\x13\n\x0b\x61\x63tivity_id\x18\x01 \x01(\t\x12;\n\ractivity_type\x18\x02 \x01(\x0b\x32$.temporal.api.common.v1.ActivityType\x12\x38\n\ntask_queue\x18\x04 \x01(\x0b\x32$.temporal.api.taskqueue.v1.TaskQueue\x12.\n\x06header\x18\x05 \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12/\n\x05input\x18\x06 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12<\n\x19schedule_to_close_timeout\x18\x07 \x01(\x0b\x32\x19.google.protobuf.Duration\x12<\n\x19schedule_to_start_timeout\x18\x08 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x39\n\x16start_to_close_timeout\x18\t \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x34\n\x11heartbeat_timeout\x18\n \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x39\n\x0cretry_policy\x18\x0b \x01(\x0b\x32#.temporal.api.common.v1.RetryPolicy\x12\x1f\n\x17request_eager_execution\x18\x0c \x01(\x08\x12\x1d\n\x15use_workflow_build_id\x18\r \x01(\x08\x12\x32\n\x08priority\x18\x0e \x01(\x0b\x32 .temporal.api.common.v1.PriorityJ\x04\x08\x03\x10\x04\"H\n*RequestCancelActivityTaskCommandAttributes\x12\x1a\n\x12scheduled_event_id\x18\x01 \x01(\x03\"i\n\x1bStartTimerCommandAttributes\x12\x10\n\x08timer_id\x18\x01 \x01(\t\x12\x38\n\x15start_to_fire_timeout\x18\x02 \x01(\x0b\x32\x19.google.protobuf.Duration\"^\n*CompleteWorkflowExecutionCommandAttributes\x12\x30\n\x06result\x18\x01 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\"[\n&FailWorkflowExecutionCommandAttributes\x12\x31\n\x07\x66\x61ilure\x18\x01 \x01(\x0b\x32 .temporal.api.failure.v1.Failure\"0\n\x1c\x43\x61ncelTimerCommandAttributes\x12\x10\n\x08timer_id\x18\x01 \x01(\t\"]\n(CancelWorkflowExecutionCommandAttributes\x12\x31\n\x07\x64\x65tails\x18\x01 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\"\xaf\x01\n7RequestCancelExternalWorkflowExecutionCommandAttributes\x12\x11\n\tnamespace\x18\x01 \x01(\t\x12\x13\n\x0bworkflow_id\x18\x02 \x01(\t\x12\x0e\n\x06run_id\x18\x03 \x01(\t\x12\x0f\n\x07\x63ontrol\x18\x04 \x01(\t\x12\x1b\n\x13\x63hild_workflow_only\x18\x05 \x01(\x08\x12\x0e\n\x06reason\x18\x06 \x01(\t\"\xa7\x02\n0SignalExternalWorkflowExecutionCommandAttributes\x12\x11\n\tnamespace\x18\x01 \x01(\t\x12<\n\texecution\x18\x02 \x01(\x0b\x32).temporal.api.common.v1.WorkflowExecution\x12\x13\n\x0bsignal_name\x18\x03 \x01(\t\x12/\n\x05input\x18\x04 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12\x0f\n\x07\x63ontrol\x18\x05 \x01(\t\x12\x1b\n\x13\x63hild_workflow_only\x18\x06 \x01(\x08\x12.\n\x06header\x18\x07 \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\"v\n/UpsertWorkflowSearchAttributesCommandAttributes\x12\x43\n\x11search_attributes\x18\x01 \x01(\x0b\x32(.temporal.api.common.v1.SearchAttributes\"`\n)ModifyWorkflowPropertiesCommandAttributes\x12\x33\n\rupserted_memo\x18\x01 \x01(\x0b\x32\x1c.temporal.api.common.v1.Memo\"\xbf\x02\n\x1dRecordMarkerCommandAttributes\x12\x13\n\x0bmarker_name\x18\x01 \x01(\t\x12T\n\x07\x64\x65tails\x18\x02 \x03(\x0b\x32\x43.temporal.api.command.v1.RecordMarkerCommandAttributes.DetailsEntry\x12.\n\x06header\x18\x03 \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12\x31\n\x07\x66\x61ilure\x18\x04 \x01(\x0b\x32 .temporal.api.failure.v1.Failure\x1aP\n\x0c\x44\x65tailsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12/\n\x05value\x18\x02 \x01(\x0b\x32 .temporal.api.common.v1.Payloads:\x02\x38\x01\"\xcb\x06\n/ContinueAsNewWorkflowExecutionCommandAttributes\x12;\n\rworkflow_type\x18\x01 \x01(\x0b\x32$.temporal.api.common.v1.WorkflowType\x12\x38\n\ntask_queue\x18\x02 \x01(\x0b\x32$.temporal.api.taskqueue.v1.TaskQueue\x12/\n\x05input\x18\x03 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12\x37\n\x14workflow_run_timeout\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x38\n\x15workflow_task_timeout\x18\x05 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x39\n\x16\x62\x61\x63koff_start_interval\x18\x06 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x39\n\x0cretry_policy\x18\x07 \x01(\x0b\x32#.temporal.api.common.v1.RetryPolicy\x12@\n\tinitiator\x18\x08 \x01(\x0e\x32-.temporal.api.enums.v1.ContinueAsNewInitiator\x12\x31\n\x07\x66\x61ilure\x18\t \x01(\x0b\x32 .temporal.api.failure.v1.Failure\x12@\n\x16last_completion_result\x18\n \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12\x15\n\rcron_schedule\x18\x0b \x01(\t\x12.\n\x06header\x18\x0c \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12*\n\x04memo\x18\r \x01(\x0b\x32\x1c.temporal.api.common.v1.Memo\x12\x43\n\x11search_attributes\x18\x0e \x01(\x0b\x32(.temporal.api.common.v1.SearchAttributes\x12\x18\n\x10inherit_build_id\x18\x0f \x01(\x08\"\x99\x07\n,StartChildWorkflowExecutionCommandAttributes\x12\x11\n\tnamespace\x18\x01 \x01(\t\x12\x13\n\x0bworkflow_id\x18\x02 \x01(\t\x12;\n\rworkflow_type\x18\x03 \x01(\x0b\x32$.temporal.api.common.v1.WorkflowType\x12\x38\n\ntask_queue\x18\x04 \x01(\x0b\x32$.temporal.api.taskqueue.v1.TaskQueue\x12/\n\x05input\x18\x05 \x01(\x0b\x32 .temporal.api.common.v1.Payloads\x12=\n\x1aworkflow_execution_timeout\x18\x06 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14workflow_run_timeout\x18\x07 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x38\n\x15workflow_task_timeout\x18\x08 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x45\n\x13parent_close_policy\x18\t \x01(\x0e\x32(.temporal.api.enums.v1.ParentClosePolicy\x12\x0f\n\x07\x63ontrol\x18\n \x01(\t\x12N\n\x18workflow_id_reuse_policy\x18\x0b \x01(\x0e\x32,.temporal.api.enums.v1.WorkflowIdReusePolicy\x12\x39\n\x0cretry_policy\x18\x0c \x01(\x0b\x32#.temporal.api.common.v1.RetryPolicy\x12\x15\n\rcron_schedule\x18\r \x01(\t\x12.\n\x06header\x18\x0e \x01(\x0b\x32\x1e.temporal.api.common.v1.Header\x12*\n\x04memo\x18\x0f \x01(\x0b\x32\x1c.temporal.api.common.v1.Memo\x12\x43\n\x11search_attributes\x18\x10 \x01(\x0b\x32(.temporal.api.common.v1.SearchAttributes\x12\x18\n\x10inherit_build_id\x18\x11 \x01(\x08\x12\x32\n\x08priority\x18\x12 \x01(\x0b\x32 .temporal.api.common.v1.Priority\"6\n ProtocolMessageCommandAttributes\x12\x12\n\nmessage_id\x18\x01 \x01(\t\"\xea\x02\n\'ScheduleNexusOperationCommandAttributes\x12\x10\n\x08\x65ndpoint\x18\x01 \x01(\t\x12\x0f\n\x07service\x18\x02 \x01(\t\x12\x11\n\toperation\x18\x03 \x01(\t\x12.\n\x05input\x18\x04 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload\x12<\n\x19schedule_to_close_timeout\x18\x05 \x01(\x0b\x32\x19.google.protobuf.Duration\x12g\n\x0cnexus_header\x18\x06 \x03(\x0b\x32Q.temporal.api.command.v1.ScheduleNexusOperationCommandAttributes.NexusHeaderEntry\x1a\x32\n\x10NexusHeaderEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"J\n,RequestCancelNexusOperationCommandAttributes\x12\x1a\n\x12scheduled_event_id\x18\x01 \x01(\x03\"\xc2\x11\n\x07\x43ommand\x12\x38\n\x0c\x63ommand_type\x18\x01 \x01(\x0e\x32\".temporal.api.enums.v1.CommandType\x12\x39\n\ruser_metadata\x18\xad\x02 \x01(\x0b\x32!.temporal.api.sdk.v1.UserMetadata\x12s\n)schedule_activity_task_command_attributes\x18\x02 \x01(\x0b\x32>.temporal.api.command.v1.ScheduleActivityTaskCommandAttributesH\x00\x12^\n\x1estart_timer_command_attributes\x18\x03 \x01(\x0b\x32\x34.temporal.api.command.v1.StartTimerCommandAttributesH\x00\x12}\n.complete_workflow_execution_command_attributes\x18\x04 \x01(\x0b\x32\x43.temporal.api.command.v1.CompleteWorkflowExecutionCommandAttributesH\x00\x12u\n*fail_workflow_execution_command_attributes\x18\x05 \x01(\x0b\x32?.temporal.api.command.v1.FailWorkflowExecutionCommandAttributesH\x00\x12~\n/request_cancel_activity_task_command_attributes\x18\x06 \x01(\x0b\x32\x43.temporal.api.command.v1.RequestCancelActivityTaskCommandAttributesH\x00\x12`\n\x1f\x63\x61ncel_timer_command_attributes\x18\x07 \x01(\x0b\x32\x35.temporal.api.command.v1.CancelTimerCommandAttributesH\x00\x12y\n,cancel_workflow_execution_command_attributes\x18\x08 \x01(\x0b\x32\x41.temporal.api.command.v1.CancelWorkflowExecutionCommandAttributesH\x00\x12\x99\x01\n=request_cancel_external_workflow_execution_command_attributes\x18\t \x01(\x0b\x32P.temporal.api.command.v1.RequestCancelExternalWorkflowExecutionCommandAttributesH\x00\x12\x62\n record_marker_command_attributes\x18\n \x01(\x0b\x32\x36.temporal.api.command.v1.RecordMarkerCommandAttributesH\x00\x12\x89\x01\n5continue_as_new_workflow_execution_command_attributes\x18\x0b \x01(\x0b\x32H.temporal.api.command.v1.ContinueAsNewWorkflowExecutionCommandAttributesH\x00\x12\x82\x01\n1start_child_workflow_execution_command_attributes\x18\x0c \x01(\x0b\x32\x45.temporal.api.command.v1.StartChildWorkflowExecutionCommandAttributesH\x00\x12\x8a\x01\n5signal_external_workflow_execution_command_attributes\x18\r \x01(\x0b\x32I.temporal.api.command.v1.SignalExternalWorkflowExecutionCommandAttributesH\x00\x12\x88\x01\n4upsert_workflow_search_attributes_command_attributes\x18\x0e \x01(\x0b\x32H.temporal.api.command.v1.UpsertWorkflowSearchAttributesCommandAttributesH\x00\x12h\n#protocol_message_command_attributes\x18\x0f \x01(\x0b\x32\x39.temporal.api.command.v1.ProtocolMessageCommandAttributesH\x00\x12{\n-modify_workflow_properties_command_attributes\x18\x11 \x01(\x0b\x32\x42.temporal.api.command.v1.ModifyWorkflowPropertiesCommandAttributesH\x00\x12w\n+schedule_nexus_operation_command_attributes\x18\x12 \x01(\x0b\x32@.temporal.api.command.v1.ScheduleNexusOperationCommandAttributesH\x00\x12\x82\x01\n1request_cancel_nexus_operation_command_attributes\x18\x13 \x01(\x0b\x32\x45.temporal.api.command.v1.RequestCancelNexusOperationCommandAttributesH\x00\x42\x0c\n\nattributesB\x8e\x01\n\x1aio.temporal.api.command.v1B\x0cMessageProtoP\x01Z%go.temporal.io/api/command/v1;command\xaa\x02\x19Temporalio.Api.Command.V1\xea\x02\x1cTemporalio::Api::Command::V1b\x06proto3"
|
17
17
|
|
18
18
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
19
19
|
pool.add_serialized_file(descriptor_data)
|
@@ -11,7 +11,7 @@ require 'temporalio/api/enums/v1/event_type'
|
|
11
11
|
require 'temporalio/api/enums/v1/reset'
|
12
12
|
|
13
13
|
|
14
|
-
descriptor_data = "\n$temporal/api/common/v1/message.proto\x12\x16temporal.api.common.v1\x1a\x1egoogle/protobuf/duration.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a\"temporal/api/enums/v1/common.proto\x1a&temporal/api/enums/v1/event_type.proto\x1a!temporal/api/enums/v1/reset.proto\"T\n\x08\x44\x61taBlob\x12:\n\rencoding_type\x18\x01 \x01(\x0e\x32#.temporal.api.enums.v1.EncodingType\x12\x0c\n\x04\x64\x61ta\x18\x02 \x01(\x0c\"=\n\x08Payloads\x12\x31\n\x08payloads\x18\x01 \x03(\x0b\x32\x1f.temporal.api.common.v1.Payload\"\x89\x01\n\x07Payload\x12?\n\x08metadata\x18\x01 \x03(\x0b\x32-.temporal.api.common.v1.Payload.MetadataEntry\x12\x0c\n\x04\x64\x61ta\x18\x02 \x01(\x0c\x1a/\n\rMetadataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\"\xbe\x01\n\x10SearchAttributes\x12S\n\x0eindexed_fields\x18\x01 \x03(\x0b\x32;.temporal.api.common.v1.SearchAttributes.IndexedFieldsEntry\x1aU\n\x12IndexedFieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\x90\x01\n\x04Memo\x12\x38\n\x06\x66ields\x18\x01 \x03(\x0b\x32(.temporal.api.common.v1.Memo.FieldsEntry\x1aN\n\x0b\x46ieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\x94\x01\n\x06Header\x12:\n\x06\x66ields\x18\x01 \x03(\x0b\x32*.temporal.api.common.v1.Header.FieldsEntry\x1aN\n\x0b\x46ieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"8\n\x11WorkflowExecution\x12\x13\n\x0bworkflow_id\x18\x01 \x01(\t\x12\x0e\n\x06run_id\x18\x02 \x01(\t\"\x1c\n\x0cWorkflowType\x12\x0c\n\x04name\x18\x01 \x01(\t\"\x1c\n\x0c\x41\x63tivityType\x12\x0c\n\x04name\x18\x01 \x01(\t\"\xd1\x01\n\x0bRetryPolicy\x12\x33\n\x10initial_interval\x18\x01 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x1b\n\x13\x62\x61\x63koff_coefficient\x18\x02 \x01(\x01\x12\x33\n\x10maximum_interval\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x18\n\x10maximum_attempts\x18\x04 \x01(\x05\x12!\n\x19non_retryable_error_types\x18\x05 \x03(\t\"F\n\x10MeteringMetadata\x12\x32\n*nonfirst_local_activity_execution_attempts\x18\r \x01(\r\">\n\x12WorkerVersionStamp\x12\x10\n\x08\x62uild_id\x18\x01 \x01(\t\x12\x16\n\x0euse_versioning\x18\x03 \x01(\x08\"
|
14
|
+
descriptor_data = "\n$temporal/api/common/v1/message.proto\x12\x16temporal.api.common.v1\x1a\x1egoogle/protobuf/duration.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a\"temporal/api/enums/v1/common.proto\x1a&temporal/api/enums/v1/event_type.proto\x1a!temporal/api/enums/v1/reset.proto\"T\n\x08\x44\x61taBlob\x12:\n\rencoding_type\x18\x01 \x01(\x0e\x32#.temporal.api.enums.v1.EncodingType\x12\x0c\n\x04\x64\x61ta\x18\x02 \x01(\x0c\"=\n\x08Payloads\x12\x31\n\x08payloads\x18\x01 \x03(\x0b\x32\x1f.temporal.api.common.v1.Payload\"\x89\x01\n\x07Payload\x12?\n\x08metadata\x18\x01 \x03(\x0b\x32-.temporal.api.common.v1.Payload.MetadataEntry\x12\x0c\n\x04\x64\x61ta\x18\x02 \x01(\x0c\x1a/\n\rMetadataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\"\xbe\x01\n\x10SearchAttributes\x12S\n\x0eindexed_fields\x18\x01 \x03(\x0b\x32;.temporal.api.common.v1.SearchAttributes.IndexedFieldsEntry\x1aU\n\x12IndexedFieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\x90\x01\n\x04Memo\x12\x38\n\x06\x66ields\x18\x01 \x03(\x0b\x32(.temporal.api.common.v1.Memo.FieldsEntry\x1aN\n\x0b\x46ieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\x94\x01\n\x06Header\x12:\n\x06\x66ields\x18\x01 \x03(\x0b\x32*.temporal.api.common.v1.Header.FieldsEntry\x1aN\n\x0b\x46ieldsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"8\n\x11WorkflowExecution\x12\x13\n\x0bworkflow_id\x18\x01 \x01(\t\x12\x0e\n\x06run_id\x18\x02 \x01(\t\"\x1c\n\x0cWorkflowType\x12\x0c\n\x04name\x18\x01 \x01(\t\"\x1c\n\x0c\x41\x63tivityType\x12\x0c\n\x04name\x18\x01 \x01(\t\"\xd1\x01\n\x0bRetryPolicy\x12\x33\n\x10initial_interval\x18\x01 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x1b\n\x13\x62\x61\x63koff_coefficient\x18\x02 \x01(\x01\x12\x33\n\x10maximum_interval\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x18\n\x10maximum_attempts\x18\x04 \x01(\x05\x12!\n\x19non_retryable_error_types\x18\x05 \x03(\t\"F\n\x10MeteringMetadata\x12\x32\n*nonfirst_local_activity_execution_attempts\x18\r \x01(\r\">\n\x12WorkerVersionStamp\x12\x10\n\x08\x62uild_id\x18\x01 \x01(\t\x12\x16\n\x0euse_versioning\x18\x03 \x01(\x08\"e\n\x19WorkerVersionCapabilities\x12\x10\n\x08\x62uild_id\x18\x01 \x01(\t\x12\x16\n\x0euse_versioning\x18\x02 \x01(\x08\x12\x1e\n\x16\x64\x65ployment_series_name\x18\x04 \x01(\t\"\xe9\x02\n\x0cResetOptions\x12\x35\n\x13\x66irst_workflow_task\x18\x01 \x01(\x0b\x32\x16.google.protobuf.EmptyH\x00\x12\x34\n\x12last_workflow_task\x18\x02 \x01(\x0b\x32\x16.google.protobuf.EmptyH\x00\x12\x1a\n\x10workflow_task_id\x18\x03 \x01(\x03H\x00\x12\x12\n\x08\x62uild_id\x18\x04 \x01(\tH\x00\x12\x43\n\x12reset_reapply_type\x18\n \x01(\x0e\x32\'.temporal.api.enums.v1.ResetReapplyType\x12\x18\n\x10\x63urrent_run_only\x18\x0b \x01(\x08\x12S\n\x1breset_reapply_exclude_types\x18\x0c \x03(\x0e\x32..temporal.api.enums.v1.ResetReapplyExcludeTypeB\x08\n\x06target\"\xb7\x02\n\x08\x43\x61llback\x12\x37\n\x05nexus\x18\x02 \x01(\x0b\x32&.temporal.api.common.v1.Callback.NexusH\x00\x12=\n\x08internal\x18\x03 \x01(\x0b\x32).temporal.api.common.v1.Callback.InternalH\x00\x1a\x87\x01\n\x05Nexus\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\x42\n\x06header\x18\x02 \x03(\x0b\x32\x32.temporal.api.common.v1.Callback.Nexus.HeaderEntry\x1a-\n\x0bHeaderEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x1a\x18\n\x08Internal\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c\x42\t\n\x07variantJ\x04\x08\x01\x10\x02\"\xb0\x03\n\x04Link\x12\x44\n\x0eworkflow_event\x18\x01 \x01(\x0b\x32*.temporal.api.common.v1.Link.WorkflowEventH\x00\x12:\n\tbatch_job\x18\x02 \x01(\x0b\x32%.temporal.api.common.v1.Link.BatchJobH\x00\x1a\xfe\x01\n\rWorkflowEvent\x12\x11\n\tnamespace\x18\x01 \x01(\t\x12\x13\n\x0bworkflow_id\x18\x02 \x01(\t\x12\x0e\n\x06run_id\x18\x03 \x01(\t\x12N\n\tevent_ref\x18\x64 \x01(\x0b\x32\x39.temporal.api.common.v1.Link.WorkflowEvent.EventReferenceH\x00\x1aX\n\x0e\x45ventReference\x12\x10\n\x08\x65vent_id\x18\x01 \x01(\x03\x12\x34\n\nevent_type\x18\x02 \x01(\x0e\x32 .temporal.api.enums.v1.EventTypeB\x0b\n\treference\x1a\x1a\n\x08\x42\x61tchJob\x12\x0e\n\x06job_id\x18\x01 \x01(\tB\t\n\x07variant\" \n\x08Priority\x12\x14\n\x0cpriority_key\x18\x01 \x01(\x05\x42\x89\x01\n\x19io.temporal.api.common.v1B\x0cMessageProtoP\x01Z#go.temporal.io/api/common/v1;common\xaa\x02\x18Temporalio.Api.Common.V1\xea\x02\x1bTemporalio::Api::Common::V1b\x06proto3"
|
15
15
|
|
16
16
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
17
17
|
pool.add_serialized_file(descriptor_data)
|
@@ -41,6 +41,7 @@ module Temporalio
|
|
41
41
|
Link::WorkflowEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.common.v1.Link.WorkflowEvent").msgclass
|
42
42
|
Link::WorkflowEvent::EventReference = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.common.v1.Link.WorkflowEvent.EventReference").msgclass
|
43
43
|
Link::BatchJob = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.common.v1.Link.BatchJob").msgclass
|
44
|
+
Priority = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.common.v1.Priority").msgclass
|
44
45
|
end
|
45
46
|
end
|
46
47
|
end
|
@@ -0,0 +1,38 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: temporal/api/deployment/v1/message.proto
|
4
|
+
|
5
|
+
require 'google/protobuf'
|
6
|
+
|
7
|
+
require 'google/protobuf/timestamp_pb'
|
8
|
+
require 'temporalio/api/enums/v1/deployment'
|
9
|
+
require 'temporalio/api/enums/v1/task_queue'
|
10
|
+
require 'temporalio/api/common/v1/message'
|
11
|
+
|
12
|
+
|
13
|
+
descriptor_data = "\n(temporal/api/deployment/v1/message.proto\x12\x1atemporal.api.deployment.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a&temporal/api/enums/v1/deployment.proto\x1a&temporal/api/enums/v1/task_queue.proto\x1a$temporal/api/common/v1/message.proto\"\x91\x01\n\x17WorkerDeploymentOptions\x12\x17\n\x0f\x64\x65ployment_name\x18\x01 \x01(\t\x12\x10\n\x08\x62uild_id\x18\x02 \x01(\t\x12K\n\x16worker_versioning_mode\x18\x03 \x01(\x0e\x32+.temporal.api.enums.v1.WorkerVersioningMode\"3\n\nDeployment\x12\x13\n\x0bseries_name\x18\x01 \x01(\t\x12\x10\n\x08\x62uild_id\x18\x02 \x01(\t\"\x8e\x04\n\x0e\x44\x65ploymentInfo\x12:\n\ndeployment\x18\x01 \x01(\x0b\x32&.temporal.api.deployment.v1.Deployment\x12/\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12R\n\x10task_queue_infos\x18\x03 \x03(\x0b\x32\x38.temporal.api.deployment.v1.DeploymentInfo.TaskQueueInfo\x12J\n\x08metadata\x18\x04 \x03(\x0b\x32\x38.temporal.api.deployment.v1.DeploymentInfo.MetadataEntry\x12\x12\n\nis_current\x18\x05 \x01(\x08\x1aP\n\rMetadataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\x1a\x88\x01\n\rTaskQueueInfo\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x32\n\x04type\x18\x02 \x01(\x0e\x32$.temporal.api.enums.v1.TaskQueueType\x12\x35\n\x11\x66irst_poller_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"\xea\x01\n\x18UpdateDeploymentMetadata\x12_\n\x0eupsert_entries\x18\x01 \x03(\x0b\x32G.temporal.api.deployment.v1.UpdateDeploymentMetadata.UpsertEntriesEntry\x12\x16\n\x0eremove_entries\x18\x02 \x03(\t\x1aU\n\x12UpsertEntriesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\x95\x01\n\x12\x44\x65ploymentListInfo\x12:\n\ndeployment\x18\x01 \x01(\x0b\x32&.temporal.api.deployment.v1.Deployment\x12/\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x12\n\nis_current\x18\x03 \x01(\x08\"\x84\x05\n\x1bWorkerDeploymentVersionInfo\x12\x0f\n\x07version\x18\x01 \x01(\t\x12\x17\n\x0f\x64\x65ployment_name\x18\x02 \x01(\t\x12/\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x38\n\x14routing_changed_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x36\n\x12\x63urrent_since_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x36\n\x12ramping_since_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x17\n\x0framp_percentage\x18\x07 \x01(\x02\x12\x66\n\x10task_queue_infos\x18\x08 \x03(\x0b\x32L.temporal.api.deployment.v1.WorkerDeploymentVersionInfo.VersionTaskQueueInfo\x12\x46\n\rdrainage_info\x18\t \x01(\x0b\x32/.temporal.api.deployment.v1.VersionDrainageInfo\x12=\n\x08metadata\x18\n \x01(\x0b\x32+.temporal.api.deployment.v1.VersionMetadata\x1aX\n\x14VersionTaskQueueInfo\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x32\n\x04type\x18\x02 \x01(\x0e\x32$.temporal.api.enums.v1.TaskQueueType\"\xc1\x01\n\x13VersionDrainageInfo\x12<\n\x06status\x18\x01 \x01(\x0e\x32,.temporal.api.enums.v1.VersionDrainageStatus\x12\x35\n\x11last_changed_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x35\n\x11last_checked_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"\xd0\x03\n\x14WorkerDeploymentInfo\x12\x0c\n\x04name\x18\x01 \x01(\t\x12j\n\x11version_summaries\x18\x02 \x03(\x0b\x32O.temporal.api.deployment.v1.WorkerDeploymentInfo.WorkerDeploymentVersionSummary\x12/\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x41\n\x0erouting_config\x18\x04 \x01(\x0b\x32).temporal.api.deployment.v1.RoutingConfig\x12\x1e\n\x16last_modifier_identity\x18\x05 \x01(\t\x1a\xa9\x01\n\x1eWorkerDeploymentVersionSummary\x12\x0f\n\x07version\x18\x01 \x01(\t\x12/\n\x0b\x63reate_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x45\n\x0f\x64rainage_status\x18\x03 \x01(\x0e\x32,.temporal.api.enums.v1.VersionDrainageStatus\"\xad\x01\n\x0fVersionMetadata\x12I\n\x07\x65ntries\x18\x01 \x03(\x0b\x32\x38.temporal.api.deployment.v1.VersionMetadata.EntriesEntry\x1aO\n\x0c\x45ntriesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12.\n\x05value\x18\x02 \x01(\x0b\x32\x1f.temporal.api.common.v1.Payload:\x02\x38\x01\"\xb6\x02\n\rRoutingConfig\x12\x17\n\x0f\x63urrent_version\x18\x01 \x01(\t\x12\x17\n\x0framping_version\x18\x02 \x01(\t\x12\"\n\x1aramping_version_percentage\x18\x03 \x01(\x02\x12@\n\x1c\x63urrent_version_changed_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12@\n\x1cramping_version_changed_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12K\n\'ramping_version_percentage_changed_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x9d\x01\n\x1dio.temporal.api.deployment.v1B\x0cMessageProtoP\x01Z+go.temporal.io/api/deployment/v1;deployment\xaa\x02\x1cTemporalio.Api.Deployment.V1\xea\x02\x1fTemporalio::Api::Deployment::V1b\x06proto3"
|
14
|
+
|
15
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
16
|
+
pool.add_serialized_file(descriptor_data)
|
17
|
+
|
18
|
+
module Temporalio
|
19
|
+
module Api
|
20
|
+
module Deployment
|
21
|
+
module V1
|
22
|
+
WorkerDeploymentOptions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.WorkerDeploymentOptions").msgclass
|
23
|
+
Deployment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.Deployment").msgclass
|
24
|
+
DeploymentInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.DeploymentInfo").msgclass
|
25
|
+
DeploymentInfo::TaskQueueInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.DeploymentInfo.TaskQueueInfo").msgclass
|
26
|
+
UpdateDeploymentMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.UpdateDeploymentMetadata").msgclass
|
27
|
+
DeploymentListInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.DeploymentListInfo").msgclass
|
28
|
+
WorkerDeploymentVersionInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.WorkerDeploymentVersionInfo").msgclass
|
29
|
+
WorkerDeploymentVersionInfo::VersionTaskQueueInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.WorkerDeploymentVersionInfo.VersionTaskQueueInfo").msgclass
|
30
|
+
VersionDrainageInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.VersionDrainageInfo").msgclass
|
31
|
+
WorkerDeploymentInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.WorkerDeploymentInfo").msgclass
|
32
|
+
WorkerDeploymentInfo::WorkerDeploymentVersionSummary = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.WorkerDeploymentInfo.WorkerDeploymentVersionSummary").msgclass
|
33
|
+
VersionMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.VersionMetadata").msgclass
|
34
|
+
RoutingConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("temporal.api.deployment.v1.RoutingConfig").msgclass
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
@@ -5,7 +5,7 @@
|
|
5
5
|
require 'google/protobuf'
|
6
6
|
|
7
7
|
|
8
|
-
descriptor_data = "\n+temporal/api/enums/v1/batch_operation.proto\x12\x15temporal.api.enums.v1*\
|
8
|
+
descriptor_data = "\n+temporal/api/enums/v1/batch_operation.proto\x12\x15temporal.api.enums.v1*\x94\x02\n\x12\x42\x61tchOperationType\x12$\n BATCH_OPERATION_TYPE_UNSPECIFIED\x10\x00\x12\"\n\x1e\x42\x41TCH_OPERATION_TYPE_TERMINATE\x10\x01\x12\x1f\n\x1b\x42\x41TCH_OPERATION_TYPE_CANCEL\x10\x02\x12\x1f\n\x1b\x42\x41TCH_OPERATION_TYPE_SIGNAL\x10\x03\x12\x1f\n\x1b\x42\x41TCH_OPERATION_TYPE_DELETE\x10\x04\x12\x1e\n\x1a\x42\x41TCH_OPERATION_TYPE_RESET\x10\x05\x12\x31\n-BATCH_OPERATION_TYPE_UPDATE_EXECUTION_OPTIONS\x10\x06*\xa6\x01\n\x13\x42\x61tchOperationState\x12%\n!BATCH_OPERATION_STATE_UNSPECIFIED\x10\x00\x12!\n\x1d\x42\x41TCH_OPERATION_STATE_RUNNING\x10\x01\x12#\n\x1f\x42\x41TCH_OPERATION_STATE_COMPLETED\x10\x02\x12 \n\x1c\x42\x41TCH_OPERATION_STATE_FAILED\x10\x03\x42\x8b\x01\n\x18io.temporal.api.enums.v1B\x13\x42\x61tchOperationProtoP\x01Z!go.temporal.io/api/enums/v1;enums\xaa\x02\x17Temporalio.Api.Enums.V1\xea\x02\x1aTemporalio::Api::Enums::V1b\x06proto3"
|
9
9
|
|
10
10
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
11
11
|
pool.add_serialized_file(descriptor_data)
|
@@ -5,7 +5,7 @@
|
|
5
5
|
require 'google/protobuf'
|
6
6
|
|
7
7
|
|
8
|
-
descriptor_data = "\n\"temporal/api/enums/v1/common.proto\x12\x15temporal.api.enums.v1*_\n\x0c\x45ncodingType\x12\x1d\n\x19\x45NCODING_TYPE_UNSPECIFIED\x10\x00\x12\x18\n\x14\x45NCODING_TYPE_PROTO3\x10\x01\x12\x16\n\x12\x45NCODING_TYPE_JSON\x10\x02*\x91\x02\n\x10IndexedValueType\x12\"\n\x1eINDEXED_VALUE_TYPE_UNSPECIFIED\x10\x00\x12\x1b\n\x17INDEXED_VALUE_TYPE_TEXT\x10\x01\x12\x1e\n\x1aINDEXED_VALUE_TYPE_KEYWORD\x10\x02\x12\x1a\n\x16INDEXED_VALUE_TYPE_INT\x10\x03\x12\x1d\n\x19INDEXED_VALUE_TYPE_DOUBLE\x10\x04\x12\x1b\n\x17INDEXED_VALUE_TYPE_BOOL\x10\x05\x12\x1f\n\x1bINDEXED_VALUE_TYPE_DATETIME\x10\x06\x12#\n\x1fINDEXED_VALUE_TYPE_KEYWORD_LIST\x10\x07*^\n\x08Severity\x12\x18\n\x14SEVERITY_UNSPECIFIED\x10\x00\x12\x11\n\rSEVERITY_HIGH\x10\x01\x12\x13\n\x0fSEVERITY_MEDIUM\x10\x02\x12\x10\n\x0cSEVERITY_LOW\x10\x03*\
|
8
|
+
descriptor_data = "\n\"temporal/api/enums/v1/common.proto\x12\x15temporal.api.enums.v1*_\n\x0c\x45ncodingType\x12\x1d\n\x19\x45NCODING_TYPE_UNSPECIFIED\x10\x00\x12\x18\n\x14\x45NCODING_TYPE_PROTO3\x10\x01\x12\x16\n\x12\x45NCODING_TYPE_JSON\x10\x02*\x91\x02\n\x10IndexedValueType\x12\"\n\x1eINDEXED_VALUE_TYPE_UNSPECIFIED\x10\x00\x12\x1b\n\x17INDEXED_VALUE_TYPE_TEXT\x10\x01\x12\x1e\n\x1aINDEXED_VALUE_TYPE_KEYWORD\x10\x02\x12\x1a\n\x16INDEXED_VALUE_TYPE_INT\x10\x03\x12\x1d\n\x19INDEXED_VALUE_TYPE_DOUBLE\x10\x04\x12\x1b\n\x17INDEXED_VALUE_TYPE_BOOL\x10\x05\x12\x1f\n\x1bINDEXED_VALUE_TYPE_DATETIME\x10\x06\x12#\n\x1fINDEXED_VALUE_TYPE_KEYWORD_LIST\x10\x07*^\n\x08Severity\x12\x18\n\x14SEVERITY_UNSPECIFIED\x10\x00\x12\x11\n\rSEVERITY_HIGH\x10\x01\x12\x13\n\x0fSEVERITY_MEDIUM\x10\x02\x12\x10\n\x0cSEVERITY_LOW\x10\x03*\xde\x01\n\rCallbackState\x12\x1e\n\x1a\x43\x41LLBACK_STATE_UNSPECIFIED\x10\x00\x12\x1a\n\x16\x43\x41LLBACK_STATE_STANDBY\x10\x01\x12\x1c\n\x18\x43\x41LLBACK_STATE_SCHEDULED\x10\x02\x12\x1e\n\x1a\x43\x41LLBACK_STATE_BACKING_OFF\x10\x03\x12\x19\n\x15\x43\x41LLBACK_STATE_FAILED\x10\x04\x12\x1c\n\x18\x43\x41LLBACK_STATE_SUCCEEDED\x10\x05\x12\x1a\n\x16\x43\x41LLBACK_STATE_BLOCKED\x10\x06*\xfd\x01\n\x1aPendingNexusOperationState\x12-\n)PENDING_NEXUS_OPERATION_STATE_UNSPECIFIED\x10\x00\x12+\n\'PENDING_NEXUS_OPERATION_STATE_SCHEDULED\x10\x01\x12-\n)PENDING_NEXUS_OPERATION_STATE_BACKING_OFF\x10\x02\x12)\n%PENDING_NEXUS_OPERATION_STATE_STARTED\x10\x03\x12)\n%PENDING_NEXUS_OPERATION_STATE_BLOCKED\x10\x04*\xfe\x02\n\x1fNexusOperationCancellationState\x12\x32\n.NEXUS_OPERATION_CANCELLATION_STATE_UNSPECIFIED\x10\x00\x12\x30\n,NEXUS_OPERATION_CANCELLATION_STATE_SCHEDULED\x10\x01\x12\x32\n.NEXUS_OPERATION_CANCELLATION_STATE_BACKING_OFF\x10\x02\x12\x30\n,NEXUS_OPERATION_CANCELLATION_STATE_SUCCEEDED\x10\x03\x12-\n)NEXUS_OPERATION_CANCELLATION_STATE_FAILED\x10\x04\x12\x30\n,NEXUS_OPERATION_CANCELLATION_STATE_TIMED_OUT\x10\x05\x12.\n*NEXUS_OPERATION_CANCELLATION_STATE_BLOCKED\x10\x06\x42\x83\x01\n\x18io.temporal.api.enums.v1B\x0b\x43ommonProtoP\x01Z!go.temporal.io/api/enums/v1;enums\xaa\x02\x17Temporalio.Api.Enums.V1\xea\x02\x1aTemporalio::Api::Enums::V1b\x06proto3"
|
9
9
|
|
10
10
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
11
11
|
pool.add_serialized_file(descriptor_data)
|