Documentation ¶
Index ¶
- Constants
- func GetAuthInfo() (auth *user.AuthToken)
- func GetClientUserName() string
- func GetClientUserSecret() string
- func GetDBMongoAddrs() []string
- func GetDBMongoAuth() *mongo.Auth
- func GetDBMongoTimeout() time.Duration
- func GetFsWorkdir() string
- func GetHttpBind() string
- func GetHttpHost() string
- func GetHttpPort() int
- func GetRpcBind() string
- func GetRpcHost() string
- func GetRpcOptionMaxRecvMsgSize() int
- func GetRpcOptionMaxRecvMsgSizeMB() int
- func GetRpcOptionMaxSendMsgSize() int
- func GetRpcOptionMaxSendMsgSizeMB() int
- func GetRpcPort() int
- func InitMongoClient() (client *mongo.Client, err error)
- func LoadConfig(path string) (err error)
- func SetClientUserName(user string) error
- func SetClientUserSecret(secret string) error
Constants ¶
View Source
const ( // RPC Section KeyRpcBind = "rpc.bind" KeyRpcHost = "rpc.host" KeyRpcPort = "rpc.port" KeyRpcOptionMaxRecvMsgSizeMB = "rpc.option.max_recv_msg_size_mb" KeyRpcOptionMaxSendMsgSizeMB = "rpc.option.max_send_msg_size_mb" KeyHttpBind = "rpc.http.bind" KeyHttpHost = "rpc.http.host" KeyHttpPort = "rpc.http.port" // Database KeyDBMongoAddrs = "db.mongo.addrs" KeyDBMongoPerformAuth = "db.mongo.with_auth" KeyDBMongoAuthDatabase = "db.mongo.auth.db" KeyDBMongoAuthUser = "db.mongo.auth.user" KeyDBMongoAuthPass = "db.mongo.auth.pass" KeyDBMongoAuthMechanism = "db.mongo.auth.mechanism" KeyDBMongoTimeoutSec = "db.mongo.timeout_sec" KeyDBMongoDatabase = "db.mongo.db" // Client KeyClientUserName = "client.user.name" KeyClientUserSecret = "client.user.secret" KeyClientProject = "client.project" KeyFsWorkdir = "fs.workdir" )
Variables ¶
This section is empty.
Functions ¶
func GetAuthInfo ¶
func GetClientUserName ¶
func GetClientUserName() string
func GetClientUserSecret ¶
func GetClientUserSecret() string
func GetDBMongoAddrs ¶
func GetDBMongoAddrs() []string
func GetDBMongoAuth ¶
func GetDBMongoTimeout ¶
func GetFsWorkdir ¶
func GetFsWorkdir() string
func GetHttpBind ¶
func GetHttpBind() string
func GetHttpHost ¶
func GetHttpHost() string
func GetHttpPort ¶
func GetHttpPort() int
func GetRpcBind ¶
func GetRpcBind() string
func GetRpcHost ¶
func GetRpcHost() string
func GetRpcOptionMaxRecvMsgSize ¶
func GetRpcOptionMaxRecvMsgSize() int
func GetRpcOptionMaxRecvMsgSizeMB ¶
func GetRpcOptionMaxRecvMsgSizeMB() int
func GetRpcOptionMaxSendMsgSize ¶
func GetRpcOptionMaxSendMsgSize() int
func GetRpcOptionMaxSendMsgSizeMB ¶
func GetRpcOptionMaxSendMsgSizeMB() int
func GetRpcPort ¶
func GetRpcPort() int
func InitMongoClient ¶
func LoadConfig ¶
this function will search and load configurations
func SetClientUserName ¶
func SetClientUserSecret ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.