http

package
v0.97.0 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2024 License: Apache-2.0 Imports: 8 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 {
	// contains filtered or unexported fields
}

Client is an HTTP client.

func NewClient

func NewClient(env *iruntime.Env) *Client

NewClient creates a new HTTP client.

func (*Client) Send

func (c *Client) Send(
	method string,
	path string,
	req any,
	resp any,
) error

Send sends a request to the server.

We use this client instead of using gRPC as we don't know if an ingress controller in a customer's environment supports gRPC.

func (*Client) SendRequest added in v0.26.0

func (c *Client) SendRequest(
	method string,
	path string,
	req any,
) (io.ReadCloser, error)

SendRequest sends a request to the server and returns the response body.

Jump to

Keyboard shortcuts

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