chore: refresh gramsrv public release

This commit is contained in:
A 2026-06-30 14:37:43 +08:00
parent 75cebe8dbf
commit 70b6820474
1274 changed files with 378751 additions and 59919 deletions

View file

@ -0,0 +1,32 @@
package readmodel
import (
"encoding/binary"
"hash/fnv"
)
const (
ModelDialogLight = "dialog_light"
ModelContactAccount = "contact_account"
ModelChannelBase = "channel_base"
ModelChannelMember = "channel_member"
ModelChannelActiveIDs = "channel_active_memberships"
ModelChannelMediaCounts = "channel_media_counts"
ModelPrivateMediaCounts = "private_media_counts"
ModelChannelParticipants = "channel_participants"
ModelChannelSelfBoosts = "channel_self_boosts"
)
func MixHashes(values ...int64) int64 {
h := fnv.New64a()
var buf [8]byte
for _, value := range values {
binary.LittleEndian.PutUint64(buf[:], uint64(value))
_, _ = h.Write(buf[:])
}
sum := int64(h.Sum64() & 0x7fffffffffffffff)
if sum == 0 {
return 1
}
return sum
}