http

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package http is Datly's default implementation of the public outbound HTTP client contract (github.com/viant/xdatly/client/http). One Client is built per distinct typed Options value; it applies the configured static headers, timeout and response-size bound to every explicit request it executes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Validate

func Validate(options xhttp.Options) error

Validate checks the complete declaration without opening any connection.

Types

type Client

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

Client implements xhttp.Client for one configured destination.

func New

func New(options xhttp.Options) (*Client, error)

New validates options and builds the client.

func (*Client) Close

func (c *Client) Close() error

Close releases idle connections. Only the provider owner calls it.

func (*Client) Do

func (c *Client) Do(request *http.Request) (*http.Response, error)

Do executes one explicit request against the configured destination. Static headers fill in only names the request did not set; the request context is bounded by the configured timeout, and the response body errors once it exceeds the configured byte limit.

func (*Client) Identity

func (c *Client) Identity() string

Identity is the digest of the options the client was built from.

Jump to

Keyboard shortcuts

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