1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-04 09:40:19 +00:00

#254 add SessionHashFunc SessionHashKey SessionCookieLifeTime

This commit is contained in:
astaxie
2013-11-03 21:41:07 +08:00
parent 9ccdb31003
commit 23d79b8b05
2 changed files with 52 additions and 21 deletions

View File

@ -71,7 +71,14 @@ func Run() {
}
if SessionOn {
GlobalSessions, _ = session.NewManager(SessionProvider, SessionName, SessionGCMaxLifetime, SessionSavePath, HttpTLS)
GlobalSessions, _ = session.NewManager(SessionProvider,
SessionName,
SessionGCMaxLifetime,
SessionSavePath,
HttpTLS,
SessionHashFunc,
SessionHashKey,
SessionCookieLifeTime)
go GlobalSessions.GC()
}