Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Command ¶
type Command struct { Server *pilosa.Server // Configuration. Config *Config // Standard input/output *pilosa.CmdIO // Started will be closed once Command.Start is finished. Started chan struct{} Handler pilosa.Handler API *pilosa.API // contains filtered or unexported fields }
Command represents the state of the pilosa server command.
func NewCommand ¶
NewCommand returns a new instance of Main.
func (*Command) GossipTransport ¶
GossipTransport allows a caller to return the gossip transport created when setting up the GossipMemberSet. This is useful if one needs to determine the allocated ephemeral port programmatically. (usually used in tests)
func (*Command) SetupServer ¶
SetupServer uses the cluster configuration to set up this server.
type CommandOption ¶
func OptCommandCloseTimeout ¶
func OptCommandCloseTimeout(d time.Duration) CommandOption
func OptCommandServerOptions ¶
func OptCommandServerOptions(opts ...pilosa.ServerOption) CommandOption
type Config ¶
type Config struct { // DataDir is the directory where Pilosa stores both indexed data and // running state such as cluster topology information. DataDir string `toml:"data-dir"` // Bind is the host:port on which Pilosa will listen. Bind string `toml:"bind"` // MaxWritesPerRequest limits the number of mutating commands that can be in // a single request to the server. This includes Set, Clear, // SetRowAttrs & SetColumnAttrs. MaxWritesPerRequest int `toml:"max-writes-per-request"` // LogPath configures where Pilosa will write logs. LogPath string `toml:"log-path"` // Verbose toggles verbose logging which can be useful for debugging. Verbose bool `toml:"verbose"` // HTTP Handler options Handler struct { // CORS Allowed Origins AllowedOrigins []string `toml:"allowed-origins"` } `toml:"handler"` // TLS TLS TLSConfig `toml:"tls"` Cluster struct { // Disabled controls whether clustering functionality is enabled. Disabled bool `toml:"disabled"` Coordinator bool `toml:"coordinator"` ReplicaN int `toml:"replicas"` Hosts []string `toml:"hosts"` LongQueryTime toml.Duration `toml:"long-query-time"` } `toml:"cluster"` // Gossip config is based around memberlist.Config. Gossip gossip.Config `toml:"gossip"` Translation struct { MapSize int `toml:"map-size"` // DEPRECATED: Translation config supports translation store replication. PrimaryURL string `toml:"primary-url"` } `toml:"translation"` AntiEntropy struct { Interval toml.Duration `toml:"interval"` } `toml:"anti-entropy"` Metric struct { // Service can be statsd, expvar, or none. Service string `toml:"service"` // Host tells the statsd client where to write. Host string `toml:"host"` PollInterval toml.Duration `toml:"poll-interval"` // Diagnostics toggles sending some limited diagnostic information to // Pilosa's developers. Diagnostics bool `toml:"diagnostics"` } `toml:"metric"` Tracing struct { // SamplerType is the type of sampler to use. SamplerType string `toml:"sampler-type"` // SamplerParam is the parameter passed to the tracing sampler. // Its meaning is dependent on the type of sampler. SamplerParam float64 `toml:"sampler-param"` // AgentHostPort is the host:port of the local agent. AgentHostPort string `toml:"agent-host-port"` } `toml:"tracing"` }
Config represents the configuration for the command.
type TLSConfig ¶
type TLSConfig struct { // CertificatePath contains the path to the certificate (.crt or .pem file) CertificatePath string `toml:"certificate"` // CertificateKeyPath contains the path to the certificate key (.key file) CertificateKeyPath string `toml:"key"` // SkipVerify disables verification for self-signed certificates SkipVerify bool `toml:"skip-verify"` }
TLSConfig contains TLS configuration
Click to show internal directories.
Click to hide internal directories.