Skip to main content

Interface: NexusSerializationContext

Experimental

Context provided to data converters for payloads of a Nexus operation.

Callers receive this context when encoding inputs and decoding results or failures. Handlers receive it when decoding inputs, encoding synchronous results, and encoding failures raised while handling a Nexus task.

Workflows and standalone Activities started by a handler, and Workflow Updates it sends, receive this context through the server and use it for the payloads returned to the caller: results, failures, and standalone Activity heartbeat details. Clients decode these with the context the server returns. See ActivityInfo.nexusSerializationContext for asynchronous Activity completion.

A standalone operation handle decodes with the context the server returns, falling back to the context of its start request on older servers.

A failure encoded by a handler is later decoded by a caller, and some operation paths lack this context entirely. Contextual encodings must therefore be self-describing, and decoders must keep accepting payloads encoded without context.

Nexus serialization context is an experimental feature and may change.

Properties​

endpoint​

endpoint: string

Experimental

Nexus endpoint name.


operation​

operation: string

Experimental

Nexus operation name.


service​

service: string

Experimental

Nexus service name.


type​

type: "nexus"

Experimental

Always 'nexus' for Nexus operation payloads.