model

package
v0.0.0-...-4fa2157 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 2, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LambdaAgentIdentifier     string = "Lambda-Extension-Identifier"
	ErrAgentIdentifierMissing string = "Extension.MissingExtensionIdentifier"
	ErrAgentIdentifierInvalid string = "Extension.InvalidExtensionIdentifier"
)
View Source
const (
	XRaySampled    = "1"
	XRayNonSampled = "0"
)
View Source
const MaxErrorCauseSizeBytes = 64 << 10

Variables

This section is empty.

Functions

func ValidatedErrorCauseJSON

func ValidatedErrorCauseJSON(errorCauseJSON []byte) ([]byte, error)

Types

type AgentEvent

type AgentEvent struct {
	EventType  string `json:"eventType"`
	DeadlineMs int64  `json:"deadlineMs"`
}

type AgentInvokeEvent

type AgentInvokeEvent struct {
	*AgentEvent
	RequestID          string   `json:"requestId"`
	InvokedFunctionArn string   `json:"invokedFunctionArn"`
	Tracing            *Tracing `json:"tracing,omitempty"`
}

type AgentShutdownEvent

type AgentShutdownEvent struct {
	*AgentEvent
	ShutdownReason ShutdownReason `json:"shutdownReason"`
}

type CognitoIdentity

type CognitoIdentity struct {
	CognitoIdentityID     string `json:"cognitoIdentityId"`
	CognitoIdentityPoolID string `json:"cognitoIdentityPoolId"`
}

type CtxKey

type CtxKey int
const (
	AgentIDCtxKey CtxKey = iota
)

type ErrorCause

type ErrorCause struct {
	Exceptions []exception `json:"exceptions"`
	WorkingDir string      `json:"working_directory"`
	Paths      []string    `json:"paths"`
	Message    string      `json:"message,omitempty"`
}

type ErrorResponse

type ErrorResponse struct {
	ErrorMessage string   `json:"errorMessage"`
	ErrorType    string   `json:"errorType"`
	StackTrace   []string `json:"stackTrace,omitempty"`
}

type ExtensionRegisterResponse

type ExtensionRegisterResponse struct {
	AccountID       string `json:"accountId,omitempty"`
	FunctionName    string `json:"functionName"`
	FunctionVersion string `json:"functionVersion"`
	Handler         string `json:"handler"`
}

type ShutdownReason

type ShutdownReason string
const (
	Spindown ShutdownReason = "spindown"
	Failure  ShutdownReason = "failure"
)

type StatusResponse

type StatusResponse struct {
	Status string `json:"status"`
}

type Tracing

type Tracing struct {
	Type TracingType `json:"type"`
	XRayTracing
}

func NewXRayTracing

func NewXRayTracing(value string) *Tracing

type TracingType

type TracingType string
const (
	XRayTracingType TracingType = "X-Amzn-Trace-Id"
)

type XRayTracing

type XRayTracing struct {
	Value string `json:"value"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL