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

Function parseClientContext

lambda/invoke_loop.go:150–158  ·  view source on GitHub ↗
(invoke *invoke, out *lambdacontext.ClientContext)

Source from the content-addressed store, hash-verified

148}
149
150func parseClientContext(invoke *invoke, out *lambdacontext.ClientContext) error {
151 clientContextJSON := invoke.headers.Get(headerClientContext)
152 if clientContextJSON != "" {
153 if err := json.Unmarshal([]byte(clientContextJSON), out); err != nil {
154 return fmt.Errorf("failed to unmarshal client context json: %v", err)
155 }
156 }
157 return nil
158}
159
160func safeMarshal(v interface{}) []byte {
161 payload, err := json.Marshal(v)

Callers 1

handleInvokeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…