fault

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package fault holds the fault-injection points that tests use to crash, delay or fail the gateway at exact places.

The points act only in binaries built with the faultinject tag and are chosen by environment variables; without the tag every point is a no-op, so a shipped binary has no way to trigger one. The package imports no other internal package. Any gateway package may call it; nothing outside tests may depend on a point having an effect.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CancelPoint

func CancelPoint(context.Context, string)

func CandidateReadFault

func CandidateReadFault() error

func CrashPoint

func CrashPoint(string)

func RateClockFault

func RateClockFault() (int64, bool)

func RollbackFault

func RollbackFault() error

func SignalCapture

func SignalCapture(string, string)

func TimerFault

func TimerFault() bool

func WallOffset

func WallOffset() time.Duration

func WriteAudit

func WriteAudit(file *os.File, data []byte) error

WriteAudit appends data and syncs it to disk.

Types

This section is empty.

Jump to

Keyboard shortcuts

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