Documentation ¶
Index ¶
Constants ¶
View Source
const ( // GtctlDir is the root directory that contains states of cluster info. GtctlDir = ".gtctl" DefaultEtcdVersion = "v3.5.7" DefaultGreptimeVersion = "latest" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Cluster *Cluster `yaml:"cluster" validate:"required"` Etcd *Etcd `yaml:"etcd" validate:"required"` }
Config is the desired state of a GreptimeDB cluster on bare metal.
The field of Config that with `validate` tag will be validated against its requirement. Each filed has only one requirement.
Each field of Config can also have its own exported method `Validate`.
func DefaultConfig ¶
func DefaultConfig() *Config
type Datanode ¶
type Datanode struct { Replicas int `yaml:"replicas" validate:"gt=0"` NodeID int `yaml:"nodeID" validate:"gte=0"` RPCAddr string `yaml:"rpcAddr" validate:"required,hostname_port"` HTTPAddr string `yaml:"httpAddr" validate:"required,hostname_port"` DataDir string `yaml:"dataDir" validate:"omitempty,dirpath"` WalDir string `yaml:"walDir" validate:"omitempty,dirpath"` ProcedureDir string `yaml:"procedureDir" validate:"omitempty,dirpath"` LogLevel string `yaml:"logLevel"` }
type Frontend ¶
type Frontend struct { Replicas int `yaml:"replicas" validate:"gt=0"` GRPCAddr string `yaml:"grpcAddr" validate:"omitempty,hostname_port"` HTTPAddr string `yaml:"httpAddr" validate:"omitempty,hostname_port"` PostgresAddr string `yaml:"postgresAddr" validate:"omitempty,hostname_port"` MetaAddr string `yaml:"metaAddr" validate:"omitempty,hostname_port"` LogLevel string `yaml:"logLevel"` }
type MetaSrv ¶
type MetaSrv struct { StoreAddr string `yaml:"storeAddr" validate:"hostname_port"` ServerAddr string `yaml:"serverAddr" validate:"hostname_port"` BindAddr string `yaml:"bindAddr" validate:"omitempty,hostname_port"` HTTPAddr string `yaml:"httpAddr" validate:"required,hostname_port"` LogLevel string `yaml:"logLevel"` }
Click to show internal directories.
Click to hide internal directories.