Documentation ¶
Overview ¶
Gorilla Sessions backend for ClusterSQL.
Copyright (c) 2016 Contributors. See the list of contributors in the CONTRIBUTORS file for details.
This software is licensed under a MIT style license available in the LICENSE file.
Index ¶
- type ClusterSQLStore
- func (m *ClusterSQLStore) Close()
- func (m *ClusterSQLStore) Delete(r *http.Request, w http.ResponseWriter, session *sessions.Session) error
- func (m *ClusterSQLStore) Get(r *http.Request, name string) (*sessions.Session, error)
- func (m *ClusterSQLStore) New(r *http.Request, name string) (*sessions.Session, error)
- func (m *ClusterSQLStore) Save(r *http.Request, w http.ResponseWriter, session *sessions.Session) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClusterSQLStore ¶
type ClusterSQLStore struct { Codecs []securecookie.Codec Options *sessions.Options // contains filtered or unexported fields }
func NewClusterSQLStore ¶
func NewClusterSQLStore(driverName, path string, maxAge int, keyPairs ...[]byte) (*ClusterSQLStore, error)
NewClusterSQLStore return a ClusterSQLStore, driverName is the name of preregistered cluster drvier
func NewClusterSQLStoreConnection ¶
func NewClusterSQLStoreConnection(db *sql.DB, path string, maxAge int, keyPairs ...[]byte) (*ClusterSQLStore, error)
NewClusterSQLStore return a ClusterSQLStore, db is an existing db connection
func (*ClusterSQLStore) Close ¶
func (m *ClusterSQLStore) Close()
Close implement the Close method of session store
func (*ClusterSQLStore) Delete ¶
func (m *ClusterSQLStore) Delete(r *http.Request, w http.ResponseWriter, session *sessions.Session) error
Delete allow delete of mysql session (not exposed by gorilla sessions interface).
func (*ClusterSQLStore) Save ¶
func (m *ClusterSQLStore) Save(r *http.Request, w http.ResponseWriter, session *sessions.Session) error
Save implement the Save method of session store
Click to show internal directories.
Click to hide internal directories.