You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2021/09/25 03:57:50 UTC

[GitHub] [skywalking-java] wuguanyu commented on a change in pull request #36: fix NumberFormat exception in MysqlURLParser

wuguanyu commented on a change in pull request #36:
URL: https://github.com/apache/skywalking-java/pull/36#discussion_r715985497



##########
File path: apm-sniffer/apm-sdk-plugin/jdbc-commons/src/main/java/org/apache/skywalking/apm/plugin/jdbc/connectionurl/parser/MysqlURLParser.java
##########
@@ -99,11 +110,13 @@ public ConnectionInfo parse() {
         } else {
             String[] hostAndPort = hostSegment[0].split(":");
             if (hostAndPort.length != 1) {
-                return new ConnectionInfo(component, dbType, hostAndPort[0], Integer.valueOf(hostAndPort[1]), fetchDatabaseNameFromURL(location
-                        .endIndex()));
+                return new ConnectionInfo(component, dbType, hostAndPort[0], Integer.valueOf(hostAndPort[1]),
+                                          fetchDatabaseNameFromURL(location
+                                                                           .endIndex()));
             } else {
-                return new ConnectionInfo(component, dbType, hostAndPort[0], DEFAULT_PORT, fetchDatabaseNameFromURL(location
-                        .endIndex()));
+                return new ConnectionInfo(component, dbType, hostAndPort[0], DEFAULT_PORT,
+                                          fetchDatabaseNameFromURL(location
+                                                                           .endIndex()));

Review comment:
       ok




-- 
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-unsubscribe@skywalking.apache.org

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