regioninfomanager

package
v0.8.15 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const KEY_COLUMN_NAME = "region_name"

====================================================================

Variables

This section is empty.

Functions

func UnRegisterRegion

func UnRegisterRegion(regionName string) (bool, error)

Types

type RegionInfo

type RegionInfo struct {
	RegionName        string           `gorm:"primaryKey"` // ex) "region01"
	ProviderName      string           // ex) "GCP"
	KeyValueInfoList  infostore.KVList `gorm:"type:text"` // stored with json format, ex) { {region, us-east1}, {zone, us-east1-c}, ...}
	AvailableZoneList infostore.AZList `gorm:"type:text"` // stored with json format, ex) { us-east1-c, us-east1-d, ...}
}

func GetRegion

func GetRegion(regionName string) (*RegionInfo, error)

1. check params 2. get RegionIfno from info-store

func ListRegion

func ListRegion() ([]*RegionInfo, error)

func RegisterRegion

func RegisterRegion(regionName string, providerName string, keyValueInfoList []icdrs.KeyValue, AZList []string) (*RegionInfo, error)

func RegisterRegionInfo

func RegisterRegionInfo(rgnInfo RegionInfo) (*RegionInfo, error)

1. check params 2. insert them into info-store

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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