Class: Temporalio::Workflow::NexusClient
- Inherits:
-
Object
- Object
- Temporalio::Workflow::NexusClient
- Defined in:
- lib/temporalio/workflow/nexus_client.rb
Overview
Client for executing Nexus operations from workflows.
This is created via create_nexus_client, it is never instantiated directly.
WARNING: Nexus support is experimental.
Direct Known Subclasses
Instance Method Summary collapse
-
#endpoint ⇒ String
Endpoint name for this client.
-
#execute_operation(operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil) ⇒ Object
Execute a Nexus operation and wait for the result.
-
#service ⇒ String
Service name for this client.
-
#start_operation(operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil) ⇒ NexusOperationHandle
Start a Nexus operation and return a handle.
Instance Method Details
#endpoint ⇒ String
Returns Endpoint name for this client.
17 18 19 |
# File 'lib/temporalio/workflow/nexus_client.rb', line 17 def endpoint raise NotImplementedError end |
#execute_operation(operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil) ⇒ Object
Execute a Nexus operation and wait for the result.
This is a convenience method that calls #start_operation and immediately waits for the result.
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/temporalio/workflow/nexus_client.rb', line 64 def execute_operation( operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil ) start_operation( operation, arg, schedule_to_close_timeout:, cancellation_type:, summary:, cancellation:, arg_hint:, result_hint: ).result end |
#service ⇒ String
Returns Service name for this client.
22 23 24 |
# File 'lib/temporalio/workflow/nexus_client.rb', line 22 def service raise NotImplementedError end |
#start_operation(operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil) ⇒ NexusOperationHandle
Start a Nexus operation and return a handle.
37 38 39 40 41 42 43 44 45 46 47 48 |
# File 'lib/temporalio/workflow/nexus_client.rb', line 37 def start_operation( operation, arg, schedule_to_close_timeout: nil, cancellation_type: NexusOperationCancellationType::WAIT_CANCELLATION_COMPLETED, summary: nil, cancellation: Workflow.cancellation, arg_hint: nil, result_hint: nil ) raise NotImplementedError end |