Client
查看 MarkdownThis page lists the Rust SDK names for the Client. The doc comment of each API gives its parameters, defaults, and errors. Read them in the Rust SDK API reference.
API names
| Task | Rust API | Dex behavior |
|---|---|---|
| Create a Client | Client::try_new or Client::new, with Registry, BlobCache, and ClientOptions | Client requests |
| Start a Flow | start_flow, or start_flow_with_options with StartFlowOptions | Start a Flow |
| Invoke an RPC | invoke_rpc and invoke_rpc_without_input | Invoke an RPC |
| Read Attributes | get_attributes | Read Attributes |
| Wait for a Flow to close | wait_for_flow and wait_for_flow_with_timeout | Wait for a Flow |
| Wait for a Step execution to complete | wait_for_step_completion, with WaitForStepCompletionOptions | Wait for a Step |
| Wait until an Attribute matches | wait_for_attribute_match and wait_for_attribute_map_instance_match, with WaitForAttributeOptions | Wait for an Attribute match |
| Describe a Flow | describe_flow | Describe a Flow |
| Search Flows | search_flows, search_flows_page, and search_flows_with_options | Search Flows |
| Stop a Flow | stop_flow, with StopFlowOptions | Stop a Flow |
| Skip a Timer | skip_timer | Skip a Timer |
| Update FlowConfig | update_flow_config | Update FlowConfig |
| Write and read a Stream | write_stream, read_stream, and list_stream_messages | Stream |
| Upload Flow definitions | upload_flow_definitions, with FlowDefinitionDocument; returns FlowDefinitionUploadResult values. Since 1.45.0 | Flow definitions |
| Time travel a Flow | time_travel, with TimeTravelOptions | Time travel |
| Handle a failed request | SdkError, with ServiceError and ErrorSubStatus | Client requests |
Every Client method blocks the calling thread. An internal Tokio runtime performs the requests.
Example
Example: examples/rust/src/primitives/client_apis/controller.rs