fix: wrong usage of RLock

This commit is contained in:
wwqgtxx
2024-07-22 09:57:57 +08:00
parent fd5b537ab1
commit 4eb13a73bf
5 changed files with 42 additions and 20 deletions

View File

@@ -205,7 +205,6 @@ func strategyStickySessions(url string) strategyFn {
proxy := proxies[nowIdx]
if proxy.AliveForTestUrl(url) {
if nowIdx != idx {
lruCache.Delete(key)
lruCache.Set(key, nowIdx)
}
@@ -215,7 +214,6 @@ func strategyStickySessions(url string) strategyFn {
}
}
lruCache.Delete(key)
lruCache.Set(key, 0)
return proxies[0]
}