PubSubInterceptorContext
PubSubInterceptorContext =
object& {operation:"publish";request:PublishRequest; } | {delivery:Delivery;operation:"handle"; } | {event:PubSubTransportEvent;operation:"scheduled"; } | {event:PubSubTransportEvent;operation:"retried"; } | {event:PubSubTransportEvent;operation:"retryExhausted"; } | {event:PubSubTransportEvent;operation:"deadLettered"; } | {event:PubSubTransportEvent;operation:"recovered"; } | {event:PubSubTransportEvent;operation:"delivered"; } | {event:PubSubTransportEvent;operation:"tombstoned"; } | {event:PubSubTransportEvent;operation:"committed"; } | {event:PubSubTransportFailureEvent;operation:"deliveryFailed"; } | {event:PubSubTransportFailureEvent;operation:"parseFailed"; }
Defined in: packages/pubsub/src/types.ts:214
Context passed to each PubSubInterceptor in the chain.
This is a discriminated union keyed on operation. Narrowing on
ctx.operation gives access to the operation-specific fields.
publish and handle wrap user-facing operations where interceptor errors
propagate. All other operations are transport lifecycle notifications where
interceptor errors are caught to avoid breaking delivery flow.
Type Declaration
Section titled “Type Declaration”contextValues?
Section titled “contextValues?”
optionalcontextValues?:ContextValues
Context values passed through the interceptor chain and to nested operations.