client

package
v0.9.2 Latest Latest
Warning

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

Go to latest
Published: May 15, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*common.Client
}

func NewClient

func NewClient(url, token string) *Client

NewClient initializes and returns a API client.

func (*Client) ApproveRunTask

func (c *Client) ApproveRunTask(ctx context.Context, runID, taskID string, changeGroupsUpdateToken string) (*Response, error)

func (*Client) CheckCache

func (c *Client) CheckCache(ctx context.Context, key string, prefix bool) (*Response, error)

func (*Client) CreateRun

func (*Client) DeleteLogs added in v0.4.0

func (c *Client) DeleteLogs(ctx context.Context, runID, taskID string, setup bool, step int) (*Response, error)

func (*Client) DisableMaintenance added in v0.8.0

func (c *Client) DisableMaintenance(ctx context.Context) (*Response, error)

func (*Client) EnableMaintenance added in v0.8.0

func (c *Client) EnableMaintenance(ctx context.Context) (*Response, error)

func (*Client) Export added in v0.8.0

func (c *Client) Export(ctx context.Context) (*Response, error)

func (*Client) GetArchive

func (c *Client) GetArchive(ctx context.Context, taskID string, step int) (*Response, error)

func (*Client) GetCache

func (c *Client) GetCache(ctx context.Context, key string, prefix bool) (*Response, error)

func (*Client) GetExecutorTask

func (c *Client) GetExecutorTask(ctx context.Context, executorID, etID string) (*rsapitypes.ExecutorTask, *Response, error)

func (*Client) GetExecutorTasks

func (c *Client) GetExecutorTasks(ctx context.Context, executorID string) ([]*rsapitypes.ExecutorTask, *Response, error)

func (*Client) GetGroupFirstQueuedRuns

func (c *Client) GetGroupFirstQueuedRuns(ctx context.Context, group string, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetGroupLastRun

func (c *Client) GetGroupLastRun(ctx context.Context, group string, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetGroupQueuedRuns

func (c *Client) GetGroupQueuedRuns(ctx context.Context, group string, limit int, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetGroupRunningRuns

func (c *Client) GetGroupRunningRuns(ctx context.Context, group string, limit int, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetGroupRuns added in v0.7.0

func (c *Client) GetGroupRuns(ctx context.Context, group string, opts *GetGroupRunsOptions) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetLogs

func (c *Client) GetLogs(ctx context.Context, runID, taskID string, setup bool, step int, follow bool) (*Response, error)

func (*Client) GetMaintenanceStatus added in v0.8.0

func (c *Client) GetMaintenanceStatus(ctx context.Context) (*rsapitypes.MaintenanceStatusResponse, *Response, error)

func (*Client) GetParsedResponse added in v0.9.0

func (c *Client) GetParsedResponse(ctx context.Context, method, path string, query url.Values, header http.Header, ibody io.Reader, obj interface{}) (*Response, error)

func (*Client) GetQueuedRuns

func (c *Client) GetQueuedRuns(ctx context.Context, startRunSequence uint64, limit int, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetResponse added in v0.9.0

func (c *Client) GetResponse(ctx context.Context, method, path string, query url.Values, contentLength int64, header http.Header, ibody io.Reader) (*Response, error)

func (*Client) GetRun

func (c *Client) GetRun(ctx context.Context, runID string, changeGroups []string) (*rsapitypes.RunResponse, *Response, error)

func (*Client) GetRunByGroup added in v0.7.0

func (c *Client) GetRunByGroup(ctx context.Context, group string, runNumber uint64, changeGroups []string) (*rsapitypes.RunResponse, *Response, error)

func (*Client) GetRunEvents

func (c *Client) GetRunEvents(ctx context.Context, afterSequence uint64) (*Response, error)

func (*Client) GetRunningRuns

func (c *Client) GetRunningRuns(ctx context.Context, startRunSequence uint64, limit int, changeGroups []string) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) GetRuns

func (c *Client) GetRuns(ctx context.Context, phaseFilter, resultFilter, groups []string, lastRun bool, changeGroups []string, startRunSequence uint64, limit int, asc bool) (*rsapitypes.GetRunsResponse, *Response, error)

func (*Client) Import added in v0.8.0

func (c *Client) Import(ctx context.Context, r io.Reader) (*Response, error)

func (*Client) PutCache

func (c *Client) PutCache(ctx context.Context, key string, size int64, r io.Reader) (*Response, error)

func (*Client) RunActions

func (c *Client) RunActions(ctx context.Context, runID string, req *rsapitypes.RunActionsRequest) (*Response, error)

func (*Client) RunTaskActions

func (c *Client) RunTaskActions(ctx context.Context, runID, taskID string, req *rsapitypes.RunTaskActionsRequest) (*Response, error)

func (*Client) RunTaskSetAnnotations

func (c *Client) RunTaskSetAnnotations(ctx context.Context, runID, taskID string, annotations map[string]string, changeGroupsUpdateToken string) (*Response, error)

func (*Client) SendExecutorStatus

func (c *Client) SendExecutorStatus(ctx context.Context, executorID string, executor *rsapitypes.ExecutorStatus) (*Response, error)

func (*Client) SendExecutorTaskStatus

func (c *Client) SendExecutorTaskStatus(ctx context.Context, executorID, etID string, et *rsapitypes.ExecutorTaskStatus) (*Response, error)

func (*Client) StartRun

func (c *Client) StartRun(ctx context.Context, runID string, changeGroupsUpdateToken string) (*Response, error)

type GetGroupRunsOptions added in v0.9.0

type GetGroupRunsOptions struct {
	*ListOptions

	StartRunCounter uint64
	PhaseFilter     []string
	ResultFilter    []string
	ChangeGroups    []string
}

func (*GetGroupRunsOptions) Add added in v0.9.0

func (o *GetGroupRunsOptions) Add(q url.Values)

type ListOptions added in v0.9.0

type ListOptions struct {
	Limit         int
	SortDirection rstypes.SortDirection
}

func (*ListOptions) Add added in v0.9.0

func (o *ListOptions) Add(q url.Values)

type Response added in v0.9.0

type Response struct {
	*http.Response

	HasMore bool
}

Jump to

Keyboard shortcuts

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