jerqi commented on code in PR #1710:
URL:
https://github.com/apache/incubator-uniffle/pull/1710#discussion_r1602521792
##########
common/src/main/java/org/apache/uniffle/common/util/RssUtils.java:
##########
@@ -274,6 +274,14 @@ public static String generatePartitionKey(String appId,
Integer shuffleId, Integ
Constants.KEY_SPLIT_CHAR, appId, String.valueOf(shuffleId),
String.valueOf(partition));
}
+ public static <T> T loadExtension(Class<T> extCls, String clsPackage, Object
obj) {
+ List<T> exts = loadExtensions(extCls, Arrays.asList(clsPackage), obj);
+ if (exts != null && exts.size() == 1) {
+ return exts.get(0);
+ }
+ return null;
Review Comment:
So maybe we should throw an IllegalException instead of returning null value.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]