closest

package
v0.0.0-...-143112b Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Endpoints

type Endpoints map[string]string

Endpoints is a map with region name as a key and an endpoint as value.

type Latencies

type Latencies map[string]time.Duration

Latencies type stores average latencies measured while accessing service endpoints.

type Regions

type Regions struct{}

Regions type selects available endpoints end finds the closest one.

func (*Regions) FindClosest

func (r *Regions) FindClosest(endpoints Endpoints) (string, error)

FindClosest method finds the closest AWS region to the caller.

type Services

type Services struct{}

Services type provides a list of supported AWS regions.

func (*Services) EndpointsForService

func (s *Services) EndpointsForService(serviceName string) (Endpoints, error)

EndpointsForService method provides a list of endpoints for a given service. US-Gov partition will be skipped.

Jump to

Keyboard shortcuts

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