options

package
v1.1.5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	// Name is the Name of the cache, taken from the Key in the Caches map[string]*CacheConfig
	Name string `toml:"-"`
	// Type represents the type of cache that we wish to use: "boltdb", "memory", "filesystem", or "redis"
	CacheType string `toml:"cache_type"`
	// Index provides options for the Cache Index
	Index *index.Options `toml:"index"`
	// Redis provides options for Redis caching
	Redis *redis.Options `toml:"redis"`
	// Filesystem provides options for Filesystem caching
	Filesystem *filesystem.Options `toml:"filesystem"`
	// BBolt provides options for BBolt caching
	BBolt *bbolt.Options `toml:"bbolt"`
	// Badger provides options for BadgerDB caching
	Badger *badger.Options `toml:"badger"`

	// CacheTypeID represents the internal constant for the provided CacheType string
	// and is automatically populated at startup
	CacheTypeID types.CacheType `toml:"-"`
}

Options is a collection of defining the Trickster Caching Behavior

func NewOptions

func NewOptions() *Options

NewOptions will return a pointer to an OriginConfig with the default configuration settings

func (*Options) Clone

func (cc *Options) Clone() *Options

Clone returns an exact copy of a *CachingConfig

func (*Options) Equal

func (cc *Options) Equal(cc2 *Options) bool

Equal returns true if all values in the Options references and their their child Option references are completely identical

Jump to

Keyboard shortcuts

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