zhaomoran commented on code in PR #5642:
URL: https://github.com/apache/hbase/pull/5642#discussion_r1461290657
##########
hbase-common/src/main/java/org/apache/hadoop/hbase/ServerName.java:
##########
@@ -143,11 +143,10 @@ public static ServerName valueOf(final String hostname,
final int port, final lo
* instances, though we may return a shared immutable object as an internal
optimization.
*/
public static ServerName valueOf(final String serverName) {
- int firstSep = serverName.indexOf(SERVERNAME_SEPARATOR);
- int lastSep = serverName.lastIndexOf(SERVERNAME_SEPARATOR);
- String hostname = serverName.substring(0, firstSep);
- int port = Integer.parseInt(serverName.substring(firstSep + 1, lastSep));
- long startCode = Long.parseLong(serverName.substring(lastSep + 1));
+ String[] splits = serverName.split(",");
Review Comment:
The cause of the problem started from this issue
https://issues.apache.org/jira/browse/HBASE-24305,The ServerName function
previously supported filling in only the host name and port。Currently, it also
affects clear_ Compaction_ Queues.rb。Other RBs do not support the forms of host
name and port in promt。
--
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]