Documentation ¶
Overview ¶
Package client provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen/v2 version v2.1.0 DO NOT EDIT.
Index ¶
- Constants
- func GetSwagger() (swagger *openapi3.T, err error)
- func NewBusyRequest(server string) (*http.Request, error)
- func NewCreateOrUpdateJobRequest(server string, params *CreateOrUpdateJobParams, ...) (*http.Request, error)
- func NewCreateOrUpdateJobRequestWithBody(server string, params *CreateOrUpdateJobParams, contentType string, ...) (*http.Request, error)
- func NewDeleteJobRequest(server string, jobName string) (*http.Request, error)
- func NewDeletePolicyRequest(server string, name string) (*http.Request, error)
- func NewGetIsLeaderRequest(server string) (*http.Request, error)
- func NewGetJobsRequest(server string, params *GetJobsParams) (*http.Request, error)
- func NewGetLeaderRequest(server string) (*http.Request, error)
- func NewGetMemberRequest(server string) (*http.Request, error)
- func NewLeaveRequest(server string) (*http.Request, error)
- func NewListExecutionsByJobRequest(server string, jobName string) (*http.Request, error)
- func NewRestoreRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewRunJobRequest(server string, jobName string) (*http.Request, error)
- func NewShowExecutionByIDRequest(server string, jobName string, execution string) (*http.Request, error)
- func NewShowJobByNameRequest(server string, jobName string) (*http.Request, error)
- func NewShowPolicyByNameRequest(server string, name string) (*http.Request, error)
- func NewStatusRequest(server string) (*http.Request, error)
- func NewToggleJobRequest(server string, jobName string) (*http.Request, error)
- func NewUpsertPolicyRequest(server string, name string) (*http.Request, error)
- func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)
- func RegisterHandlers(router EchoRouter, si ServerInterface)
- func RegisterHandlersWithBaseURL(router EchoRouter, si ServerInterface, baseURL string)
- type BusyResponse
- type Client
- func (c *Client) Busy(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) CreateOrUpdateJob(ctx context.Context, params *CreateOrUpdateJobParams, ...) (*http.Response, error)
- func (c *Client) CreateOrUpdateJobWithBody(ctx context.Context, params *CreateOrUpdateJobParams, contentType string, ...) (*http.Response, error)
- func (c *Client) DeleteJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) DeletePolicy(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetIsLeader(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetJobs(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetLeader(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetMember(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) Leave(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) ListExecutionsByJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) RestoreWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) RunJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) ShowExecutionByID(ctx context.Context, jobName string, execution string, ...) (*http.Response, error)
- func (c *Client) ShowJobByName(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) ShowPolicyByName(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) Status(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) ToggleJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) UpsertPolicy(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) BusyWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*BusyResponse, error)
- func (c *ClientWithResponses) CreateOrUpdateJobWithBodyWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, contentType string, ...) (*CreateOrUpdateJobResponse, error)
- func (c *ClientWithResponses) CreateOrUpdateJobWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, ...) (*CreateOrUpdateJobResponse, error)
- func (c *ClientWithResponses) DeleteJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*DeleteJobResponse, error)
- func (c *ClientWithResponses) DeletePolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error)
- func (c *ClientWithResponses) GetIsLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetIsLeaderResponse, error)
- func (c *ClientWithResponses) GetJobsWithResponse(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*GetJobsResponse, error)
- func (c *ClientWithResponses) GetLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetLeaderResponse, error)
- func (c *ClientWithResponses) GetMemberWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetMemberResponse, error)
- func (c *ClientWithResponses) LeaveWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LeaveResponse, error)
- func (c *ClientWithResponses) ListExecutionsByJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ListExecutionsByJobResponse, error)
- func (c *ClientWithResponses) RestoreWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*RestoreResponse, error)
- func (c *ClientWithResponses) RunJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*RunJobResponse, error)
- func (c *ClientWithResponses) ShowExecutionByIDWithResponse(ctx context.Context, jobName string, execution string, ...) (*ShowExecutionByIDResponse, error)
- func (c *ClientWithResponses) ShowJobByNameWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ShowJobByNameResponse, error)
- func (c *ClientWithResponses) ShowPolicyByNameWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*ShowPolicyByNameResponse, error)
- func (c *ClientWithResponses) StatusWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*StatusResponse, error)
- func (c *ClientWithResponses) ToggleJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ToggleJobResponse, error)
- func (c *ClientWithResponses) UpsertPolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*UpsertPolicyResponse, error)
- type ClientWithResponsesInterface
- type CreateOrUpdateJobJSONRequestBody
- type CreateOrUpdateJobParams
- type CreateOrUpdateJobResponse
- type DeleteJobResponse
- type DeletePolicyResponse
- type EchoRouter
- type Execution
- type GetIsLeaderResponse
- type GetJobsParams
- type GetJobsResponse
- type GetLeaderResponse
- type GetMemberResponse
- type HttpRequestDoer
- type Job
- type LeaveResponse
- type ListExecutionsByJobResponse
- type Member
- type Policy
- type Processors
- type RequestEditorFn
- type Restore
- type RestoreBody
- type RestoreMultipartRequestBody
- type RestoreResponse
- type RunJobResponse
- type ServerInterface
- type ServerInterfaceWrapper
- func (w *ServerInterfaceWrapper) Busy(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) CreateOrUpdateJob(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DeleteJob(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DeletePolicy(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) GetIsLeader(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) GetJobs(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) GetLeader(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) GetMember(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) Leave(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) ListExecutionsByJob(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) Restore(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) RunJob(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) ShowExecutionByID(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) ShowJobByName(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) ShowPolicyByName(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) Status(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) ToggleJob(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) UpsertPolicy(ctx echo.Context) error
- type ShowExecutionByIDResponse
- type ShowJobByNameResponse
- type ShowPolicyByNameResponse
- type Status
- type StatusResponse
- type ToggleJobResponse
- type UpsertPolicyResponse
Constants ¶
const (
TokenAuthScopes = "TokenAuth.Scopes"
)
Variables ¶
This section is empty.
Functions ¶
func GetSwagger ¶
GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.
func NewBusyRequest ¶
NewBusyRequest generates requests for Busy
func NewCreateOrUpdateJobRequest ¶
func NewCreateOrUpdateJobRequest(server string, params *CreateOrUpdateJobParams, body CreateOrUpdateJobJSONRequestBody) (*http.Request, error)
NewCreateOrUpdateJobRequest calls the generic CreateOrUpdateJob builder with application/json body
func NewCreateOrUpdateJobRequestWithBody ¶
func NewCreateOrUpdateJobRequestWithBody(server string, params *CreateOrUpdateJobParams, contentType string, body io.Reader) (*http.Request, error)
NewCreateOrUpdateJobRequestWithBody generates requests for CreateOrUpdateJob with any type of body
func NewDeleteJobRequest ¶
NewDeleteJobRequest generates requests for DeleteJob
func NewDeletePolicyRequest ¶
NewDeletePolicyRequest generates requests for DeletePolicy
func NewGetIsLeaderRequest ¶
NewGetIsLeaderRequest generates requests for GetIsLeader
func NewGetJobsRequest ¶
func NewGetJobsRequest(server string, params *GetJobsParams) (*http.Request, error)
NewGetJobsRequest generates requests for GetJobs
func NewGetLeaderRequest ¶
NewGetLeaderRequest generates requests for GetLeader
func NewGetMemberRequest ¶
NewGetMemberRequest generates requests for GetMember
func NewLeaveRequest ¶
NewLeaveRequest generates requests for Leave
func NewListExecutionsByJobRequest ¶
NewListExecutionsByJobRequest generates requests for ListExecutionsByJob
func NewRestoreRequestWithBody ¶
func NewRestoreRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
NewRestoreRequestWithBody generates requests for Restore with any type of body
func NewRunJobRequest ¶
NewRunJobRequest generates requests for RunJob
func NewShowExecutionByIDRequest ¶
func NewShowExecutionByIDRequest(server string, jobName string, execution string) (*http.Request, error)
NewShowExecutionByIDRequest generates requests for ShowExecutionByID
func NewShowJobByNameRequest ¶
NewShowJobByNameRequest generates requests for ShowJobByName
func NewShowPolicyByNameRequest ¶
NewShowPolicyByNameRequest generates requests for ShowPolicyByName
func NewStatusRequest ¶
NewStatusRequest generates requests for Status
func NewToggleJobRequest ¶
NewToggleJobRequest generates requests for ToggleJob
func NewUpsertPolicyRequest ¶
NewUpsertPolicyRequest generates requests for UpsertPolicy
func PathToRawSpec ¶
Constructs a synthetic filesystem for resolving external references when loading openapi specifications.
func RegisterHandlers ¶
func RegisterHandlers(router EchoRouter, si ServerInterface)
RegisterHandlers adds each server route to the EchoRouter.
func RegisterHandlersWithBaseURL ¶
func RegisterHandlersWithBaseURL(router EchoRouter, si ServerInterface, baseURL string)
Registers handlers, and prepends BaseURL to the paths, so that the paths can be served under a prefix.
Types ¶
type BusyResponse ¶
func ParseBusyResponse ¶
func ParseBusyResponse(rsp *http.Response) (*BusyResponse, error)
ParseBusyResponse parses an HTTP response from a BusyWithResponse call
func (BusyResponse) Status ¶
func (r BusyResponse) Status() string
Status returns HTTPResponse.Status
func (BusyResponse) StatusCode ¶
func (r BusyResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type Client ¶
type Client struct { // The endpoint of the server conforming to this interface, with scheme, // https://api.deepmap.com for example. This can contain a path relative // to the server, such as https://api.deepmap.com/dev-test, and all the // paths in the swagger spec will be appended to the server. Server string // Doer for performing requests, typically a *http.Client with any // customized settings, such as certificate chains. Client HttpRequestDoer // A list of callbacks for modifying requests which are generated before sending over // the network. RequestEditors []RequestEditorFn }
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) CreateOrUpdateJob ¶
func (c *Client) CreateOrUpdateJob(ctx context.Context, params *CreateOrUpdateJobParams, body CreateOrUpdateJobJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateOrUpdateJobWithBody ¶
func (*Client) DeletePolicy ¶
func (*Client) GetIsLeader ¶
func (*Client) GetJobs ¶
func (c *Client) GetJobs(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) ListExecutionsByJob ¶
func (*Client) RestoreWithBody ¶
func (*Client) ShowExecutionByID ¶
func (*Client) ShowJobByName ¶
func (*Client) ShowPolicyByName ¶
func (*Client) UpsertPolicy ¶
type ClientInterface ¶
type ClientInterface interface { // Status request Status(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // DeletePolicy request DeletePolicy(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error) // ShowPolicyByName request ShowPolicyByName(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error) // UpsertPolicy request UpsertPolicy(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*http.Response, error) // Busy request Busy(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // GetIsLeader request GetIsLeader(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // GetJobs request GetJobs(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateOrUpdateJobWithBody request with any body CreateOrUpdateJobWithBody(ctx context.Context, params *CreateOrUpdateJobParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) CreateOrUpdateJob(ctx context.Context, params *CreateOrUpdateJobParams, body CreateOrUpdateJobJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteJob request DeleteJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error) // ShowJobByName request ShowJobByName(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error) // RunJob request RunJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error) // ListExecutionsByJob request ListExecutionsByJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error) // ShowExecutionByID request ShowExecutionByID(ctx context.Context, jobName string, execution string, reqEditors ...RequestEditorFn) (*http.Response, error) // ToggleJob request ToggleJob(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*http.Response, error) // GetLeader request GetLeader(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // Leave request Leave(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // GetMember request GetMember(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) // RestoreWithBody request with any body RestoreWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) }
The interface specification for the client above.
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func NewClientWithResponses ¶
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) BusyWithResponse ¶
func (c *ClientWithResponses) BusyWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*BusyResponse, error)
BusyWithResponse request returning *BusyResponse
func (*ClientWithResponses) CreateOrUpdateJobWithBodyWithResponse ¶
func (c *ClientWithResponses) CreateOrUpdateJobWithBodyWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateOrUpdateJobResponse, error)
CreateOrUpdateJobWithBodyWithResponse request with arbitrary body returning *CreateOrUpdateJobResponse
func (*ClientWithResponses) CreateOrUpdateJobWithResponse ¶
func (c *ClientWithResponses) CreateOrUpdateJobWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, body CreateOrUpdateJobJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateOrUpdateJobResponse, error)
func (*ClientWithResponses) DeleteJobWithResponse ¶
func (c *ClientWithResponses) DeleteJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*DeleteJobResponse, error)
DeleteJobWithResponse request returning *DeleteJobResponse
func (*ClientWithResponses) DeletePolicyWithResponse ¶
func (c *ClientWithResponses) DeletePolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error)
DeletePolicyWithResponse request returning *DeletePolicyResponse
func (*ClientWithResponses) GetIsLeaderWithResponse ¶
func (c *ClientWithResponses) GetIsLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetIsLeaderResponse, error)
GetIsLeaderWithResponse request returning *GetIsLeaderResponse
func (*ClientWithResponses) GetJobsWithResponse ¶
func (c *ClientWithResponses) GetJobsWithResponse(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*GetJobsResponse, error)
GetJobsWithResponse request returning *GetJobsResponse
func (*ClientWithResponses) GetLeaderWithResponse ¶
func (c *ClientWithResponses) GetLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetLeaderResponse, error)
GetLeaderWithResponse request returning *GetLeaderResponse
func (*ClientWithResponses) GetMemberWithResponse ¶
func (c *ClientWithResponses) GetMemberWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetMemberResponse, error)
GetMemberWithResponse request returning *GetMemberResponse
func (*ClientWithResponses) LeaveWithResponse ¶
func (c *ClientWithResponses) LeaveWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LeaveResponse, error)
LeaveWithResponse request returning *LeaveResponse
func (*ClientWithResponses) ListExecutionsByJobWithResponse ¶
func (c *ClientWithResponses) ListExecutionsByJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ListExecutionsByJobResponse, error)
ListExecutionsByJobWithResponse request returning *ListExecutionsByJobResponse
func (*ClientWithResponses) RestoreWithBodyWithResponse ¶
func (c *ClientWithResponses) RestoreWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RestoreResponse, error)
RestoreWithBodyWithResponse request with arbitrary body returning *RestoreResponse
func (*ClientWithResponses) RunJobWithResponse ¶
func (c *ClientWithResponses) RunJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*RunJobResponse, error)
RunJobWithResponse request returning *RunJobResponse
func (*ClientWithResponses) ShowExecutionByIDWithResponse ¶
func (c *ClientWithResponses) ShowExecutionByIDWithResponse(ctx context.Context, jobName string, execution string, reqEditors ...RequestEditorFn) (*ShowExecutionByIDResponse, error)
ShowExecutionByIDWithResponse request returning *ShowExecutionByIDResponse
func (*ClientWithResponses) ShowJobByNameWithResponse ¶
func (c *ClientWithResponses) ShowJobByNameWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ShowJobByNameResponse, error)
ShowJobByNameWithResponse request returning *ShowJobByNameResponse
func (*ClientWithResponses) ShowPolicyByNameWithResponse ¶
func (c *ClientWithResponses) ShowPolicyByNameWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*ShowPolicyByNameResponse, error)
ShowPolicyByNameWithResponse request returning *ShowPolicyByNameResponse
func (*ClientWithResponses) StatusWithResponse ¶
func (c *ClientWithResponses) StatusWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*StatusResponse, error)
StatusWithResponse request returning *StatusResponse
func (*ClientWithResponses) ToggleJobWithResponse ¶
func (c *ClientWithResponses) ToggleJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ToggleJobResponse, error)
ToggleJobWithResponse request returning *ToggleJobResponse
func (*ClientWithResponses) UpsertPolicyWithResponse ¶
func (c *ClientWithResponses) UpsertPolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*UpsertPolicyResponse, error)
UpsertPolicyWithResponse request returning *UpsertPolicyResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface { // StatusWithResponse request StatusWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*StatusResponse, error) // DeletePolicyWithResponse request DeletePolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) // ShowPolicyByNameWithResponse request ShowPolicyByNameWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*ShowPolicyByNameResponse, error) // UpsertPolicyWithResponse request UpsertPolicyWithResponse(ctx context.Context, name string, reqEditors ...RequestEditorFn) (*UpsertPolicyResponse, error) // BusyWithResponse request BusyWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*BusyResponse, error) // GetIsLeaderWithResponse request GetIsLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetIsLeaderResponse, error) // GetJobsWithResponse request GetJobsWithResponse(ctx context.Context, params *GetJobsParams, reqEditors ...RequestEditorFn) (*GetJobsResponse, error) // CreateOrUpdateJobWithBodyWithResponse request with any body CreateOrUpdateJobWithBodyWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateOrUpdateJobResponse, error) CreateOrUpdateJobWithResponse(ctx context.Context, params *CreateOrUpdateJobParams, body CreateOrUpdateJobJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateOrUpdateJobResponse, error) // DeleteJobWithResponse request DeleteJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*DeleteJobResponse, error) // ShowJobByNameWithResponse request ShowJobByNameWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ShowJobByNameResponse, error) // RunJobWithResponse request RunJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*RunJobResponse, error) // ListExecutionsByJobWithResponse request ListExecutionsByJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ListExecutionsByJobResponse, error) // ShowExecutionByIDWithResponse request ShowExecutionByIDWithResponse(ctx context.Context, jobName string, execution string, reqEditors ...RequestEditorFn) (*ShowExecutionByIDResponse, error) // ToggleJobWithResponse request ToggleJobWithResponse(ctx context.Context, jobName string, reqEditors ...RequestEditorFn) (*ToggleJobResponse, error) // GetLeaderWithResponse request GetLeaderWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetLeaderResponse, error) // LeaveWithResponse request LeaveWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LeaveResponse, error) // GetMemberWithResponse request GetMemberWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetMemberResponse, error) // RestoreWithBodyWithResponse request with any body RestoreWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RestoreResponse, error) }
ClientWithResponsesInterface is the interface specification for the client with responses above.
type CreateOrUpdateJobJSONRequestBody ¶
type CreateOrUpdateJobJSONRequestBody = Job
CreateOrUpdateJobJSONRequestBody defines body for CreateOrUpdateJob for application/json ContentType.
type CreateOrUpdateJobParams ¶
type CreateOrUpdateJobParams struct { // Runoncreate If present, regardless of any value, causes the job to be run immediately after being succesfully created or updated. Runoncreate *bool `form:"runoncreate,omitempty" json:"runoncreate,omitempty"` }
CreateOrUpdateJobParams defines parameters for CreateOrUpdateJob.
type CreateOrUpdateJobResponse ¶
func ParseCreateOrUpdateJobResponse ¶
func ParseCreateOrUpdateJobResponse(rsp *http.Response) (*CreateOrUpdateJobResponse, error)
ParseCreateOrUpdateJobResponse parses an HTTP response from a CreateOrUpdateJobWithResponse call
func (CreateOrUpdateJobResponse) Status ¶
func (r CreateOrUpdateJobResponse) Status() string
Status returns HTTPResponse.Status
func (CreateOrUpdateJobResponse) StatusCode ¶
func (r CreateOrUpdateJobResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type DeleteJobResponse ¶
func ParseDeleteJobResponse ¶
func ParseDeleteJobResponse(rsp *http.Response) (*DeleteJobResponse, error)
ParseDeleteJobResponse parses an HTTP response from a DeleteJobWithResponse call
func (DeleteJobResponse) Status ¶
func (r DeleteJobResponse) Status() string
Status returns HTTPResponse.Status
func (DeleteJobResponse) StatusCode ¶
func (r DeleteJobResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type DeletePolicyResponse ¶
func ParseDeletePolicyResponse ¶
func ParseDeletePolicyResponse(rsp *http.Response) (*DeletePolicyResponse, error)
ParseDeletePolicyResponse parses an HTTP response from a DeletePolicyWithResponse call
func (DeletePolicyResponse) Status ¶
func (r DeletePolicyResponse) Status() string
Status returns HTTPResponse.Status
func (DeletePolicyResponse) StatusCode ¶
func (r DeletePolicyResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type EchoRouter ¶
type EchoRouter interface { CONNECT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route DELETE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route GET(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route HEAD(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route OPTIONS(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route PATCH(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route POST(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route PUT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route TRACE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route }
This is a simple interface which specifies echo.Route addition functions which are present on both echo.Echo and echo.Group, since we want to allow using either of them for path registration
type GetIsLeaderResponse ¶
func ParseGetIsLeaderResponse ¶
func ParseGetIsLeaderResponse(rsp *http.Response) (*GetIsLeaderResponse, error)
ParseGetIsLeaderResponse parses an HTTP response from a GetIsLeaderWithResponse call
func (GetIsLeaderResponse) Status ¶
func (r GetIsLeaderResponse) Status() string
Status returns HTTPResponse.Status
func (GetIsLeaderResponse) StatusCode ¶
func (r GetIsLeaderResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetJobsParams ¶
type GetJobsParams struct { // Metadata Filter jobs by metadata Metadata *[]string `form:"metadata,omitempty" json:"metadata,omitempty"` // Sort Sorting field Sort *string `form:"_sort,omitempty" json:"_sort,omitempty"` // Order Sort order (ASC/DESC) Order *string `form:"_order,omitempty" json:"_order,omitempty"` // Q Filter query text Q *string `form:"q,omitempty" json:"q,omitempty"` // Start Start index Start *int `form:"_start,omitempty" json:"_start,omitempty"` // End End index End *int `form:"_end,omitempty" json:"_end,omitempty"` }
GetJobsParams defines parameters for GetJobs.
type GetJobsResponse ¶
func ParseGetJobsResponse ¶
func ParseGetJobsResponse(rsp *http.Response) (*GetJobsResponse, error)
ParseGetJobsResponse parses an HTTP response from a GetJobsWithResponse call
func (GetJobsResponse) Status ¶
func (r GetJobsResponse) Status() string
Status returns HTTPResponse.Status
func (GetJobsResponse) StatusCode ¶
func (r GetJobsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetLeaderResponse ¶
func ParseGetLeaderResponse ¶
func ParseGetLeaderResponse(rsp *http.Response) (*GetLeaderResponse, error)
ParseGetLeaderResponse parses an HTTP response from a GetLeaderWithResponse call
func (GetLeaderResponse) Status ¶
func (r GetLeaderResponse) Status() string
Status returns HTTPResponse.Status
func (GetLeaderResponse) StatusCode ¶
func (r GetLeaderResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetMemberResponse ¶
func ParseGetMemberResponse ¶
func ParseGetMemberResponse(rsp *http.Response) (*GetMemberResponse, error)
ParseGetMemberResponse parses an HTTP response from a GetMemberWithResponse call
func (GetMemberResponse) Status ¶
func (r GetMemberResponse) Status() string
Status returns HTTPResponse.Status
func (GetMemberResponse) StatusCode ¶
func (r GetMemberResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type LeaveResponse ¶
func ParseLeaveResponse ¶
func ParseLeaveResponse(rsp *http.Response) (*LeaveResponse, error)
ParseLeaveResponse parses an HTTP response from a LeaveWithResponse call
func (LeaveResponse) Status ¶
func (r LeaveResponse) Status() string
Status returns HTTPResponse.Status
func (LeaveResponse) StatusCode ¶
func (r LeaveResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ListExecutionsByJobResponse ¶
type ListExecutionsByJobResponse struct { Body []byte HTTPResponse *http.Response JSON200 *[]Execution }
func ParseListExecutionsByJobResponse ¶
func ParseListExecutionsByJobResponse(rsp *http.Response) (*ListExecutionsByJobResponse, error)
ParseListExecutionsByJobResponse parses an HTTP response from a ListExecutionsByJobWithResponse call
func (ListExecutionsByJobResponse) Status ¶
func (r ListExecutionsByJobResponse) Status() string
Status returns HTTPResponse.Status
func (ListExecutionsByJobResponse) StatusCode ¶
func (r ListExecutionsByJobResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type Processors ¶
Processors Processor plugins used to process executions results of this job
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type RestoreBody ¶
type RestoreBody struct { // File Json file that needs to be restored. File openapi_types.File `json:"file"` }
RestoreBody defines model for restore_body.
type RestoreMultipartRequestBody ¶
type RestoreMultipartRequestBody = RestoreBody
RestoreMultipartRequestBody defines body for Restore for multipart/form-data ContentType.
type RestoreResponse ¶
func ParseRestoreResponse ¶
func ParseRestoreResponse(rsp *http.Response) (*RestoreResponse, error)
ParseRestoreResponse parses an HTTP response from a RestoreWithResponse call
func (RestoreResponse) Status ¶
func (r RestoreResponse) Status() string
Status returns HTTPResponse.Status
func (RestoreResponse) StatusCode ¶
func (r RestoreResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type RunJobResponse ¶
func ParseRunJobResponse ¶
func ParseRunJobResponse(rsp *http.Response) (*RunJobResponse, error)
ParseRunJobResponse parses an HTTP response from a RunJobWithResponse call
func (RunJobResponse) Status ¶
func (r RunJobResponse) Status() string
Status returns HTTPResponse.Status
func (RunJobResponse) StatusCode ¶
func (r RunJobResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ServerInterface ¶
type ServerInterface interface { // (GET /) Status(ctx echo.Context) error // (DELETE /acl/policies/{name}) DeletePolicy(ctx echo.Context, name string) error // (GET /acl/policies/{name}) ShowPolicyByName(ctx echo.Context, name string) error // (POST /acl/policies/{name}) UpsertPolicy(ctx echo.Context, name string) error // (GET /busy) Busy(ctx echo.Context) error // (GET /isleader) GetIsLeader(ctx echo.Context) error // (GET /jobs) GetJobs(ctx echo.Context, params GetJobsParams) error // (POST /jobs) CreateOrUpdateJob(ctx echo.Context, params CreateOrUpdateJobParams) error // (DELETE /jobs/{job_name}) DeleteJob(ctx echo.Context, jobName string) error // (GET /jobs/{job_name}) ShowJobByName(ctx echo.Context, jobName string) error // (POST /jobs/{job_name}) RunJob(ctx echo.Context, jobName string) error // (GET /jobs/{job_name}/executions) ListExecutionsByJob(ctx echo.Context, jobName string) error // (GET /jobs/{job_name}/executions/{execution}) ShowExecutionByID(ctx echo.Context, jobName string, execution string) error // (POST /jobs/{job_name}/toggle) ToggleJob(ctx echo.Context, jobName string) error // (GET /leader) GetLeader(ctx echo.Context) error // (POST /leave) Leave(ctx echo.Context) error // (GET /members) GetMember(ctx echo.Context) error // (POST /restore) Restore(ctx echo.Context) error }
ServerInterface represents all server handlers.
type ServerInterfaceWrapper ¶
type ServerInterfaceWrapper struct {
Handler ServerInterface
}
ServerInterfaceWrapper converts echo contexts to parameters.
func (*ServerInterfaceWrapper) Busy ¶
func (w *ServerInterfaceWrapper) Busy(ctx echo.Context) error
Busy converts echo context to params.
func (*ServerInterfaceWrapper) CreateOrUpdateJob ¶
func (w *ServerInterfaceWrapper) CreateOrUpdateJob(ctx echo.Context) error
CreateOrUpdateJob converts echo context to params.
func (*ServerInterfaceWrapper) DeleteJob ¶
func (w *ServerInterfaceWrapper) DeleteJob(ctx echo.Context) error
DeleteJob converts echo context to params.
func (*ServerInterfaceWrapper) DeletePolicy ¶
func (w *ServerInterfaceWrapper) DeletePolicy(ctx echo.Context) error
DeletePolicy converts echo context to params.
func (*ServerInterfaceWrapper) GetIsLeader ¶
func (w *ServerInterfaceWrapper) GetIsLeader(ctx echo.Context) error
GetIsLeader converts echo context to params.
func (*ServerInterfaceWrapper) GetJobs ¶
func (w *ServerInterfaceWrapper) GetJobs(ctx echo.Context) error
GetJobs converts echo context to params.
func (*ServerInterfaceWrapper) GetLeader ¶
func (w *ServerInterfaceWrapper) GetLeader(ctx echo.Context) error
GetLeader converts echo context to params.
func (*ServerInterfaceWrapper) GetMember ¶
func (w *ServerInterfaceWrapper) GetMember(ctx echo.Context) error
GetMember converts echo context to params.
func (*ServerInterfaceWrapper) Leave ¶
func (w *ServerInterfaceWrapper) Leave(ctx echo.Context) error
Leave converts echo context to params.
func (*ServerInterfaceWrapper) ListExecutionsByJob ¶
func (w *ServerInterfaceWrapper) ListExecutionsByJob(ctx echo.Context) error
ListExecutionsByJob converts echo context to params.
func (*ServerInterfaceWrapper) Restore ¶
func (w *ServerInterfaceWrapper) Restore(ctx echo.Context) error
Restore converts echo context to params.
func (*ServerInterfaceWrapper) RunJob ¶
func (w *ServerInterfaceWrapper) RunJob(ctx echo.Context) error
RunJob converts echo context to params.
func (*ServerInterfaceWrapper) ShowExecutionByID ¶
func (w *ServerInterfaceWrapper) ShowExecutionByID(ctx echo.Context) error
ShowExecutionByID converts echo context to params.
func (*ServerInterfaceWrapper) ShowJobByName ¶
func (w *ServerInterfaceWrapper) ShowJobByName(ctx echo.Context) error
ShowJobByName converts echo context to params.
func (*ServerInterfaceWrapper) ShowPolicyByName ¶
func (w *ServerInterfaceWrapper) ShowPolicyByName(ctx echo.Context) error
ShowPolicyByName converts echo context to params.
func (*ServerInterfaceWrapper) Status ¶
func (w *ServerInterfaceWrapper) Status(ctx echo.Context) error
Status converts echo context to params.
func (*ServerInterfaceWrapper) ToggleJob ¶
func (w *ServerInterfaceWrapper) ToggleJob(ctx echo.Context) error
ToggleJob converts echo context to params.
func (*ServerInterfaceWrapper) UpsertPolicy ¶
func (w *ServerInterfaceWrapper) UpsertPolicy(ctx echo.Context) error
UpsertPolicy converts echo context to params.
type ShowExecutionByIDResponse ¶
type ShowExecutionByIDResponse struct { Body []byte HTTPResponse *http.Response JSON200 *Execution }
func ParseShowExecutionByIDResponse ¶
func ParseShowExecutionByIDResponse(rsp *http.Response) (*ShowExecutionByIDResponse, error)
ParseShowExecutionByIDResponse parses an HTTP response from a ShowExecutionByIDWithResponse call
func (ShowExecutionByIDResponse) Status ¶
func (r ShowExecutionByIDResponse) Status() string
Status returns HTTPResponse.Status
func (ShowExecutionByIDResponse) StatusCode ¶
func (r ShowExecutionByIDResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ShowJobByNameResponse ¶
func ParseShowJobByNameResponse ¶
func ParseShowJobByNameResponse(rsp *http.Response) (*ShowJobByNameResponse, error)
ParseShowJobByNameResponse parses an HTTP response from a ShowJobByNameWithResponse call
func (ShowJobByNameResponse) Status ¶
func (r ShowJobByNameResponse) Status() string
Status returns HTTPResponse.Status
func (ShowJobByNameResponse) StatusCode ¶
func (r ShowJobByNameResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ShowPolicyByNameResponse ¶
func ParseShowPolicyByNameResponse ¶
func ParseShowPolicyByNameResponse(rsp *http.Response) (*ShowPolicyByNameResponse, error)
ParseShowPolicyByNameResponse parses an HTTP response from a ShowPolicyByNameWithResponse call
func (ShowPolicyByNameResponse) Status ¶
func (r ShowPolicyByNameResponse) Status() string
Status returns HTTPResponse.Status
func (ShowPolicyByNameResponse) StatusCode ¶
func (r ShowPolicyByNameResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type Status ¶
type Status struct { // Agent Node basic details Agent *map[string]map[string]interface{} `json:"agent,omitempty"` // Serf Serf status Serf *map[string]map[string]interface{} `json:"serf,omitempty"` // Tags Tags asociated with this node Tags *map[string]string `json:"tags,omitempty"` }
Status Status represents details about the node.
type StatusResponse ¶
func ParseStatusResponse ¶
func ParseStatusResponse(rsp *http.Response) (*StatusResponse, error)
ParseStatusResponse parses an HTTP response from a StatusWithResponse call
func (StatusResponse) Status ¶
func (r StatusResponse) Status() string
Status returns HTTPResponse.Status
func (StatusResponse) StatusCode ¶
func (r StatusResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type ToggleJobResponse ¶
func ParseToggleJobResponse ¶
func ParseToggleJobResponse(rsp *http.Response) (*ToggleJobResponse, error)
ParseToggleJobResponse parses an HTTP response from a ToggleJobWithResponse call
func (ToggleJobResponse) Status ¶
func (r ToggleJobResponse) Status() string
Status returns HTTPResponse.Status
func (ToggleJobResponse) StatusCode ¶
func (r ToggleJobResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type UpsertPolicyResponse ¶
func ParseUpsertPolicyResponse ¶
func ParseUpsertPolicyResponse(rsp *http.Response) (*UpsertPolicyResponse, error)
ParseUpsertPolicyResponse parses an HTTP response from a UpsertPolicyWithResponse call
func (UpsertPolicyResponse) Status ¶
func (r UpsertPolicyResponse) Status() string
Status returns HTTPResponse.Status
func (UpsertPolicyResponse) StatusCode ¶
func (r UpsertPolicyResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode