Fixing clustering problem (#4320)
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
57eb69927c
Коммит
3e1fc76bf9
@@ -474,6 +474,14 @@ func GetSession(token string) *model.Session {
|
||||
|
||||
func RemoveAllSessionsForUserId(userId string) {
|
||||
|
||||
RemoveAllSessionsForUserIdSkipClusterSend(userId)
|
||||
|
||||
if einterfaces.GetClusterInterface() != nil {
|
||||
einterfaces.GetClusterInterface().RemoveAllSessionsForUserId(userId)
|
||||
}
|
||||
}
|
||||
|
||||
func RemoveAllSessionsForUserIdSkipClusterSend(userId string) {
|
||||
keys := sessionCache.Keys()
|
||||
|
||||
for _, key := range keys {
|
||||
@@ -485,9 +493,6 @@ func RemoveAllSessionsForUserId(userId string) {
|
||||
}
|
||||
}
|
||||
|
||||
if einterfaces.GetClusterInterface() != nil {
|
||||
einterfaces.GetClusterInterface().RemoveAllSessionsForUserId(userId)
|
||||
}
|
||||
}
|
||||
|
||||
func AddSessionToCache(session *model.Session) {
|
||||
|
||||
Ссылка в новой задаче
Block a user