util

package
v1.12.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2026 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AutoHeartbeat

func AutoHeartbeat(ctx context.Context)

AutoHeartbeat sends activity heartbeats in a loop until the activity completes. It is meant to be run in a background goroutine. Example usage:

func MyActivity(ctx context.Context) error {
    go AutoHeartbeat(ctx)
    // ...
    return nil
}

func NewClient

func NewClient(deploymentName, buildID, temporalNamespace string, metricsPort int) (c client.Client, stopFunc func())

func NewHTTPClient

func NewHTTPClient(minDelay, maxDelay time.Duration) *http.Client

NewHTTPClient creates an HTTP client with random network delays uniformly distributed in [minDelay, maxDelay).

func NewVersionedWorker

func NewVersionedWorker(opts worker.Options) (w worker.Worker, stopFunc func())

func SetActivityTimeout

func SetActivityTimeout(ctx workflow.Context, startToClose time.Duration) workflow.Context

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL