MCPcopy Index your code
hub / github.com/aws/aws-lambda-go / WithContext

Function WithContext

lambda/handler.go:41–45  ·  view source on GitHub ↗

WithContext is a HandlerOption that sets the base context for all invocations of the handler.

(ctx context.Context)

Source from the content-addressed store, hash-verified

39
40// WithContext is a HandlerOption that sets the base context for all invocations of the handler.
41func WithContext(ctx context.Context) Option {
42 return Option(func(h *handlerOptions) {
43 h.baseContext = ctx
44 })
45}
46
47// WithContextValue adds a value to the handler context.
48// If a base context was set using WithContext, that base is used as the parent.

Callers 3

ExampleWithContextFunction · 0.92
StartWithContextFunction · 0.85
StartHandlerWithContextFunction · 0.85

Calls 1

OptionFuncType · 0.85

Tested by 1

ExampleWithContextFunction · 0.74

Used in the wild real call sites across dependent graphs

searching dependent graphs…