session

package
v0.0.0-...-5e0f84c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2018 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrResponseNil = errors.New("Can not Set session, resp is nil")

ErrResponseNil used for to represent the error response, when it is nil

View Source
var SessionCache *cache.Cache

SessionCache session cache variable

Functions

func CheckForSessionID

func CheckForSessionID(inv *invocation.Invocation, autoTimeout int, resp *fasthttp.Response, req *fasthttp.Request)

CheckForSessionID check session id

func ClearExpired

func ClearExpired()

ClearExpired delete all expired session

func Delete

func Delete(key string)

Delete for deleting the sid

func DeletingKeySuccessiveFailure

func DeletingKeySuccessiveFailure(resp *fasthttp.Response)

DeletingKeySuccessiveFailure deleting key successes and failures

func Get

func Get(k string) (sid interface{}, ok bool)

Get return session id based on session key

func GetSessionFromResp

func GetSessionFromResp(key string, resp *fasthttp.Response) string

GetSessionFromResp return session id in resp if there is

func Save

func Save(sid string, addr string, timeOut time.Duration)

Save for setting the service id, address, timeout

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL