v1

package
v0.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2017 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleGetGroup added in v0.5.0

func HandleGetGroup(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func HandleGetGroups added in v0.5.0

func HandleGetGroups(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func HandleGetMetric added in v0.5.0

func HandleGetMetric(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func HandleGetMetrics added in v0.5.0

func HandleGetMetrics(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func HandleGetStatus added in v0.5.0

func HandleGetStatus(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func HandlePatchStatus added in v0.5.0

func HandlePatchStatus(rw http.ResponseWriter, r *http.Request, p httprouter.Params)

func NewHandler

func NewHandler() http.Handler

Types

type Check added in v0.5.0

type Check struct {
	ID     int64  `json:"id"`
	Name   string `json:"name"`
	Passes int64  `json:"passes"`
	Fails  int64  `json:"fails"`
}

func NewCheck added in v0.5.0

func NewCheck(c *lib.Check) Check

type Error added in v0.5.0

type Error api2go.Error

func (Error) Error added in v0.5.0

func (e Error) Error() string

type ErrorResponse added in v0.5.0

type ErrorResponse struct {
	Errors []Error `json:"errors"`
}

type Group added in v0.5.0

type Group struct {
	ID     int64   `json:"-"`
	Name   string  `json:"name"`
	Checks []Check `json:"checks"`

	Parent   *Group   `json:"-"`
	ParentID int64    `json:"-"`
	Groups   []*Group `json:"-"`
	GroupIDs []int64  `json:"-"`
}

func FlattenGroup added in v0.5.0

func FlattenGroup(g *Group) []*Group

func NewGroup added in v0.5.0

func NewGroup(g *lib.Group, parent *Group) *Group

func (Group) GetID added in v0.5.0

func (g Group) GetID() string

func (Group) GetReferencedIDs added in v0.5.0

func (g Group) GetReferencedIDs() []jsonapi.ReferenceID

func (Group) GetReferences added in v0.5.0

func (g Group) GetReferences() []jsonapi.Reference

func (*Group) SetID added in v0.5.0

func (g *Group) SetID(v string) error

func (*Group) SetToManyReferenceIDs added in v0.5.0

func (g *Group) SetToManyReferenceIDs(name string, IDs []string) error

func (*Group) SetToOneReferenceID added in v0.5.0

func (g *Group) SetToOneReferenceID(name, ID string) error

type Metric added in v0.5.0

type Metric struct {
	Name string `json:"-"`

	Type     NullMetricType `json:"type"`
	Contains NullValueType  `json:"contains"`

	Sample map[string]float64 `json:"sample"`
}

func NewMetric added in v0.5.0

func NewMetric(m stats.Metric, sink stats.Sink) Metric

func (Metric) GetID added in v0.5.0

func (m Metric) GetID() string

func (*Metric) SetID added in v0.5.0

func (m *Metric) SetID(id string) error

type NullMetricType added in v0.5.0

type NullMetricType struct {
	Type  stats.MetricType
	Valid bool
}

func (NullMetricType) MarshalJSON added in v0.5.0

func (t NullMetricType) MarshalJSON() ([]byte, error)

func (*NullMetricType) UnmarshalJSON added in v0.5.0

func (t *NullMetricType) UnmarshalJSON(data []byte) error

type NullValueType added in v0.5.0

type NullValueType struct {
	Type  stats.ValueType
	Valid bool
}

func (NullValueType) MarshalJSON added in v0.5.0

func (t NullValueType) MarshalJSON() ([]byte, error)

func (*NullValueType) UnmarshalJSON added in v0.5.0

func (t *NullValueType) UnmarshalJSON(data []byte) error

type Status added in v0.5.0

type Status struct {
	Paused null.Bool `json:"paused"`
	VUs    null.Int  `json:"vus"`
	VUsMax null.Int  `json:"vus-max"`

	// Readonly.
	Running bool `json:"running"`
	Tainted bool `json:"tainted"`
}

func NewStatus added in v0.5.0

func NewStatus(engine *lib.Engine) Status

func (Status) GetID added in v0.5.0

func (s Status) GetID() string

func (Status) GetName added in v0.5.0

func (s Status) GetName() string

func (Status) SetID added in v0.5.0

func (s Status) SetID(id string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL