dimas-b commented on code in PR #4396:
URL: https://github.com/apache/polaris/pull/4396#discussion_r3230530761
##########
runtime/service/src/main/java/org/apache/polaris/service/admin/PolarisAdminService.java:
##########
@@ -1077,6 +1077,16 @@ public void deletePrincipal(String name) {
throw new ValidationException(
"Cannot reset credentials for a federated principal: %s",
principalName);
}
+ if (customClientId != null) {
+ PolarisPrincipalSecrets collidingSecrets =
+ metaStoreManager
+ .loadPrincipalSecrets(getCurrentPolarisContext(), customClientId)
+ .getPrincipalSecrets();
+ if (collidingSecrets != null
+ && collidingSecrets.getPrincipalId() !=
currentPrincipalEntity.getId()) {
Review Comment:
Ok, let's keep this check, but would it be possible to add dedicated tests
for NoSQL and JDBC Persistence to validate that backends also enforce client
IDs uniqueness?
--
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]