Versions in this module Expand all Collapse all v1 v1.1.0 Feb 11, 2022 Changes in this version type Config + Signer signer.Signer v1.0.0 Aug 31, 2021 Changes in this version + const Version + type Client struct + func New(cfg Config) (*Client, error) + func (c *Client) DiscoverNodes() error + func (c *Client) Metrics() (Metrics, error) + func (c *Client) Perform(req *http.Request) (*http.Response, error) + func (c *Client) URLs() []*url.URL + type ColorLogger struct + EnableRequestBody bool + EnableResponseBody bool + Output io.Writer + func (l *ColorLogger) LogRoundTrip(req *http.Request, res *http.Response, err error, start time.Time, ...) error + func (l *ColorLogger) RequestBodyEnabled() bool + func (l *ColorLogger) ResponseBodyEnabled() bool + type Config struct + CACert []byte + CompressRequestBody bool + ConnectionPoolFunc func([]*Connection, Selector) ConnectionPool + DisableRetry bool + DiscoverNodesInterval time.Duration + EnableDebugLogger bool + EnableMetrics bool + EnableRetryOnTimeout bool + Header http.Header + Logger Logger + MaxRetries int + Password string + RetryBackoff func(attempt int) time.Duration + RetryOnStatus []int + Selector Selector + Transport http.RoundTripper + URLs []*url.URL + Username string + type Connection struct + Attributes map[string]interface{} + DeadSince time.Time + Failures int + ID string + IsDead bool + Name string + Roles []string + URL *url.URL + func (c *Connection) String() string + type ConnectionMetric struct + DeadSince *time.Time + Failures int + IsDead bool + Meta struct{ ... } + URL string + func (cm ConnectionMetric) String() string + type ConnectionPool interface + Next func() (*Connection, error) + OnFailure func(*Connection) error + OnSuccess func(*Connection) error + URLs func() []*url.URL + func NewConnectionPool(conns []*Connection, selector Selector) (ConnectionPool, error) + type CurlLogger struct + EnableRequestBody bool + EnableResponseBody bool + Output io.Writer + func (l *CurlLogger) LogRoundTrip(req *http.Request, res *http.Response, err error, start time.Time, ...) error + func (l *CurlLogger) RequestBodyEnabled() bool + func (l *CurlLogger) ResponseBodyEnabled() bool + type DebuggingLogger interface + Log func(a ...interface{}) error + Logf func(format string, a ...interface{}) error + type Discoverable interface + DiscoverNodes func() error + type Interface interface + Perform func(*http.Request) (*http.Response, error) + type JSONLogger struct + EnableRequestBody bool + EnableResponseBody bool + Output io.Writer + func (l *JSONLogger) LogRoundTrip(req *http.Request, res *http.Response, err error, start time.Time, ...) error + func (l *JSONLogger) RequestBodyEnabled() bool + func (l *JSONLogger) ResponseBodyEnabled() bool + type Logger interface + LogRoundTrip func(*http.Request, *http.Response, error, time.Time, time.Duration) error + RequestBodyEnabled func() bool + ResponseBodyEnabled func() bool + type Measurable interface + Metrics func() (Metrics, error) + type Metrics struct + Connections []fmt.Stringer + Failures int + Requests int + Responses map[int]int + func (m Metrics) String() string + type Selector interface + Select func([]*Connection) (*Connection, error) + type TextLogger struct + EnableRequestBody bool + EnableResponseBody bool + Output io.Writer + func (l *TextLogger) LogRoundTrip(req *http.Request, res *http.Response, err error, start time.Time, ...) error + func (l *TextLogger) RequestBodyEnabled() bool + func (l *TextLogger) ResponseBodyEnabled() bool Other modules containing this package github.com/opensearch-project/opensearch-go/v2 github.com/opensearch-project/opensearch-go/v3 github.com/opensearch-project/opensearch-go/v4