ddanielr commented on code in PR #5729:
URL: https://github.com/apache/accumulo/pull/5729#discussion_r2199363064


##########
server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java:
##########
@@ -453,6 +454,13 @@ private GCStatus fetchGcStatus() {
   public void run() {
     ServerContext context = getContext();
     int[] ports = getConfiguration().getPort(Property.MONITOR_PORT);
+    String rootContext = getConfiguration().get(Property.MONITOR_ROOT_CONTEXT);
+    // Needs leading slash in order to property create rest endpoint requests
+    Preconditions.checkArgument(rootContext.startsWith("/"),
+        "Root context: \"%s\" does not have a leading '/'", rootContext);
+    // Needed to support the existing zk monitor address format
+    Preconditions.checkArgument(rootContext.endsWith("/"),
+        "Root context: \"%s\" does not have a trailing '/'", rootContext);

Review Comment:
   ok, I can easily change the code to add the ending slash for the user vs 
erroring out.



-- 
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: notifications-unsubscr...@accumulo.apache.org

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

Reply via email to