rediskey

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const ActiveGamesZSet = "automuteus:games"
View Source
const CachedUserDataExpiration = time.Hour * 12
View Source
const Commit = "automuteus:commit"
View Source
const EventsNamespace = "automuteus:capture:events"
View Source
const JobNamespace = "automuteus:jobs:"
View Source
const NotFound = -1
View Source
const TotalGameExpiration = time.Minute * 5
View Source
const TotalGames = "automuteus:games:total"
View Source
const TotalGuildsSet = "automuteus:count:guilds"
View Source
const TotalUsers = "automuteus:users:total"
View Source
const TotalUsersExpiration = time.Minute * 5
View Source
const Version = "automuteus:version"

Variables

This section is empty.

Functions

func ActiveGamesForGuild

func ActiveGamesForGuild(guildID string) string

func BotTokenIdentifyLock

func BotTokenIdentifyLock(token string) string

func CachedUserInfoOnGuild

func CachedUserInfoOnGuild(userID, guildID string) string

func CompleteTask

func CompleteTask(taskID string) string

func ConnectCodeData

func ConnectCodeData(guildID, connCode string) string

func ConnectCodePtr

func ConnectCodePtr(guildID, code string) string

func GetActiveGames

func GetActiveGames(ctx context.Context, client *redis.Client, secs int64) int64

func GetCachedUserInfo

func GetCachedUserInfo(ctx context.Context, client *redis.Client, userID, guildID string) string

func GetGuildCounter

func GetGuildCounter(ctx context.Context, client *redis.Client) int64

func GetTotalGames

func GetTotalGames(ctx context.Context, client *redis.Client) int64

func GetTotalUsers

func GetTotalUsers(ctx context.Context, client *redis.Client) int64

func GetVersionAndCommit

func GetVersionAndCommit(ctx context.Context, client *redis.Client) (string, string)

func GuildCacheHash

func GuildCacheHash(guildID string) string

func GuildSettings

func GuildSettings(id HashedID) string

func GuildTokenLock

func GuildTokenLock(guildID, hToken string) string

func IsGameInTextChannel

func IsGameInTextChannel(ctx context.Context, client *redis.Client, guildID, textChannelID string) (bool, error)

func IsGameInVoiceChannel

func IsGameInVoiceChannel(ctx context.Context, client *redis.Client, guildID, voiceChannelID string) (bool, error)

func RefreshTotalGames

func RefreshTotalGames(ctx context.Context, client *redis.Client, pool *pgxpool.Pool) int64

func RefreshTotalUsers

func RefreshTotalUsers(ctx context.Context, client *redis.Client, pool *pgxpool.Pool) int64

func RequestsByType

func RequestsByType(typeStr string) string

func RoomCodesForConnCode

func RoomCodesForConnCode(connCode string) string

func SetCachedUserInfo

func SetCachedUserInfo(ctx context.Context, client *redis.Client, userID, guildID, userData string) error

func SetVersionAndCommit

func SetVersionAndCommit(ctx context.Context, client *redis.Client, version, commit string)

func SnowflakeLockID

func SnowflakeLockID(snowflake string) string

func TasksList

func TasksList(connectCode string) string

func TextChannelPtr

func TextChannelPtr(guildID, channelID string) string

func UserRateLimitGeneral

func UserRateLimitGeneral(userID string) string

func UserRateLimitSpecific

func UserRateLimitSpecific(userID, cmdType string) string

func UserSoftban

func UserSoftban(userID string) string

func UserSoftbanCount

func UserSoftbanCount(userID string) string

func VoiceChangesForGameCodeLock

func VoiceChangesForGameCodeLock(connectCode string) string

func VoiceChannelPtr

func VoiceChannelPtr(guildID, channelID string) string

Types

type HashedID

type HashedID string

func HashGuildID

func HashGuildID(guildID string) HashedID

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL