处理网关模块依赖报错问题
This commit is contained in:
parent
9d2623904f
commit
76377b5e28
@ -26,7 +26,6 @@ type Equipment struct {
|
||||
api *apiComp
|
||||
configure *configureComp
|
||||
modelEquipment *modelEquipmentComp
|
||||
hero comm.IHero
|
||||
}
|
||||
|
||||
//模块名
|
||||
@ -44,12 +43,6 @@ func (this *Equipment) Init(service core.IService, module core.IModule, options
|
||||
//模块启动接口
|
||||
func (this *Equipment) Start() (err error) {
|
||||
err = this.ModuleBase.Start()
|
||||
var module interface{}
|
||||
if module, err = this.service.GetModule(comm.ModuleHero); err != nil {
|
||||
log.Errorf("Equipment Start err:%v", err)
|
||||
return
|
||||
}
|
||||
this.hero = module.(comm.IHero)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -2,10 +2,10 @@ package gateway
|
||||
|
||||
import (
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules"
|
||||
|
||||
"go_dreamfactory/lego/base"
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/lego/core/cbase"
|
||||
"go_dreamfactory/lego/sys/log"
|
||||
)
|
||||
|
||||
@ -21,7 +21,7 @@ func NewModule() core.IModule {
|
||||
}
|
||||
|
||||
type Gateway struct {
|
||||
modules.ModuleBase
|
||||
cbase.ModuleBase
|
||||
service base.IRPCXService // rpcx服务接口 主要client->server
|
||||
wsService *WSServiceComp // websocket服务 监听websocket连接
|
||||
agentMgr *AgentMgrComp // 客户端websocket连接管理
|
||||
|
Loading…
Reference in New Issue
Block a user