remove locking from accounts service

add a cached named rwlock pkg
use sync.map in the cache pkg
use named rwlock in indexer pkg
use sync.map in indexer pkg
remove husky
This commit is contained in:
Florian Schade
2021-01-14 22:07:58 +01:00
parent f97f0d7342
commit a02fb890f7
11 changed files with 10554 additions and 131 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ type OIDCProvider interface {
// OIDCAuth provides a middleware to check access secured by a static token.
func OIDCAuth(optionSetters ...Option) func(next http.Handler) http.Handler {
options := newOptions(optionSetters...)
tokenCache := cache.NewCache(cache.Size(options.UserinfoCacheSize))
tokenCache := cache.NewCache(options.UserinfoCacheSize)
h := oidcAuth{
logger: options.Logger,