class TracingJdbcEventListener extends SimpleJdbcEventListener {

  void parseServerIpAndPort(Connection connection, Span span) {
    try {
      String urlAsString = connection.getMetaData().getURL().substring(5); // strip "jdbc:"
      URI url =
        URI.create(urlAsString.replace(" ", "")); // Remove all white space according to RFC 2396
      String defaultRemoteServiceName = remoteServiceName;
      Matcher matcher = URL_SERVICE_NAME_FINDER.matcher(url.toString());
      if (matcher.find() && matcher.groupCount() == 1) {
        String parsedServiceName = matcher.group(1);
        if (parsedServiceName != null
          && !parsedServiceName.isEmpty()) { // Do not override global service name if parsed service name is invalid
          defaultRemoteServiceName = parsedServiceName;
        }
      }
      if (defaultRemoteServiceName == null || "".equals(defaultRemoteServiceName)) {
        String databaseName = connection.getCatalog();
        if (databaseName != null && !databaseName.isEmpty()) {
          span.remoteServiceName(databaseName);
        }
      } else {
        span.remoteServiceName(defaultRemoteServiceName);
      }
      span.remoteIpAndPort(url.getHost(), url.getPort());
    } catch (Exception e) {
      // remote address is optional
    }
  }

    TracingJdbcEventListener(@Nullable String remoteServiceName, boolean includeParameterValues,
    P6LogLoadableOptions logOptions);

}