Skip to main content

Interface: ConnectionOptions

client.ConnectionOptions

gRPC and Temporal Server connection options

Properties

address

Optional address: string

Server hostname and optional port. Port defaults to 7233 if address contains only host.

Default

localhost:7233


channelArgs

Optional channelArgs: ChannelOptions

GRPC Channel arguments

See

option descriptions here


connectTimeout

Optional connectTimeout: string | number

Milliseconds to wait until establishing a connection with the server.

Used either when connecting eagerly with connect or calling ensureConnected.

Format

ms formatted string

Default

10 seconds


credentials

Optional credentials: ChannelCredentials

Channel credentials, create using the factory methods defined here

Either tls or this may be specified for configuring TLS


interceptors

Optional interceptors: Interceptor[]

Grpc interceptors which will be applied to every RPC call performed by this connection. By default, an interceptor will be included which automatically retries retryable errors. If you do not wish to perform automatic retries, set this to an empty list (or a list with your own interceptors).


metadata

Optional metadata: Metadata

Optional mapping of gRPC metadata (HTTP headers) to send with each request to the server.

In order to dynamically set metadata, use withMetadata


tls

Optional tls: null | boolean | TLSConfig

TLS configuration. Pass a falsy value to use a non-encrypted connection or true or {} to connect with TLS without any customization.

Either credentials or this may be specified for configuring TLS