Documentation ¶
Index ¶
Constants ¶
View Source
const ( Inject_Config = "Config" Inject_ZAPLOGGER = "ZapLogger" Inject_LOGGER = "Logger" Inject_Node_LOGGER = "NodeLogger" Inject_Web_LOGGER = "WebLogger" Inject_GRPC_LOGGER = "GRPCLogger" Inject_Redis_LOGGER = "RedisLogger" Inject_Mysql_LOGGER = "MysqlLogger" Inject_Redis_Service = "RedisService" Inject_Mysql_Service = "MysqlService" Inject_Trace_Service = "TraceService" Inject_Basic_Service = "BasicService" Inject_User_Service = "UserService" Inject_Crypto_Service = "CryptoService" Inject_TinyURL_Service = "TinyURLService" Inject_Pastebin_Service = "PastebinService" Inject_Blog_Service = "BlogService" Inject_Cos_Service = "CosService" Inject_Web_Service = "WebService" Inject_GRPC_Service = "GRPCService" Inject_Node_Service = "NodeService" )
Variables ¶
View Source
var ( // RootCmd the root command RootCmd = &cobra.Command{ Use: "root", Short: "Root Command", PersistentPreRunE: func(cmd *cobra.Command, args []string) (err error) { if cmd.Name() != StartCmd.Name() { return nil } if cfg, err = config.LoadFromFile(configFile); err != nil { return err } initLogger() logger.Info("Init finished") return nil }, } )
View Source
var ( // StartCmd the start command StartCmd = &cobra.Command{ Use: "start", Short: "Start Command", RunE: func(cmd *cobra.Command, args []string) (err error) { var node gateway.NodeService if node, err = initService(); err != nil { return err } else if err = node.OnStart(); err != nil { return err } return nil }, } )
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.