Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTTPFilter ¶
type HTTPFilter struct {
// contains filtered or unexported fields
}
HTTPFilter filters HTTP traffic.
func (*HTTPFilter) Filter ¶
func (hf *HTTPFilter) Filter(ctx context.HTTPContext) bool
Filter filters HTTPContext.
type Probability ¶
type Probability struct { PerMill uint32 `yaml:"perMill" jsonschema:"required,minimum=1,maximum=1000"` Policy string `yaml:"policy" jsonschema:"required,enum=ipHash,enum=headerHash,enum=random"` HeaderHashKey string `yaml:"headerHashKey" jsonschema:"omitempty"` }
Probability filters HTTP traffic by probability.
type Spec ¶
type Spec struct { MatchAllHeaders bool `yaml:"matchAllHeaders" jsonschema:"omitempty"` Headers map[string]*urlrule.StringMatch `yaml:"headers" jsonschema:"omitempty"` URLs []*urlrule.URLRule `yaml:"urls" jsonschema:"omitempty"` Probability *Probability `yaml:"probability,omitempty" jsonschema:"omitempty"` }
Spec describes HTTPFilter.
Click to show internal directories.
Click to hide internal directories.