Cache Rules

This commit is contained in:
Ben Toogood 2020-05-26 15:53:28 +01:00
parent 5712cc9c62
commit cd283654eb

View File

@ -112,7 +112,7 @@ func (s *svc) Rules(opts ...auth.RulesOption) ([]*auth.Rule, error) {
options.Context = context.TODO()
}
rsp, err := s.rules.List(options.Context, &pb.ListRequest{})
rsp, err := s.rules.List(options.Context, &pb.ListRequest{}, client.WithCache(time.Second*30))
if err != nil {
return nil, err
}