Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrObtainingForVersion = fmt.Errorf("waiting for the cluster version to be loaded")
ErrObtainingForVersion An error due to cluster version client collection
var ErrTooLong = fmt.Errorf("the incoming sample data is too long")
ErrTooLong An error for sample data that is too long
var ErrWaitingForVersion = fmt.Errorf("waiting for the cluster version to be loaded")
ErrWaitingForVersion An error due to cluster version responding slowly
Functions ¶
func LimitReader ¶
LimitReader returns a Reader that reads from r but stops with ErrTooLong after n bytes. The underlying implementation is a *LimitedReader.
func NewLimitReadCloser ¶
func NewLimitReadCloser(r io.ReadCloser, n int64) io.ReadCloser
NewLimitReadCloser Initialize a new limitReadCloser object
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client The client structure for making requests to cloud.redhat.com
func New ¶
func New(client *http.Client, maxBytes int64, certPath string, metricsName string, proxyCtrl *proxycontrol.ProxyControl, reqDecorator *requestdecorator.RequestDecorator) *Client
New Initialize a new client object
func (*Client) GetMultiPartBodyAndHeaders ¶
GetMultiPartBodyAndHeaders Get multi-part body and headers for upload
type LimitedReader ¶
A LimitedReader reads from R but limits the amount of data returned to just N bytes. Each call to Read updates N to reflect the new amount remaining. Read returns ErrTooLong when N <= 0 or when the underlying R returns EOF.