Documentation
¶
Overview ¶
Package helpers contains deterministic, non-secret helpers for native plugins.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccountTag ¶
func AccountTag(username string, options AccountTagOptions) string
AccountTag returns a Redis Cluster hash-tag for account-scoped keys.
func CountryName ¶
CountryName returns the Lua-compatible display name for a country code.
func IsRoutableIP ¶
IsRoutableIP reports whether ip is suitable for public internet routing decisions.
func ScopedIP ¶
func ScopedIP(ip string, options IPScopingOptions) string
ScopedIP returns ip or a configured network identifier for stable cache and Redis keys.
Types ¶
type AccountTagOptions ¶
AccountTagOptions controls Redis Cluster hash-tag generation for account keys.
func DefaultAccountTagOptions ¶
func DefaultAccountTagOptions() AccountTagOptions
DefaultAccountTagOptions returns the Lua-compatible account hash-tag defaults.
type IPScopingOptions ¶
IPScopingOptions controls deterministic IP network scoping.
Click to show internal directories.
Click to hide internal directories.