Documentation
¶
Overview ¶
Package common contains common utilities that are shared among other packages.
Index ¶
Constants ¶
View Source
const ShowErrorDetailsEnv = "XRAYR_SHOW_ERROR_DETAILS"
Variables ¶
This section is empty.
Functions ¶
func SafeCompileRegex ¶
SafeCompileRegex compiles a regex pattern with safety checks against catastrophic backtracking (ReDoS). It validates the parsed syntax tree depth and rejects overly long patterns.
func SetShowErrorDetails ¶
func SetShowErrorDetails(enabled bool)
func ShowErrorDetails ¶
func ShowErrorDetails() bool
Types ¶
type ManagedPeriodic ¶
type ManagedPeriodic struct {
Interval time.Duration
Execute func() error
// contains filtered or unexported fields
}
ManagedPeriodic runs Execute immediately on Start, then waits Interval after each successful callback, and waits for an in-flight callback when closed.
func (*ManagedPeriodic) Close ¶
func (p *ManagedPeriodic) Close() error
func (*ManagedPeriodic) Start ¶
func (p *ManagedPeriodic) Start() error
func (*ManagedPeriodic) Stop ¶
func (p *ManagedPeriodic) Stop() error
func (*ManagedPeriodic) Wait ¶
func (p *ManagedPeriodic) Wait() error
Directories
¶
| Path | Synopsis |
|---|---|
|
Package limiter is to control the links that go into the dispatcher
|
Package limiter is to control the links that go into the dispatcher |
|
Package rule controls audit-rule matching and result draining.
|
Package rule controls audit-rule matching and result draining. |
Click to show internal directories.
Click to hide internal directories.