Closed tyjyhapple closed 3 years ago
@GopherJ @xcaptain @hackerchai
@tyjyhapple Sorry for the late reply, I believe we can remove the lock only if we can ensure there is no modification on policies.
In this case we can use only Arc
.
Also we are using CachedEnforcer
so it needs &mut
to be able to modify internal cache.
If you have better ideas don't hesitate
Closed as stale.
enforcer: Arc<RwLock> why use lock,When I test the performance, the performance drops dramatically under using Rwlock