klsince commented on code in PR #13706:
URL: https://github.com/apache/pinot/pull/13706#discussion_r1710316668


##########
pinot-broker/src/main/java/org/apache/pinot/broker/requesthandler/BaseSingleStageBrokerRequestHandler.java:
##########
@@ -836,6 +840,31 @@ protected BrokerResponse handleRequest(long requestId, 
String query, @Nullable S
     }
   }
 
+  @VisibleForTesting
+  static String addRoutingPolicyInErrMsg(String errorMessage, String 
realtimeRoutingPolicy,
+      String offlineRoutingPolicy) {
+    if (realtimeRoutingPolicy != null && offlineRoutingPolicy != null) {
+      return String.format("%s, with routing policy: %s [realtime], %s 
[offline]", errorMessage, realtimeRoutingPolicy,
+          offlineRoutingPolicy);
+    }
+    if (realtimeRoutingPolicy != null) {
+      return String.format("%s, with routing policy: %s [realtime]", 
errorMessage, realtimeRoutingPolicy);
+    }
+    if (offlineRoutingPolicy != null) {
+      return String.format("%s, with routing policy: %s [offline]", 
errorMessage, offlineRoutingPolicy);
+    }

Review Comment:
   got it. it's error handling path, but anyway, lemme update to use +



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

Reply via email to