Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Engine Engine `yaml:"engine"`
Handlers *HandlerMap `yaml:"handlers"`
}
func (*Config) ParseFromYaml ¶
func (*Config) ParseFromYamlFile ¶
type Engine ¶
type FilterHandler ¶
type FilterHandler struct {
ExpectFalse bool `yaml:"expect_false"`
Expression string `yaml:"expression"`
}
func (FilterHandler) Validate ¶
func (h FilterHandler) Validate() error
type HTTPHandler ¶
type HTTPHandler struct {
URL string `yaml:"url"`
Method string `yaml:"method"`
Body string `yaml:"body"`
Headers map[string]string `yaml:"headers"`
QueryParams map[string]string `yaml:"query_params"`
Timeout time.Duration `yaml:"timeout"`
ExpectedResponseCode int `yaml:"expected_response_code"`
Retries int `yaml:"retries"`
RetryInterval time.Duration `yaml:"retry_interval"`
ParallelRun bool `yaml:"parallel_run"`
}
func (HTTPHandler) Validate ¶
func (h HTTPHandler) Validate() error
type Handler ¶
type Handler struct {
Type HandlerType `yaml:"type"`
HTTPHandler HTTPHandler `yaml:"http"`
FilterHandler FilterHandler `yaml:"filter"`
}
type HandlerMap ¶
type HandlerMap []HandlerMapItem
HandlerMap is a list of HandlerMapItem. It is used to guarantee the order of the handlers.
func (*HandlerMap) UnmarshalYAML ¶
func (hm *HandlerMap) UnmarshalYAML(node *yaml.Node) error
type HandlerMapItem ¶
type HandlerType ¶
type HandlerType string
const ( HandlerTypeHTTP HandlerType = "http" HandlerTypeFilter HandlerType = "filter" )
Click to show internal directories.
Click to hide internal directories.