MCPcopy Create free account
hub / github.com/GoSimplicity/LinkMe / GenerateCacheKey

Method GenerateCacheKey

internal/repository/cache/relation.go:98–102  ·  view source on GitHub ↗
(userID int64, relationType string, pagination domain.Pagination)

Source from the content-addressed store, hash-verified

96}
97
98func (c *relationCache) GenerateCacheKey(userID int64, relationType string, pagination domain.Pagination) string {
99 // 生成缓存键
100 return fmt.Sprintf("relation:%s:%d:offset=%d:size=%d",
101 relationType, userID, *pagination.Offset, *pagination.Size)
102}
103
104func (c *relationCache) GenerateCountCacheKey(userID int64, relationType string) string {
105 // 生成计数缓存键

Callers 1

ClearFollowCacheMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected