Documentation ¶
Index ¶
- Constants
- func CopyFileTo(dir string, srcPath string) error
- func DirOrFileExists(path string) bool
- func JsonToYaml(j []byte, spaces int) ([]byte, error)
- func MkdirAllTargetOrDefault(workingDir, targetDir, defaultDir string) (string, error)
- func NewIOLogger(stdOut io.Writer, stdErr io.Writer) logr.Logger
- type CLISettings
- type Config
- type Environment
- type FileMarshaler
- type Flow
- type Generatable
- type Generatables
- type GetFlow
- type IOLogger
- func (l *IOLogger) Enabled() bool
- func (l *IOLogger) Error(err error, msg string, keysAndValues ...interface{})
- func (l *IOLogger) Info(msg string, keysAndValues ...interface{})
- func (l *IOLogger) V(_ int) logr.Logger
- func (l *IOLogger) WithName(_ string) logr.Logger
- func (l *IOLogger) WithValues(keysAndValues ...interface{}) logr.Logger
- type Kustomization
- type Phase
- type Scenario
- type StatusCode
- type TelemetryCLISettings
- type TestScript
Constants ¶
View Source
const DefaultManifestDir = "artillery-manifests"
View Source
const DefaultScriptsDir = "artillery-scripts"
View Source
const LabelPrefix = "loadtest"
View Source
const LoadTestFilename = "loadtest-cr.yaml"
Variables ¶
This section is empty.
Functions ¶
func CopyFileTo ¶
func DirOrFileExists ¶
func MkdirAllTargetOrDefault ¶
Types ¶
type CLISettings ¶
type CLISettings struct { File string `yaml:"-" json:"-"` Analytics *TelemetryCLISettings `yaml:"kubectl-artillery,omitempty" json:"kubectl-artillery,omitempty"` }
func GetOrCreateCLISettings ¶
func GetOrCreateCLISettings() (*CLISettings, error)
func (*CLISettings) GetFirstRun ¶
func (s *CLISettings) GetFirstRun() bool
func (*CLISettings) Save ¶
func (s *CLISettings) Save() error
func (*CLISettings) SetFirstRun ¶
func (s *CLISettings) SetFirstRun(b bool) *CLISettings
type Config ¶ added in v0.1.1
type Config struct { Target string `json:"target" yaml:"target"` Phases []Phase `json:"phases,omitempty" yaml:"phases,omitempty"` Environments map[string]Environment `json:"environments,omitempty" yaml:"environments,omitempty"` }
type Environment ¶ added in v0.1.1
type FileMarshaler ¶
type Flow ¶ added in v0.1.1
type Flow struct {
GetFlow GetFlow `json:"get,omitempty" yaml:"get,omitempty"`
}
type Generatable ¶
type Generatable struct { Path string Marshaler FileMarshaler }
type Generatables ¶
type Generatables []Generatable
type GetFlow ¶ added in v0.1.1
type GetFlow struct { Url string `json:"url,omitempty" yaml:"url,omitempty"` Expect []StatusCode `json:"expect,omitempty" yaml:"expect,omitempty"` }
type IOLogger ¶
type IOLogger struct {
// contains filtered or unexported fields
}
func (*IOLogger) WithValues ¶
type Kustomization ¶
type Kustomization struct {
*types.Kustomization
}
func NewKustomization ¶
func NewKustomization(loadtest, configMap, testScript, labelPrefix string) *Kustomization
func (*Kustomization) MarshalWithIndent ¶
func (k *Kustomization) MarshalWithIndent(indent int) ([]byte, error)
type Scenario ¶ added in v0.1.1
type Scenario struct {
Flows []Flow `json:"flow,omitempty" yaml:"flow,omitempty"`
}
type StatusCode ¶ added in v0.1.1
type StatusCode struct {
Code int `json:"statusCode,omitempty" yaml:"statusCode,omitempty"`
}
type TelemetryCLISettings ¶
type TelemetryCLISettings struct {
FirstRun *bool `yaml:"telemetry-first-run-msg,omitempty" json:"telemetry-first-run-msg,omitempty"`
}
type TestScript ¶ added in v0.1.1
type TestScript struct { Config Config `json:"config" yaml:"config"` Scenarios []Scenario `json:"scenarios" yaml:"scenarios"` }
func NewTestScript ¶ added in v0.1.1
func NewTestScript(probes kube.ServiceProbes) *TestScript
func (*TestScript) MarshalWithIndent ¶ added in v0.1.1
func (t *TestScript) MarshalWithIndent(indent int) ([]byte, error)
Click to show internal directories.
Click to hide internal directories.