mchades commented on code in PR #7796:
URL: https://github.com/apache/gravitino/pull/7796#discussion_r2251653191
##########
core/src/main/java/org/apache/gravitino/storage/relational/service/PolicyMetaService.java:
##########
@@ -327,6 +302,19 @@ public List<PolicyEntity>
associatePoliciesWithMetadataObject(
? Collections.emptyList()
: getPolicyPOsByMetalakeAndNames(metalake, policyNamesToAdd);
+ // Check if the policies to add all support the metadata object type.
+ policyPOsToAdd.forEach(
Review Comment:
I prefer to keep the current code, because the current code can use
short-circuit logic and throw exceptions with accurate information.
--
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]