Documentation
¶
Overview ¶
Package temporalclient provides functions to create and manage Temporal clients. It includes utilities for connecting to Temporal servers with default or custom namespaces.
Index ¶
- func ClearTestClients()
- func ConfigureLogger(l tlog.Logger)
- func Describe(ctx context.Context, c Describer, workflowID, runID string) (*workflowservice.DescribeWorkflowExecutionResponse, error)
- func Description(resp *workflowservice.DescribeWorkflowExecutionResponse) *client.WorkflowExecutionDescription
- func GetTemporalClientWithNamespace(namespace string) (client.Client, error)
- func NewNamespaceClient() (client.NamespaceClient, error)
- func SetClientForTests(namespace string, c client.Client)
- func ShutdownClients()
- type Describer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigureLogger ¶
ConfigureLogger sets the logger used by Temporal clients created after the call.
func Describe ¶ added in v1.334.3
func Describe( ctx context.Context, c Describer, workflowID, runID string, ) (*workflowservice.DescribeWorkflowExecutionResponse, error)
Describe returns the server's full description of a workflow run.
func Description ¶ added in v1.334.3
func Description( resp *workflowservice.DescribeWorkflowExecutionResponse, ) *client.WorkflowExecutionDescription
Description wraps a raw describe response as DescribeWorkflow returns it.
func GetTemporalClientWithNamespace ¶
GetTemporalClientWithNamespace returns the shared cached Temporal client for the namespace. Callers must not close the returned client; its lifecycle is managed by this package and ShutdownClients.
func NewNamespaceClient ¶
func NewNamespaceClient() (client.NamespaceClient, error)
NewNamespaceClient returns a new Temporal namespace client for TEMPORAL_ADDRESS. Callers own the returned client and must close it.
func SetClientForTests ¶
SetClientForTests injects a client into the cache for unit tests.
func ShutdownClients ¶
func ShutdownClients()