1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-18 02:17:05 +00:00

redis sessiondb: support more than one driver - builtin redigo(default) and radix - rel to: #1328

Former-commit-id: 1eee58f2c49f64899fffc3ad61bcf074f8949cc1
This commit is contained in:
Gerasimos (Makis) Maropoulos
2019-08-06 18:40:13 +03:00
parent 8ac32ed27c
commit eb29a80753
7 changed files with 498 additions and 135 deletions

View File

@@ -22,7 +22,15 @@ func main() {
Database: "",
Prefix: "",
Delim: "-",
}) // optionally configure the bridge between your redis server.
Driver: redis.Redigo(), // redis.Radix() can be used instead.
})
// optionally configure the underline driver:
// driver := redis.Redigo()
// driver.MaxIdle = ...
// driver.IdleTimeout = ...
// driver.Wait = ...
// redis.Config {Driver: driver}
// close connection when control+C/cmd+C
iris.RegisterOnInterrupt(func() {