adutra commented on code in PR #1397:
URL: https://github.com/apache/polaris/pull/1397#discussion_r2051770521


##########
polaris-core/src/main/java/org/apache/polaris/core/auth/AuthenticatedPolarisPrincipal.java:
##########
@@ -56,10 +72,20 @@ public List<PrincipalRoleEntity> 
getActivatedPrincipalRoles() {
     return activatedPrincipalRoles;
   }
 
+  /** FIXME this method makes this class mutable, which seems risky */
   public void setActivatedPrincipalRoles(List<PrincipalRoleEntity> 
activatedPrincipalRoles) {
     this.activatedPrincipalRoles = activatedPrincipalRoles;
   }
 
+  /**
+   * Whether all roles should be activated. This is true when the principal is 
requesting all
+   * available principal roles. When this is true, {@link 
#getActivatedPrincipalRoleNames()} returns
+   * an empty set.
+   */
+  public boolean allRoles() {

Review Comment:
   I removed the method because it doesn't work well with the `Resolver`. TLDR 
we can't distinguish "no roles" from "all roles" for now.



-- 
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