This commit is contained in:
aozhiwei 2024-04-02 08:54:26 +08:00
parent e00021c79e
commit be61f12023

View File

@ -35,7 +35,7 @@ func (this *guildMgr) loadFromDB() {
} }
func (this *guildMgr) loadGuild() { func (this *guildMgr) loadGuild() {
f5.GetSysLog().Info("friendMgr.loadFriendships begin") f5.GetSysLog().Info("loadGuild begin")
lastIdx := f5.GetJsStyleDb().SyncBatchLoadFullTable( lastIdx := f5.GetJsStyleDb().SyncBatchLoadFullTable(
constant.FRIEND_DB, constant.FRIEND_DB,
"SELECT * FROM t_guild idx > %d AND deleted = 0", "SELECT * FROM t_guild idx > %d AND deleted = 0",
@ -45,16 +45,16 @@ func (this *guildMgr) loadGuild() {
this.nameHash[p.guildName] = p this.nameHash[p.guildName] = p
}, },
func (err error) { func (err error) {
panic(fmt.Sprintf("friendMgr.loadFriendships dberror:%s", err)) panic(fmt.Sprintf("loadGuild dberror:%s", err))
}) })
f5.GetSysLog().Info("friendMgr.loadFriendships end lastIdx:%d friendNum:%d blackNum:%d", f5.GetSysLog().Info("loadGuild end lastIdx:%d idNum:%d nameNum:%d",
lastIdx, lastIdx,
len(this.idHash), len(this.idHash),
len(this.nameHash)) len(this.nameHash))
} }
func (this *guildMgr) loadGuildMember() { func (this *guildMgr) loadGuildMember() {
f5.GetSysLog().Info("friendMgr.loadFriendships begin") f5.GetSysLog().Info("loadGuildMember begin")
lastIdx := f5.GetJsStyleDb().SyncBatchLoadFullTable( lastIdx := f5.GetJsStyleDb().SyncBatchLoadFullTable(
constant.FRIEND_DB, constant.FRIEND_DB,
"SELECT * FROM t_guild_member idx > %d AND deleted = 0", "SELECT * FROM t_guild_member idx > %d AND deleted = 0",
@ -67,12 +67,11 @@ func (this *guildMgr) loadGuildMember() {
} }
}, },
func (err error) { func (err error) {
panic(fmt.Sprintf("friendMgr.loadFriendships dberror:%s", err)) panic(fmt.Sprintf("loadGuildMember dberror:%s", err))
}) })
f5.GetSysLog().Info("friendMgr.loadFriendships end lastIdx:%d friendNum:%d blackNum:%d", f5.GetSysLog().Info("loadGuildMember end memberNum:%d",
lastIdx, lastIdx,
len(this.idHash), len(this.accountIdHash))
len(this.nameHash))
} }
func (this *guildMgr) isNameTooLong(name string, maxNum int) bool { func (this *guildMgr) isNameTooLong(name string, maxNum int) bool {