MCPcopy
hub / github.com/appleboy/gin-jwt / DefaultRedisConfig

Function DefaultRedisConfig

store/redis.go:49–61  ·  view source on GitHub ↗

DefaultRedisConfig returns a default Redis configuration

()

Source from the content-addressed store, hash-verified

47
48// DefaultRedisConfig returns a default Redis configuration
49func DefaultRedisConfig() *RedisConfig {
50 return &RedisConfig{
51 Addr: "localhost:6379",
52 Password: "",
53 DB: 0,
54 CacheSize: 128 * 1024 * 1024, // 128MB
55 CacheTTL: time.Minute,
56 PoolSize: 10,
57 ConnMaxIdleTime: 30 * time.Minute,
58 ConnMaxLifetime: time.Hour,
59 KeyPrefix: "gin-jwt:",
60 }
61}
62
63// NewRedisRefreshTokenStore creates a new Redis-based refresh token store with client-side caching
64func NewRedisRefreshTokenStore(config *RedisConfig) (*RedisRefreshTokenStore, error) {

Callers 6

EnableRedisStoreMethod · 0.92
initializeRedisStoreMethod · 0.92
NewRedisConfigFunction · 0.85
CreateStoreMethod · 0.85
TestDefaultRedisConfigFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestDefaultRedisConfigFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…