yuqi1129 commented on code in PR #10908:
URL: https://github.com/apache/gravitino/pull/10908#discussion_r3165955671


##########
server-common/src/main/java/org/apache/gravitino/server/authorization/jcasbin/JcasbinAuthorizer.java:
##########
@@ -407,10 +423,12 @@ public void close() throws IOException {
 
   private class InternalAuthorizer {
 
-    Enforcer enforcer;
+    private final Enforcer enforcer;
+    private final boolean denyMode;
 
-    public InternalAuthorizer(Enforcer enforcer) {
+    InternalAuthorizer(Enforcer enforcer, boolean denyMode) {

Review Comment:
   Updated. I replaced the boolean constructor flag with an explicit 
AuthorizationMode enum, so the call sites are now:
   
   - new InternalAuthorizer(allowEnforcer, AuthorizationMode.ALLOW)
   - new InternalAuthorizer(denyEnforcer, AuthorizationMode.DENY)
   
   This should make the intent clear without requiring reviewers to remember 
what true/false means.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to