client

package
v1.0.19 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLogResultsPath

func GetLogResultsPath(date string, scan string, check string) string

GetLogResultsPath computes a request path to the getLog action of Results.

func GetReportResultsPath

func GetReportResultsPath(date string, scan string, check string) string

GetReportResultsPath computes a request path to the getReport action of Results.

func RawResultsPath

func RawResultsPath() string

RawResultsPath computes a request path to the raw action of Results.

func ReportResultsPath

func ReportResultsPath() string

ReportResultsPath computes a request path to the report action of Results.

func ShowHealthcheckPath

func ShowHealthcheckPath() string

ShowHealthcheckPath computes a request path to the show action of healthcheck.

Types

type Client

type Client struct {
	*goaclient.Client
	Encoder *goa.HTTPEncoder
	Decoder *goa.HTTPDecoder
}

Client is the vulcan-results service client.

func New

func New(c goaclient.Doer) *Client

New instantiates the client.

func (*Client) GetLogResults

func (c *Client) GetLogResults(ctx context.Context, path string) (*http.Response, error)

Download a log

func (*Client) GetReportResults

func (c *Client) GetReportResults(ctx context.Context, path string) (*http.Response, error)

Download a report

func (*Client) NewGetLogResultsRequest

func (c *Client) NewGetLogResultsRequest(ctx context.Context, path string) (*http.Request, error)

NewGetLogResultsRequest create the request corresponding to the getLog action endpoint of the Results resource.

func (*Client) NewGetReportResultsRequest

func (c *Client) NewGetReportResultsRequest(ctx context.Context, path string) (*http.Request, error)

NewGetReportResultsRequest create the request corresponding to the getReport action endpoint of the Results resource.

func (*Client) NewRawResultsRequest

func (c *Client) NewRawResultsRequest(ctx context.Context, path string, payload *RawPayload) (*http.Request, error)

NewRawResultsRequest create the request corresponding to the raw action endpoint of the Results resource.

func (*Client) NewReportResultsRequest

func (c *Client) NewReportResultsRequest(ctx context.Context, path string, payload *ReportPayload) (*http.Request, error)

NewReportResultsRequest create the request corresponding to the report action endpoint of the Results resource.

func (*Client) NewShowHealthcheckRequest

func (c *Client) NewShowHealthcheckRequest(ctx context.Context, path string) (*http.Request, error)

NewShowHealthcheckRequest create the request corresponding to the show action endpoint of the healthcheck resource.

func (*Client) RawResults

func (c *Client) RawResults(ctx context.Context, path string, payload *RawPayload) (*http.Response, error)

Update the Raw of a Check

func (*Client) ReportResults

func (c *Client) ReportResults(ctx context.Context, path string, payload *ReportPayload) (*http.Response, error)

Update the Report of a Check

func (*Client) ShowHealthcheck

func (c *Client) ShowHealthcheck(ctx context.Context, path string) (*http.Response, error)

Get the health status for the application

type RawPayload

type RawPayload struct {
	// Check UUID
	CheckID *uuid.UUID `form:"check_id,omitempty" json:"check_id,omitempty" yaml:"check_id,omitempty" xml:"check_id,omitempty"`
	// Raw result of a Check. It's a JSON with a BASE64 encoded value of the raw result
	Raw *string `form:"raw,omitempty" json:"raw,omitempty" yaml:"raw,omitempty" xml:"raw,omitempty"`
	// Scan UUID
	ScanID *uuid.UUID `form:"scan_id,omitempty" json:"scan_id,omitempty" yaml:"scan_id,omitempty" xml:"scan_id,omitempty"`
	// Scan start time
	ScanStartTime *time.Time `` /* 130-byte string literal not displayed */
}

RawPayload user type.

type ReportPayload

type ReportPayload struct {
	// Check UUID
	CheckID *uuid.UUID `form:"check_id,omitempty" json:"check_id,omitempty" yaml:"check_id,omitempty" xml:"check_id,omitempty"`
	// Report of a Check. It's a JSON containing the value of the report
	Report *string `form:"report,omitempty" json:"report,omitempty" yaml:"report,omitempty" xml:"report,omitempty"`
	// Scan UUID
	ScanID *uuid.UUID `form:"scan_id,omitempty" json:"scan_id,omitempty" yaml:"scan_id,omitempty" xml:"scan_id,omitempty"`
	// Scan start time
	ScanStartTime *time.Time `` /* 130-byte string literal not displayed */
}

ReportPayload user type.

func (*ReportPayload) Validate

func (ut *ReportPayload) Validate() (err error)

Validate validates the ReportPayload type instance.

Jump to

Keyboard shortcuts

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