environment

package
v0.4.4 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2018 License: Apache-2.0 Imports: 14 Imported by: 5 modules, 6 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	// Service is used when a topology initializer is not supplied.
	Service *etcdclient.Configuration `yaml:"service"`

	// StaticConfiguration is used for running M3DB with a static config
	Static *StaticConfiguration `yaml:"static"`

	// Presence of a (etcd) server in this config denotes an embedded cluster
	SeedNodes *SeedNodesConfig `yaml:"seedNodes"`

	// NamespaceResolutionTimeout is the maximum time to wait to discover namespaces from KV
	NamespaceResolutionTimeout time.Duration `yaml:"namespaceResolutionTimeout"`

	// TopologyResolutionTimeout is the maximum time to wait for a topology from KV
	TopologyResolutionTimeout time.Duration `yaml:"topologyResolutionTimeout"`
}

Configuration is a configuration that can be used to create namespaces, a topology, and kv store

func (Configuration) Configure

func (c Configuration) Configure(cfgParams ConfigurationParameters) (ConfigureResults, error)

Configure creates a new ConfigureResults

type ConfigurationParameters

type ConfigurationParameters struct {
	InstrumentOpts             instrument.Options
	HashingSeed                uint32
	HostID                     string
	NamespaceResolutionTimeout time.Duration
	TopologyResolutionTimeout  time.Duration
}

ConfigurationParameters are options used to create new ConfigureResults

type ConfigureResults

type ConfigureResults struct {
	NamespaceInitializer namespace.Initializer
	TopologyInitializer  topology.Initializer
	ClusterClient        clusterclient.Client
	KVStore              kv.Store
}

ConfigureResults stores initializers and kv store for dynamic and static configs

type SeedNode

type SeedNode struct {
	HostID   string `yaml:"hostID"`
	Endpoint string `yaml:"endpoint"`
}

SeedNode represents a seed node for the cluster

type SeedNodeSecurityConfig

type SeedNodeSecurityConfig struct {
	CAFile        string `yaml:"caFile"`
	CertFile      string `yaml:"certFile"`
	KeyFile       string `yaml:"keyFile"`
	TrustedCAFile string `yaml:"trustedCaFile"`
	CertAuth      bool   `yaml:"clientCertAuth"`
	AutoTLS       bool   `yaml:"autoTls"`
}

SeedNodeSecurityConfig contains the data used for security in seed nodes

type SeedNodesConfig

type SeedNodesConfig struct {
	RootDir                  string                 `yaml:"rootDir"`
	InitialAdvertisePeerUrls []string               `yaml:"initialAdvertisePeerUrls"`
	AdvertiseClientUrls      []string               `yaml:"advertiseClientUrls"`
	ListenPeerUrls           []string               `yaml:"listenPeerUrls"`
	ListenClientUrls         []string               `yaml:"listenClientUrls"`
	InitialCluster           []SeedNode             `yaml:"initialCluster"`
	ClientTransportSecurity  SeedNodeSecurityConfig `yaml:"clientTransportSecurity"`
	PeerTransportSecurity    SeedNodeSecurityConfig `yaml:"peerTransportSecurity"`
}

SeedNodesConfig defines fields for seed node

type StaticConfiguration

type StaticConfiguration struct {
	Namespaces     []namespace.MetadataConfiguration `yaml:"namespaces"`
	TopologyConfig *topology.StaticConfiguration     `yaml:"topology"`
	ListenAddress  string                            `yaml:"listenAddress"`
}

StaticConfiguration is used for running M3DB with a static config

Jump to

Keyboard shortcuts

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