package services import ( "fmt" "go_dreamfactory/sys/configure" "github.com/liwei1dao/lego/base/rpcx" "github.com/liwei1dao/lego/sys/log" ) type ServiceBase struct { rpcx.RPCXService } func (this *ServiceBase) InitSys() { this.RPCXService.InitSys() if err := configure.OnInit(this.GetSettings().Sys["configure"]); err != nil { panic(fmt.Sprintf("init sys.configure err: %s", err.Error())) } else { log.Infof("init sys.configure success!") } }