Index: admin/monitor/src/main/java/org/glassfish/flashlight/datatree/impl/AbstractTreeNode.java =================================================================== --- admin/monitor/src/main/java/org/glassfish/flashlight/datatree/impl/AbstractTreeNode.java (revision 44454) +++ admin/monitor/src/main/java/org/glassfish/flashlight/datatree/impl/AbstractTreeNode.java (working copy) @@ -421,6 +421,6 @@ } private static String decodeName(String s) { - return s.replace(SLASH, "/").replace(MONDOT, "."); + return s.replace(SLASH, "/").replace(MONDOT, "\\."); } } Index: core/kernel/src/main/java/com/sun/enterprise/v3/admin/MonitoringReporter.java =================================================================== --- core/kernel/src/main/java/com/sun/enterprise/v3/admin/MonitoringReporter.java (revision 44454) +++ core/kernel/src/main/java/com/sun/enterprise/v3/admin/MonitoringReporter.java (working copy) @@ -42,7 +42,7 @@ import com.sun.enterprise.admin.util.ClusterOperationUtil; import com.sun.enterprise.config.serverbeans.*; import com.sun.enterprise.config.serverbeans.Domain; -import com.sun.enterprise.util.StringUtils; +import static com.sun.enterprise.util.StringUtils.ok; import com.sun.enterprise.v3.common.ActionReporter; import com.sun.enterprise.v3.common.PlainTextActionReporter; import com.sun.enterprise.v3.common.PropsFileActionReporter; @@ -364,7 +364,7 @@ // 2. * // 3. *. --> which is a weird input but let's accept it anyway! // 4 . --> very weird but we'll take it - if (!StringUtils.ok(userarg) + if (!ok(userarg) || userarg.equals("*") || userarg.equals(".") || userarg.equals("*.")) { @@ -486,18 +486,39 @@ // IT 8985 bnevins // Hack to get single stats. The code above above would take a lot of - // time to unwind. For development speed we just remove unwanted items + // time to unwind. For development speed we just remove unwanted items // after the fact... - if (exactMatch != null) { Object val = getIgnoreBackslash(map, exactMatch); map.clear(); - if (val != null) - map.put(exactMatch, val); + if (val != null) { + String fixedName = normalizeName(name, exactMatch); + map.put(fixedName, val); + } } } + private static String normalizeName(String actual, String userName) { + // normal case + // username = xxxxxx.foo-count + // actual name = xxxxxx.foo + + // fail fast for readability.. + + if(!ok(actual)) + return userName; + else if(!ok(userName)) + return actual; + + int lenA = actual.length(); + int lenU = userName.length(); + + if(lenU <= lenA) + return actual; // odd case, probably never happens + + return actual + userName.substring(lenA); + } /* * bnevins, 1-11-11 * Note that we can not GUESS where to put the backslash into 'pattern'.