Will-Lo commented on code in PR #3516:
URL: https://github.com/apache/gobblin/pull/3516#discussion_r906920295


##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/orchestration/UserQuotaManager.java:
##########
@@ -103,8 +108,16 @@ public void checkQuota(Dag.DagNode<JobExecutionPlan> 
dagNode, boolean onInit) th
     boolean requesterCheck = true;
 
     if (serializedRequesters != null) {
-      List<String> uniqueRequesters = 
RequesterService.deserialize(serializedRequesters).stream()
-          
.map(ServiceRequester::getName).distinct().collect(Collectors.toList());
+      List<String> uniqueRequesters;
+      try {
+        uniqueRequesters = RequesterService.deserialize(serializedRequesters)
+            .stream()
+            .map(ServiceRequester::getName)
+            .distinct()
+            .collect(Collectors.toList());
+      } catch (IOException e) {
+        throw new RuntimeException("Could not process requesters due to ", e);
+      }

Review Comment:
   `return new ObjectMapper().readValue(jsonList, mapType);` throws an 
IOException as well, so we'd wrap that into a RuntimeException? I think that's 
appropriate given that it's not likely handleable outside of logging.



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