Documentation
¶
Index ¶
- Constants
- type AppError
- type ClientError
- func (e ClientError) Error() string
- func (e ClientError) ErrorCategory() ErrorCategory
- func (e ClientError) ErrorDetails() string
- func (e ClientError) ErrorType() ErrorType
- func (e ClientError) ReturnCode() int
- func (e ClientError) Severity() ErrorSeverity
- func (e ClientError) Source() ErrorSource
- func (e ClientError) Unwrap() error
- type Credentials
- type CustomerError
- func (e CustomerError) Error() string
- func (e CustomerError) ErrorCategory() ErrorCategory
- func (e CustomerError) ErrorDetails() string
- func (e CustomerError) ErrorType() ErrorType
- func (e CustomerError) ReturnCode() int
- func (e CustomerError) Severity() ErrorSeverity
- func (e CustomerError) Source() ErrorSource
- func (e CustomerError) Unwrap() error
- type ErrorCategory
- type ErrorOption
- type ErrorSeverity
- type ErrorSource
- type ErrorType
- type ExtensionsExec
- type ExternalAgents
- type FunctionError
- type FunctionMetadata
- type PlatformError
- func (e PlatformError) Error() string
- func (e PlatformError) ErrorCategory() ErrorCategory
- func (e PlatformError) ErrorDetails() string
- func (e PlatformError) ErrorType() ErrorType
- func (e PlatformError) ReturnCode() int
- func (e PlatformError) Severity() ErrorSeverity
- func (e PlatformError) Source() ErrorSource
- func (e PlatformError) Unwrap() error
- type Runtime
- type RuntimeExec
- type RuntimeExecError
- type RuntimeExecErrorType
- type RuntimeInfo
- type RuntimeNextWaiter
Constants ¶
View Source
const ( ErrorReasonUnknownError ErrorType = "UnknownError" ErrorCategoryReasonUnknown ErrorCategory = "Fatal.Sandbox" ErrorCategoryClientCaused ErrorCategory = "Invalid.Client" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppError ¶
type AppError interface {
error
Severity() ErrorSeverity
Source() ErrorSource
ErrorCategory() ErrorCategory
ErrorType() ErrorType
Unwrap() error
ReturnCode() int
ErrorDetails() string
}
type ClientError ¶
type ClientError struct {
// contains filtered or unexported fields
}
func NewClientError ¶
func NewClientError(cause error, severity ErrorSeverity, errorType ErrorType) ClientError
func (ClientError) ErrorCategory ¶
func (e ClientError) ErrorCategory() ErrorCategory
func (ClientError) ErrorDetails ¶
func (e ClientError) ErrorDetails() string
func (ClientError) ReturnCode ¶
func (e ClientError) ReturnCode() int
func (ClientError) Severity ¶
func (e ClientError) Severity() ErrorSeverity
func (ClientError) Source ¶
func (e ClientError) Source() ErrorSource
type Credentials ¶
type CustomerError ¶
type CustomerError struct {
// contains filtered or unexported fields
}
func NewCustomerError ¶
func NewCustomerError(errorType ErrorType, opts ...ErrorOption) CustomerError
func WrapErrorIntoCustomerFatalError ¶
func WrapErrorIntoCustomerFatalError(e error, errorType ErrorType) CustomerError
func WrapErrorIntoCustomerInvalidError ¶
func WrapErrorIntoCustomerInvalidError(e error, errorType ErrorType) CustomerError
func (CustomerError) ErrorCategory ¶
func (e CustomerError) ErrorCategory() ErrorCategory
func (CustomerError) ErrorDetails ¶
func (e CustomerError) ErrorDetails() string
func (CustomerError) ReturnCode ¶
func (e CustomerError) ReturnCode() int
func (CustomerError) Severity ¶
func (e CustomerError) Severity() ErrorSeverity
func (CustomerError) Source ¶
func (e CustomerError) Source() ErrorSource
type ErrorCategory ¶
type ErrorCategory string
func (ErrorCategory) String ¶
func (e ErrorCategory) String() string
type ErrorOption ¶
type ErrorOption func(err *appError)
func WithCause ¶
func WithCause(cause error) ErrorOption
func WithErrorMessage ¶
func WithErrorMessage(msg string) ErrorOption
func WithSeverity ¶
func WithSeverity(sev ErrorSeverity) ErrorOption
type ErrorSeverity ¶
type ErrorSeverity string
const ( ErrorSeverityError ErrorSeverity = "Error" ErrorSeverityFatal ErrorSeverity = "Fatal" ErrorSeverityInvalid ErrorSeverity = "Invalid" )
type ErrorSource ¶
type ErrorSource string
const ( ErrorSourceClient ErrorSource = "Client" ErrorSourceSandbox ErrorSource = "Sandbox" ErrorSourceRuntime ErrorSource = "Runtime" )
type ErrorType ¶
type ErrorType string
const ( ErrorInvalidRequest ErrorType = "InvalidRequest" ErrorMalformedRequest ErrorType = "ErrMalformedRequest" ErrorInitIncomplete ErrorType = "Client.InitIncomplete" ErrorEnvironmentUnhealthy ErrorType = "Client.ExecutionEnvironmentUnhealthy" ErrorDublicatedInvokeId ErrorType = "Client.DuplicatedInvokeId" ErrorInvalidFunctionVersion ErrorType = "ErrInvalidFunctionVersion" ErrorInvalidMaxPayloadSize ErrorType = "ErrInvalidMaxPayloadSize" ErrorInvalidResponseBandwidthRate ErrorType = "ErrInvalidResponseBandwidthRate" ErrorInvalidResponseBandwidthBurstSize ErrorType = "ErrInvalidResponseBandwidthBurstSize" ErrorExecutionEnvironmentShutdown ErrorType = "Client.ExecutionEnvironmentShutDown" )
const ( ErrorAgentPermissionDenied ErrorType = "PermissionDenied" ErrorAgentExtensionLaunch ErrorType = "Extension.LaunchError" ErrorAgentTooManyExtensions ErrorType = "TooManyExtensions" ErrorAgentInit ErrorType = "Extension.InitError" ErrorAgentExit ErrorType = "Extension.ExitError" ErrorAgentCrash ErrorType = "Extension.Crash" ErrorAgentUnknown ErrorType = "Unknown" ErrorRuntimeInit ErrorType = "Runtime.InitError" ErrorRuntimeInvalidWorkingDir ErrorType = "Runtime.InvalidWorkingDir" ErrorRuntimeInvalidEntryPoint ErrorType = "Runtime.InvalidEntrypoint" ErrorRuntimeExit ErrorType = "Runtime.ExitError" ErrorRuntimeUnknown ErrorType = "Runtime.Unknown" ErrorRuntimeOutOfMemory ErrorType = "Runtime.OutOfMemory" ErrorRuntimeTruncatedResponse ErrorType = "Runtime.TruncatedResponse" ErrorRuntimeInvalidResponseModeHeader ErrorType = "Runtime.InvalidResponseModeHeader" ErrorRuntimeInvokeResponseInProgress ErrorType = "Runtime.InvokeResponseInProgress" ErrorRuntimeInvokeErrorInProgress ErrorType = "Runtime.ErrorResponseInProgress" ErrorRuntimeInvokeResponseWasSent ErrorType = "Runtime.InvokeResponseWasSent" ErrorRuntimeInvalidInvokeId ErrorType = "Runtime.InvalidInvokeId" ErrorRuntimeInvokeTimeout ErrorType = "Runtime.InvokeTimeout" ErrorRuntimeTooManyIdleRuntimes ErrorType = "Runtime.TooManyIdleRuntimes" ErrorSandboxTimedout ErrorType = "Sandbox.Timedout" ErrorSandboxFailure ErrorType = "Sandbox.Failure" ErrorSandboxTimeoutResponseTrailer ErrorType = "Sandbox.TimeoutResponseTrailer" ErrorFunctionOversizedResponse ErrorType = "Function.ResponseSizeTooLarge" ErrorFunctionUnknown ErrorType = "Function.Unknown" )
const ( ErrorReasonExtensionExecFailed ErrorType = "ExtensionExecFailure" ErrorAgentCountRegistrationFailed ErrorType = "Extension.CountRegistrationFailed" ErrorAgentExtensionCreationFailed ErrorType = "Extension.CreationFailed" ErrorAgentRegistrationFailed ErrorType = "Extension.RegistrationFailed" ErrorAgentReadyFailed ErrorType = "Extension.ReadyFailed" ErrorAgentGateCreationFailed ErrorType = "Extension.GateCreationFailed" ErrorReasonRuntimeExecFailed ErrorType = "RuntimeExecFailure" ErrorRuntimeReadyFailed ErrorType = "Runtime.ReadyFailed" ErrorRuntimeRegistrationFailed ErrorType = "Runtime.RegistrationFailed" ErrSandboxEventSetupFailure ErrorType = "Sandbox.EventSetupFailure" ErrSandboxShutdownFailed ErrorType = "Sandbox.ShutdownFailed" )
type ExtensionsExec ¶
type ExternalAgents ¶
type ExternalAgents struct {
Bootstraps []string
ExecConfig ExtensionsExec
}
type FunctionError ¶
type FunctionMetadata ¶
type PlatformError ¶
type PlatformError struct {
// contains filtered or unexported fields
}
func NewPlatformError ¶
func NewPlatformError(cause error, errorType ErrorType) PlatformError
func WrapErrorIntoPlatformFatalError ¶
func WrapErrorIntoPlatformFatalError(e error, errorType ErrorType) PlatformError
func (PlatformError) ErrorCategory ¶
func (e PlatformError) ErrorCategory() ErrorCategory
func (PlatformError) ErrorDetails ¶
func (e PlatformError) ErrorDetails() string
func (PlatformError) ReturnCode ¶
func (e PlatformError) ReturnCode() int
func (PlatformError) Severity ¶
func (e PlatformError) Severity() ErrorSeverity
func (PlatformError) Source ¶
func (e PlatformError) Source() ErrorSource
type Runtime ¶
type Runtime struct {
ExecConfig RuntimeExec
ConfigError *RuntimeExecError
}
type RuntimeExecError ¶
type RuntimeExecError struct {
Type RuntimeExecErrorType
Err error
}
type RuntimeExecErrorType ¶
type RuntimeExecErrorType int
const ( InvalidTaskConfig RuntimeExecErrorType = iota InvalidEntrypoint InvalidWorkingDir )
func (RuntimeExecErrorType) FatalErrorType ¶
func (e RuntimeExecErrorType) FatalErrorType() ErrorType
type RuntimeInfo ¶
type RuntimeNextWaiter ¶
Click to show internal directories.
Click to hide internal directories.