cloud

package
v0.38.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudHandler

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

func NewHandler

func NewHandler(doer doer) CloudHandler

func (*CloudHandler) ListClouds

func (h *CloudHandler) ListClouds(ctx context.Context) ([]CloudOut, error)

func (*CloudHandler) ListProjectClouds

func (h *CloudHandler) ListProjectClouds(ctx context.Context, project string) ([]CloudOut, error)

type CloudOut

type CloudOut struct {
	CloudDescription    *string  `json:"cloud_description,omitempty"`    // Cloud provider and location
	CloudName           string   `json:"cloud_name"`                     // Target cloud
	GeoLatitude         *float64 `json:"geo_latitude,omitempty"`         // Approximate geographic latitude of the datacenters
	GeoLongitude        *float64 `json:"geo_longitude,omitempty"`        // Approximate geographic longitude of the datacenters
	GeoRegion           string   `json:"geo_region"`                     // Geographical region
	Provider            *string  `json:"provider,omitempty"`             // Cloud provider name
	ProviderDescription *string  `json:"provider_description,omitempty"` // Cloud provider description
}

type Handler

type Handler interface {
	// ListClouds list cloud platforms
	// GET /v1/clouds
	// https://api.aiven.io/doc/#tag/Cloud_platforms/operation/ListClouds
	ListClouds(ctx context.Context) ([]CloudOut, error)

	// ListProjectClouds list cloud platforms for a project
	// GET /v1/project/{project}/clouds
	// https://api.aiven.io/doc/#tag/Cloud_platforms/operation/ListProjectClouds
	ListProjectClouds(ctx context.Context, project string) ([]CloudOut, error)
}

Jump to

Keyboard shortcuts

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