Documentation
¶
Overview ¶
A very simple fault injection tool.
Index ¶
- Constants
- func AddFaultPoint(ctx context.Context, name string, freq string, action string, iarg int64, ...) error
- func AddFaultPointInDomain(ctx context.Context, domain Domain, name string, freq string, action string, ...) error
- func Disable() bool
- func DisableDomain(domain Domain) bool
- func Enable() bool
- func EnableDomain(domain Domain) bool
- func HandleFaultInject(ctx context.Context, name string, parameter string) (res string)
- func ListAllFaultPoints() string
- func ListAllFaultPointsInDomain(domain Domain) string
- func RemoveFaultPoint(ctx context.Context, name string) (bool, error)
- func RemoveFaultPointFromDomain(ctx context.Context, domain Domain, name string) (bool, error)
- func Status() bool
- func StatusOfDomain(domain Domain) bool
- func TriggerFault(name string) (iret int64, sret string, exist bool)
- func TriggerFaultInDomain(domain Domain, name string) (iret int64, sret string, exist bool)
- type Domain
- type Point
Constants ¶
View Source
const ( STOP = iota LOOKUP ADD REMOVE TRIGGER LIST )
View Source
const ( RETURN = iota GETCOUNT SLEEP WAIT GETWAITERS NOTIFY NOTIFYALL PANIC ECHO )
View Source
const ( // PANIC with non-moerr PanicUseNonMoErr = 0 // PANIC with moerr.NewXXXErr PanicUseMoErr = 1 )
View Source
const ( EnableFault = "ENABLE_FAULT_INJECTION" DisableFault = "DISABLE_FAULT_INJECTION" StatusFault = "STATUS_FAULT_POINT" ListFault = "LIST_FAULT_POINT" AddFault = "ADD_FAULT_POINT" RemoveFault = "REMOVE_FAULT_POINT" )
Variables ¶
This section is empty.
Functions ¶
func AddFaultPoint ¶
func AddFaultPointInDomain ¶
func DisableDomain ¶
func EnableDomain ¶
func HandleFaultInject ¶
func ListAllFaultPoints ¶
func ListAllFaultPoints() string
func StatusOfDomain ¶
func TriggerFault ¶
Trigger a fault point.
Types ¶
Click to show internal directories.
Click to hide internal directories.