integrationclient

package
v0.0.0-...-b258b02 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotAllowed = errors.New("Not allowed")

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(httpClient *http.Client, authenticationURL string, resourcesAllowedURL string, usageURL string) *Client

func (*Client) Authenticate

func (client *Client) Authenticate(runID string, apiKey string) error

func (*Client) ReportMemoryUsage

func (client *Client) ReportMemoryUsage(runID string, memory uint64, duration time.Duration) error

ReportMemoryUsage lets an external system know about some memory usage

func (*Client) ReportNetworkUsage

func (client *Client) ReportNetworkUsage(runID string, source string, in uint64, out uint64) error

ReportNetworkUsage lets an external system know about some network usage

func (*Client) ResourcesAllowed

func (client *Client) ResourcesAllowed(runID string, memory int64, maxRunTime int64) error

Jump to

Keyboard shortcuts

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