另客网go项目公用的代码库

session.go 336B

12345678910111213
  1. package auth
  2. type Session interface {
  3. // StoreJwtToken store jwt token is redis, make it expired for feature
  4. StoreJwtToken(token string, uid int64, timeout int64) error
  5. // IsExistsJwtToken judge whether token is invalid
  6. IsExistsJwtToken(token string) bool
  7. // DeleteJwtToken delete jwt token
  8. DeleteJwtToken(token string) bool
  9. }