argo-web-api: Index | Files

package downtimes

import ""


Package Files

controller.go model.go routing.go view.go

func Create Uses

func Create(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

Create request handler creates a new weight resource

func Delete Uses

func Delete(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

Delete weights resource based on ID

func HandleSubrouter Uses

func HandleSubrouter(s *mux.Router, confhandler *respond.ConfHandler)

HandleSubrouter uses the subrouter for a specific calls and creates a tree of sorts handling each route with a different subrouter

func List Uses

func List(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

List the existing weight resources for the tenant making the request

func ListOne Uses

func ListOne(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

ListOne handles the listing of one weight resource based on its given id

func Options Uses

func Options(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

Options request handler

func Update Uses

func Update(r *http.Request, cfg config.Config) (int, http.Header, []byte, error)

Update function to update contents of an existing weights resource

type Downtime Uses

type Downtime struct {
    HostName  string `bson:"hostname" json:"hostname"`
    Service   string `bson:"service" json:"service"`
    StartTime string `bson:"start_time" json:"start_time"`
    EndTime   string `bson:"end_time" json:"end_time"`

Downtime holds downtime information for a specific host

type Downtimes Uses

type Downtimes struct {
    ID        string     `bson:"id" json:"id"`
    DateInt   int        `bson:"date_integer" json:"-"`
    Date      string     `bson:"date" json:"date"`
    Name      string     `bson:"name" json:"name"`
    Endpoints []Downtime `bson:"endpoints" json:"endpoints"`

Downtimes holds a list of downtimes for endpoints for a specific day

type Links struct {
    Self string `json:"self"`

Links struct to hold links

type SelfReference Uses

type SelfReference struct {
    ID    string `json:"id" bson:"id,omitempty"`
    Links Links  `json:"links"`

SelfReference to hold links and id

Package downtimes imports 13 packages (graph). Updated 2020-03-31. Refresh now. Tools for package owners.