Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrInvalidType invalid transaction type ErrInvalidType = errors.New("invalid transaction type") // ErrTransactionNotFound transaction not found ErrTransactionNotFound = errors.New("transaction not found") )
Functions ¶
Types ¶
type CallBackConfig ¶
type CallBackConfig struct {
Type string `json:"type" yaml:"type"`
Script string `json:"script" yaml:"script"`
}
CallBackConfig configuration for receiving async transaction responses
type Config ¶
type Config struct {
Name string `json:"name" yaml:"name"`
Type string `json:"type" yaml:"type"`
Schedule string `json:"schedule" yaml:"schedule"`
Timeout string `json:"timeout" yaml:"timeout"`
RetryCount int `json:"retry_count" yaml:"retry_count"`
Script string `json:"script" yaml:"script"`
CallBack *CallBackConfig `json:"callback" yaml:"callback"`
Inputs map[string]interface{} `json:"inputs" yaml:"inputs"`
Metadata map[string]string `json:"metadata" yaml:"metadata"`
}
Config is a synthetic test definition
type Result ¶
type Result struct {
Name string `json:"name" yaml:"name"`
Type string `json:"type" yaml:"type"`
Failed bool `json:"failed" yaml:"failed"`
Message string `json:"message" yaml:"message"`
Data string `json:"data" yaml:"data"`
Time time.Time `json:"time" yaml:"time"`
Error error `json:"-" yaml:"-"`
Metadata map[string]string `json:"metadata" yaml:"metadata"`
RetryCount int `json:"retry_count" yaml:"retry_count"`
WithCallback bool `json:"with_callback" yaml:"with_callback"`
DurationSeconds float64 `json:"duration_seconds" yaml:"duration_seconds"`
}
Result represents a transaction execution result
func (*Result) MarshalJSON ¶ added in v0.0.2
MarshalJSON is custom marshaler for result
func (*Result) UnmarshalJSON ¶ added in v0.0.2
UnmarshalJSON is custom unmarshaler for result
Click to show internal directories.
Click to hide internal directories.