environment

package
v0.10.1 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2019 License: Apache-2.0 Imports: 13 Imported by: 6

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"`
}

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
}

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"`
	ClusterState string `yaml:"clusterState"`
}

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