This commit is contained in:
aozhiwei 2024-04-26 13:37:56 +08:00
parent d3cb56ab12
commit f3581e0a25
6 changed files with 22 additions and 2 deletions

View File

@ -130,3 +130,7 @@ func (this *app) RemoveSession(accountId string) {
delete(this.sessionHash, accountId)
}
}
func (this *app) HasTask() bool {
return false;
}

View File

@ -91,7 +91,7 @@ func (this *app) registerDataSources() {
func (this *app) AddSession(accountId string) string {
this.sessionLock.Lock()
defer this.sessionLock.Unlock()
uuid := f5.GetApp().NewUuid()
uuid := f5.GetApp().NewNodeUuid()
str := fmt.Sprintf("%s%d%s%d", accountId, uuid, randStringBytes(12), time.Now().Unix())
md5New := md5.New()
strByte := []byte(str)
@ -129,3 +129,7 @@ func (this *app) RemoveSession(accountId string) {
delete(this.sessionHash, accountId)
}
}
func (this *app) HasTask() bool {
return false
}

View File

@ -86,3 +86,7 @@ func (this *app) registerDataSources() {
func (this *app) GetHttpListenPort() int32 {
return mt.Table.HallCluster.GetHttpListenPort()
}
func (this *app) HasTask() bool {
return !this.netMsgQueue.IsEmpty()
}

View File

@ -41,7 +41,7 @@ func (this *roomMgr) genRoomId() int32 {
}
func (this *roomMgr) genRoomIdx() int64 {
return f5.GetApp().NewUuid()
return f5.GetApp().NewNodeUuid()
}
func (this *roomMgr) ProcessCMMsg(handler *cs.CsNetMsgHandler, hdr *f5.MsgHdr) {

View File

@ -55,3 +55,7 @@ func (this *app) registerDataSources() {
mt.Table.MailDb.GetById(0).GetDatabase(),
30)
}
func (this *app) HasTask() bool {
return false
}

View File

@ -86,3 +86,7 @@ func (this *app) registerDataSources() {
func (this *app) GetHttpListenPort() int32 {
return mt.Table.MatchCluster.GetHttpListenPort()
}
func (this *app) HasTask() bool {
return !this.netMsgQueue.IsEmpty()
}