You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "mbalassi (via GitHub)" <gi...@apache.org> on 2023/04/19 06:29:33 UTC

[GitHub] [flink] mbalassi commented on a diff in pull request #22420: [FLINK-31839][filesystems] Fix flink-s3-fs-hadoop and flink-s3-fs-presto plugin collision

mbalassi commented on code in PR #22420:
URL: https://github.com/apache/flink/pull/22420#discussion_r1170863184


##########
flink-runtime/src/main/java/org/apache/flink/runtime/security/token/DefaultDelegationTokenManager.java:
##########
@@ -203,6 +211,21 @@ static void checkProviderAndReceiverConsistency(
         LOG.info("Provider and receiver instances are consistent");
     }
 
+    @VisibleForTesting
+    static void checkSamePrefixedProviders(
+            Map<String, DelegationTokenProvider> providers, List<String> warnings) {
+        Set<String> providerPrefixes = new HashSet<>();
+        for (String name : providers.keySet()) {
+            String[] split = name.split("-");
+            if (!providerPrefixes.add(split[0])) {
+                String msg =
+                        String.format(
+                                "Multiple providers loaded with the same prefix: %s", split[0]);

Review Comment:
   Let us add a bit more context to this, I like this message as the beginning but let us also add:
   `Please consider using only one of the following providers: <list of clashing providerNames>, the current configuration might lead to unintended consequences.`
   
   We should also add some content to the flink docs about these unintended consequences. :)



-- 
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: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org