flavorcache

package
v0.0.0-...-6897187 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const RefreshFailureTime time.Duration = 60 * time.Second // This controls how often we try to get a look at a failed flavor
View Source
const StaledTime time.Duration = 300 * time.Second

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

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

func New

func New() *Cache

func (*Cache) Get

func (fc *Cache) Get(osService openStackInstanceService, flavorName string) (*flavors.Flavor, error)

Get returns flavor information, or an error, as retrieved less than ${cache-ttl} ago. The cache TTL is different for successful and unsuccessful results; see StaledTime and RefreshFailureTime above.

Jump to

Keyboard shortcuts

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