Documentation ¶
Index ¶
- Constants
- Variables
- type NPMError
- func ConvertToNPMError(operationFlag string, err error, cmd []string) *NPMError
- func Error(operation string, isRetriable bool, err error) *NPMError
- func ErrorWrapper(operation string, isRetriable bool, errstring string, err error) *NPMError
- func Errorf(operation string, isRetriable bool, errstring string) *NPMError
- type NPMSimpleError
Constants ¶
View Source
const ( InitializeDataPlane = "InitializeDataPlane" BootupDataplane = "BootupDataplane" BootupPolicyMgr = "BootupPolicyManager" ResetIPSets = "ResetIPSets" CreateIPSet = "CreateIPSet" AppendIPSet = "AppendIPSet" DeleteIPSet = "DeleteIPSet" DestroyIPSet = "DestroyIPSet" TestIPSet = "TestIPSet" IPSetIntersection = "IPSetIntersection" AddPolicy = "AddNetworkPolicy" RemovePolicy = "RemovePolicy" GetSelectorReference = "GetSelectorReference" AddSelectorReference = "AddSelectorReference" DeleteSelectorReference = "DeleteSelectorReference" AddNetPolReference = "AddNetPolReference" DeleteNetPolReference = "DeleteNetPolReference" RunFileCreator = "RunCommandWithFile" AddPod = "AddPod" )
Error labels for ipsetmanager
View Source
const ( SetCannotBeDestroyedInUseByKernelComponent = 1 ElemSeperatorNotSupported = 2 SetWithGivenNameDoesNotExist = 3 SecondElementIsMissing = 4 MissingSecondMandatoryArgument = 5 MaximalNumberOfSetsReached = 6 IPSetWithGivenNameAlreadyExists = 7 SetToBeAddedDeletedTestedDoesNotExist = 8 Unknown = 999 )
Error codes for ipsetmanager
Variables ¶
View Source
var ( // ErrSrcNotSpecified thrown during NPM debug cli mode when the source packet is not specified ErrSrcNotSpecified = errors.New("source not specified") // ErrDstNotSpecified thrown during NPM debug cli mode when the source packet is not specified ErrDstNotSpecified = errors.New("destination not specified") )
Functions ¶
This section is empty.
Types ¶
type NPMError ¶
type NPMError struct { OperationAction string IsRetriable bool FullCmd []string ErrID int Err error }
func ConvertToNPMError ¶
func ErrorWrapper ¶
type NPMSimpleError ¶
type NPMSimpleError struct {
Err error
}
NPMSimpleError and its methods are used to appease go lint
func SimpleError ¶
func SimpleError(errstring string) *NPMSimpleError
func SimpleErrorWrapper ¶
func SimpleErrorWrapper(errstring string, err error) *NPMSimpleError
func (*NPMSimpleError) Error ¶
func (n *NPMSimpleError) Error() string
Click to show internal directories.
Click to hide internal directories.