server

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2022 License: Apache-2.0 Imports: 81 Imported by: 2

Documentation

Overview

Package server contains the code to run the dbnode server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(runOpts RunOptions)

Run runs the server programmatically given a filename for the configuration file.

Types

type RunOptions

type RunOptions struct {
	// ConfigFile is the YAML configuration file to use to run the server.
	ConfigFile string

	// Config is an alternate way to provide configuration and will be used
	// instead of parsing ConfigFile if ConfigFile is not specified.
	Config config.DBConfiguration

	// BootstrapCh is a channel to listen on to be notified of bootstrap.
	BootstrapCh chan<- struct{}

	// EmbeddedKVCh is a channel to listen on to be notified that the embedded KV has bootstrapped.
	EmbeddedKVCh chan<- struct{}

	// ClientCh is a channel to listen on to share the same m3db client that this server uses.
	ClientCh chan<- client.Client

	// ClusterClientCh is a channel to listen on to share the same m3 cluster client that this server uses.
	ClusterClientCh chan<- clusterclient.Client

	// KVStoreCh is a channel to listen on to share the same m3 kv store client that this server uses.
	KVStoreCh chan<- kv.Store

	// InterruptCh is a programmatic interrupt channel to supply to
	// interrupt and shutdown the server.
	InterruptCh <-chan error

	// ShutdownCh is an optional channel to supply if interested in receiving
	// a notification that the server has shutdown.
	ShutdownCh chan<- struct{}

	// CustomOptions are custom options to apply to the session.
	CustomOptions []client.CustomAdminOption

	// Transform is a function to transform the Options.
	Transform storage.OptionTransform

	// StorageOptions are additional storage options.
	StorageOptions StorageOptions

	// CustomBuildTags are additional tags to be added to the instrument build
	// reporter.
	CustomBuildTags map[string]string
}

RunOptions provides options for running the server with backwards compatibility if only solely adding fields.

type StorageOptions added in v0.15.0

type StorageOptions struct {
	TChanChannelFn    node.NewTChanChannelFn
	TChanNodeServerFn node.NewTChanNodeServerFn
}

StorageOptions are options to apply to the database storage options.

Jump to

Keyboard shortcuts

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