Documentation ¶
Index ¶
Constants ¶
View Source
const ( VERSION = "0.0.17" GAUGE = "GAUGE" COUNTER = "COUNTER" DERIVE = "DERIVE" DEFAULT_STEP = 60 )
View Source
const (
COMMIT = "e249d8a"
)
Variables ¶
View Source
var (
ConfigFile string
)
Functions ¶
func ParseConfig ¶
func ParseConfig(cfg string)
Types ¶
type ClusterNode ¶
type ClusterNode struct {
Addrs []string `json:"addrs"`
}
CLUSTER NODE
func NewClusterNode ¶
func NewClusterNode(addrs []string) *ClusterNode
type GlobalConfig ¶
type GlobalConfig struct { Debug bool `json:"debug"` MinStep int `json:"minStep"` //最小周期,单位sec Http *HttpConfig `json:"http"` Rpc *RpcConfig `json:"rpc"` Socket *SocketConfig `json:"socket"` Judge *JudgeConfig `json:"judge"` Graph *GraphConfig `json:"graph"` Tsdb *TsdbConfig `json:"tsdb"` }
func Config ¶
func Config() *GlobalConfig
type GraphConfig ¶
type GraphConfig struct { Enabled bool `json:"enabled"` Batch int `json:"batch"` ConnTimeout int `json:"connTimeout"` CallTimeout int `json:"callTimeout"` MaxConns int `json:"maxConns"` MaxIdle int `json:"maxIdle"` Replicas int `json:"replicas"` Cluster map[string]string `json:"cluster"` ClusterList map[string]*ClusterNode `json:"clusterList"` }
type HttpConfig ¶
type JudgeConfig ¶
type JudgeConfig struct { Enabled bool `json:"enabled"` Batch int `json:"batch"` ConnTimeout int `json:"connTimeout"` CallTimeout int `json:"callTimeout"` MaxConns int `json:"maxConns"` MaxIdle int `json:"maxIdle"` Replicas int `json:"replicas"` Cluster map[string]string `json:"cluster"` ClusterList map[string]*ClusterNode `json:"clusterList"` }
type SocketConfig ¶
Click to show internal directories.
Click to hide internal directories.