mirror of
https://github.com/pomerium/pomerium.git
synced 2025-07-23 19:49:13 +02:00
core/authorize: cache prepared query building
This commit is contained in:
parent
0b79a28328
commit
42233223cb
11 changed files with 143 additions and 67 deletions
|
@ -130,8 +130,8 @@ func TestAuthorize_okResponse(t *testing.T) {
|
|||
}
|
||||
a := &Authorize{currentOptions: config.NewAtomicOptions(), state: atomicutil.NewValue(new(authorizeState))}
|
||||
a.currentOptions.Store(opt)
|
||||
a.store = store.New()
|
||||
pe, err := newPolicyEvaluator(opt, a.store)
|
||||
a.compiler = evaluator.NewRegoCompiler(store.New())
|
||||
pe, err := newPolicyEvaluator(opt, a.compiler)
|
||||
require.NoError(t, err)
|
||||
a.state.Load().evaluator = pe
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue