github.com/teng231/glock@v1.1.11/const.go (about) 1 package glock 2 3 import "time" 4 5 const ( 6 StatusLocked = "locked" 7 StatusNotPersist = "error_persist" 8 StatusInvalidCounter = "invalid_counter" 9 StatusCountdownDone = "countdown_done" 10 Empty = "empty" 11 CantParse = "can't parse" 12 ) 13 14 type ConnectConfig struct { 15 RedisAddr string 16 RedisPw string 17 RedisUsername string 18 Prefix string 19 Timelock time.Duration 20 RedisDb int 21 // for distributed lock 22 MaxRetries int 23 MinRetryBackoff time.Duration 24 MaxRetryBackoff time.Duration 25 PoolSize int 26 // add timezone 27 Timezone string 28 }