fix -- for echo framework

This commit is contained in:
swh 2016-02-18 17:08:51 +08:00
parent 36632d4916
commit 3d1b26f0c1
11 changed files with 22 additions and 22 deletions

View file

@ -1,22 +1,22 @@
# BoltStore - Session store using Bolt # BoltStore - Session store using Bolt
[![wercker status](https://app.wercker.com/status/752959ce0f923476671e49fb9b76ebe0/m "wercker status")](https://app.wercker.com/project/bykey/752959ce0f923476671e49fb9b76ebe0) [![wercker status](https://app.wercker.com/status/752959ce0f923476671e49fb9b76ebe0/m "wercker status")](https://app.wercker.com/project/bykey/752959ce0f923476671e49fb9b76ebe0)
[![Coverage Status](https://coveralls.io/repos/yosssi/boltstore/badge.png?branch=HEAD)](https://coveralls.io/r/yosssi/boltstore) [![Coverage Status](https://coveralls.io/repos/admpub/boltstore/badge.png?branch=HEAD)](https://coveralls.io/r/admpub/boltstore)
[![GoDoc](http://godoc.org/github.com/yosssi/boltstore?status.png)](http://godoc.org/github.com/yosssi/boltstore) [![GoDoc](http://godoc.org/github.com/admpub/boltstore?status.png)](http://godoc.org/github.com/admpub/boltstore)
## Overview ## Overview
BoltStore is a session store using [Bolt](https://github.com/boltdb/bolt) which is a pure Go key/value store. You can store session data in Bolt by using this store. This store implements the [gorilla/sessions](https://github.com/gorilla/sessions) package's [Store](http://godoc.org/github.com/gorilla/sessions#Store) interface. BoltStore's APIs and examples can be seen on its [GoDoc](http://godoc.org/github.com/yosssi/boltstore) page. BoltStore is a session store using [Bolt](https://github.com/boltdb/bolt) which is a pure Go key/value store. You can store session data in Bolt by using this store. This store implements the [gorilla/sessions](https://github.com/admpub/sessions) package's [Store](http://godoc.org/github.com/admpub/sessions#Store) interface. BoltStore's APIs and examples can be seen on its [GoDoc](http://godoc.org/github.com/admpub/boltstore) page.
## Installation ## Installation
```go ```go
go get github.com/yosssi/boltstore/... go get github.com/admpub/boltstore/...
``` ```
## Example ## Example
Here is a simple example using BoltStore. You can see other examples on the BoltStore's [GoDoc](http://godoc.org/github.com/yosssi/boltstore) page. Here is a simple example using BoltStore. You can see other examples on the BoltStore's [GoDoc](http://godoc.org/github.com/admpub/boltstore) page.
```go ```go
package main package main
@ -26,9 +26,9 @@ import (
"net/http" "net/http"
"github.com/boltdb/bolt" "github.com/boltdb/bolt"
"github.com/gorilla/sessions" "github.com/admpub/sessions"
"github.com/yosssi/boltstore/reaper" "github.com/admpub/boltstore/reaper"
"github.com/yosssi/boltstore/store" "github.com/admpub/boltstore/store"
) )
var db *bolt.DB var db *bolt.DB
@ -83,4 +83,4 @@ BenchmarkStore_Save_delete 5000 476563 ns/op 59576 B/op 76 allo
``` ```
## Documentation ## Documentation
* [GoDoc](http://godoc.org/github.com/yosssi/boltstore) * [GoDoc](http://godoc.org/github.com/admpub/boltstore)

View file

@ -3,7 +3,7 @@ package reaper
import ( import (
"time" "time"
"github.com/yosssi/boltstore/shared" "github.com/admpub/boltstore/shared"
) )
// Options represents options for the reaper. // Options represents options for the reaper.

View file

@ -3,7 +3,7 @@ package reaper
import ( import (
"testing" "testing"
"github.com/yosssi/boltstore/shared" "github.com/admpub/boltstore/shared"
) )
func TestOptions_setDefault(t *testing.T) { func TestOptions_setDefault(t *testing.T) {

View file

@ -4,8 +4,8 @@ import (
"log" "log"
"time" "time"
"github.com/admpub/boltstore/shared"
"github.com/boltdb/bolt" "github.com/boltdb/bolt"
"github.com/yosssi/boltstore/shared"
) )
//##############// //##############//

View file

@ -6,8 +6,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/admpub/boltstore/shared"
"github.com/boltdb/bolt" "github.com/boltdb/bolt"
"github.com/yosssi/boltstore/shared"
) )
func TestRun(t *testing.T) { func TestRun(t *testing.T) {

View file

@ -3,8 +3,8 @@ package shared
import ( import (
"time" "time"
"github.com/admpub/boltstore/shared/protobuf"
"github.com/gogo/protobuf/proto" "github.com/gogo/protobuf/proto"
"github.com/yosssi/boltstore/shared/protobuf"
) )
// Session converts the byte slice to the session struct value. // Session converts the byte slice to the session struct value.

View file

@ -1,7 +1,7 @@
package shared package shared
import ( import (
"github.com/yosssi/boltstore/shared/protobuf" "github.com/admpub/boltstore/shared/protobuf"
"testing" "testing"
"time" "time"

View file

@ -1,8 +1,8 @@
package store package store
import ( import (
"github.com/gorilla/sessions" "github.com/admpub/boltstore/shared"
"github.com/yosssi/boltstore/shared" "github.com/admpub/sessions"
) )
// Config represents a config for a session store. // Config represents a config for a session store.

View file

@ -3,7 +3,7 @@ package store
import ( import (
"testing" "testing"
"github.com/yosssi/boltstore/shared" "github.com/admpub/boltstore/shared"
) )
func TestConfig_setDefault(t *testing.T) { func TestConfig_setDefault(t *testing.T) {

View file

@ -8,10 +8,10 @@ import (
"net/http" "net/http"
"strings" "strings"
"github.com/admpub/boltstore/shared"
"github.com/admpub/sessions"
"github.com/boltdb/bolt" "github.com/boltdb/bolt"
"github.com/gorilla/securecookie" "github.com/gorilla/securecookie"
"github.com/gorilla/sessions"
"github.com/yosssi/boltstore/shared"
) )
// Store represents a session store. // Store represents a session store.

View file

@ -11,10 +11,10 @@ import (
"github.com/gogo/protobuf/proto" "github.com/gogo/protobuf/proto"
"github.com/admpub/boltstore/shared"
"github.com/admpub/sessions"
"github.com/boltdb/bolt" "github.com/boltdb/bolt"
"github.com/gorilla/securecookie" "github.com/gorilla/securecookie"
"github.com/gorilla/sessions"
"github.com/yosssi/boltstore/shared"
) )
var benchmarkDB = fmt.Sprintf("benchmark_store_%d.db", time.Now().Unix()) var benchmarkDB = fmt.Sprintf("benchmark_store_%d.db", time.Now().Unix())