maobaolong commented on code in PR #1852:
URL:
https://github.com/apache/incubator-uniffle/pull/1852#discussion_r1663436343
##########
dashboard/src/main/java/org/apache/uniffle/dashboard/web/proxy/WebProxyServlet.java:
##########
@@ -45,7 +45,8 @@ protected String rewriteTarget(HttpServletRequest
clientRequest) {
String targetAddress =
coordinatorServerAddressesMap.get(clientRequest.getHeader("targetAddress"));
if (targetAddress == null) {
- return null;
+ // Get random one from coordinatorServerAddressesMap
+ targetAddress = coordinatorServerAddressesMap.values().iterator().next();
Review Comment:
yes, it will throw another NPE....
```Console
[2024-07-03 11:35:34.514] [main] [INFO] JettyServerFront.main - Start to
init dashboard http server using config
/Users/mbl/projects/tencent/incubator-uniffle/conf/dashboard.conf
[2024-07-03 11:35:34.562] [main] [INFO] RssUtils.getPropertiesFromFile -
Load config from
/Users/mbl/projects/tencent/incubator-uniffle/conf/dashboard.conf
[2024-07-03 11:35:34.587] [main] [INFO] log.initialized - Logging
initialized @1726ms
Exception in thread "main" java.lang.NullPointerException
at
org.apache.uniffle.dashboard.web.utils.DashboardUtils.convertAddressesStrToMap(DashboardUtils.java:34)
at
org.apache.uniffle.dashboard.web.JettyServerFront.setRootServletHandler(JettyServerFront.java:96)
at
org.apache.uniffle.dashboard.web.JettyServerFront.initialization(JettyServerFront.java:86)
at
org.apache.uniffle.dashboard.web.JettyServerFront.<init>(JettyServerFront.java:63)
at
org.apache.uniffle.dashboard.web.JettyServerFront.main(JettyServerFront.java:75)
```
--
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]