I'm using latest version 1.27.0 of jcasbin and postgres db, so adapter supports batchUpdate.
I was struggling with concurrent update of policies.
I've just realised that SyncedEnforcer has no representative version savePolicies and removePolicies methods, so ManagementEnforcer was used instead, and it is not thread safe.
Is there any reason of why SyncedEnforcer has no such methods? Should i manually iterate through the list and save my policies one by one instead?
Is it possible to add synchronised versions of those methods into SyncedEnforcer?
I'm using latest version
1.27.0
of jcasbin and postgres db, so adapter supports batchUpdate. I was struggling with concurrent update of policies.I've just realised that
SyncedEnforcer
has no representative versionsavePolicies
andremovePolicies
methods, soManagementEnforcer
was used instead, and it is not thread safe.Is there any reason of why
SyncedEnforcer
has no such methods? Should i manually iterate through the list and save my policies one by one instead?Is it possible to add synchronised versions of those methods into
SyncedEnforcer
?