apihandler

package
v0.0.0-...-8e7039a Latest Latest
Warning

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

Go to latest
Published: May 24, 2017 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Routes = []httpapi.Route{
	httpapi.Route{
		Method:  "GET",
		Path:    "/status",
		Handler: coordinatorStatus},

	httpapi.Route{
		Method:  "GET",
		Path:    "/agents",
		Handler: agentList},

	httpapi.Route{
		Method:  "POST",
		Path:    "/agents",
		Handler: addAgent},

	httpapi.Route{
		Method:  "GET",
		Path:    "/agents/:id",
		Handler: getAgent},

	httpapi.Route{
		Method:  "GET",
		Path:    "/agents/:id/status",
		Handler: agentStatus},

	httpapi.Route{
		Method:  "PUT",
		Path:    "/agents/:id",
		Handler: updateAgent},

	httpapi.Route{
		Method:  "GET",
		Path:    "/jobs/:id",
		Handler: jobStatus},

	httpapi.Route{
		Method:  "POST",
		Path:    "/jobs",
		Handler: newJob},

	httpapi.Route{
		Method:  "POST",
		Path:    "/jobs/:id/files",
		Handler: addJobFile},

	httpapi.Route{
		Method:  "POST",
		Path:    "/jobs/:id/complete",
		Handler: finishJob},

	httpapi.Route{
		Method:  "GET",
		Path:    "/jobs",
		Handler: jobList},

	httpapi.Route{
		Method:  "GET",
		Path:    "/jobs/:id/files",
		Handler: jobFiles},

	httpapi.Route{
		Method:  "GET",
		Path:    "/jobs/:id/directories",
		Handler: jobDirectories},

	httpapi.Route{
		Method:  "GET",
		Path:    "/job-definitions",
		Handler: jobDefinitionList},

	httpapi.Route{
		Method:  "GET",
		Path:    "/job-definitions/:id",
		Handler: getJobDefinition},

	httpapi.Route{
		Method:  "DELETE",
		Path:    "/job-definitions/:id",
		Handler: deleteJobDefinition},

	httpapi.Route{
		Method:  "PUT",
		Path:    "/job-definitions/:id",
		Handler: updateJobDefinition},

	httpapi.Route{
		Method:  "POST",
		Path:    "/job-definitions",
		Handler: createJobDefinition},

	httpapi.Route{
		Method:  "GET",
		Path:    "/schedules",
		Handler: scheduleList},

	httpapi.Route{
		Method:  "POST",
		Path:    "/schedules",
		Handler: addSchedule},

	httpapi.Route{
		Method:  "DELETE",
		Path:    "/schedules/{sID}",
		Handler: deleteSchedule},

	httpapi.Route{
		Method:  "PUT",
		Path:    "/schedules/{sID}",
		Handler: updateSchedule},

	httpapi.Route{
		Method:  "POST",
		Path:    "/email",
		Handler: testEmail},
}

Routes are the agent's routes

Functions

This section is empty.

Types

type JobRequest

type JobRequest struct {
	Definition model.JobDefinition `json:"jobDefinition"`
	Agent      string              `json:"agentId"`
}

type UpdateAgentRequest

type UpdateAgentRequest struct {
	Name      string `json:"name"`
	Address   string `json:"address"`
	UpdateKey bool   `json:"updateKey"`
}

Jump to

Keyboard shortcuts

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