authorizer/server/memorystore/providers/inmemory/provider.go
2022-05-27 23:20:38 +05:30

19 lines
402 B
Go

package inmemory
import "sync"
type provider struct {
mutex sync.Mutex
sessionStore map[string]map[string]string
stateStore map[string]string
}
// NewInMemoryStore returns a new in-memory store.
func NewInMemoryProvider() (*provider, error) {
return &provider{
mutex: sync.Mutex{},
sessionStore: map[string]map[string]string{},
stateStore: map[string]string{},
}, nil
}