re-formatted, better structure

This commit is contained in:
2025-12-01 18:09:10 +01:00
parent 4a668493c4
commit 46aef47e21
9 changed files with 328 additions and 235 deletions

16
util/cache/structs.go vendored Normal file
View File

@@ -0,0 +1,16 @@
package cache
import (
"sync"
)
type ShardedCache struct {
shards []*shard
shardMask uint32
}
type shard struct {
mu sync.RWMutex
s2c map[string]string // serverId -> channelId
c2s map[string]string // channelId -> serverId
}