code: static Connection connectWithURL(String username, String password, String jdbcURL, String driverName) throws ClassNotFoundException, SQLException {
          String driver = (Objects.isNull(driverName) || driverName.isEmpty()) ? "com.mysql.cj.jdbc.Driver" : driverName;
          return doConnect(driver, jdbcURL, username, password);
      }
docs: This is a utility function that allows connecting
  to a database instance identified by the provided jdbcURL
  The connector driver name can be empty
  @param username database username
  @param password database password
  @param jdbcURL the user supplied JDBC URL. It's used as is. So ensure you supply the right parameters
  @param driverName the user supplied mysql connector driver class name
  @return Connection
  @throws ClassNotFoundException exception
  @throws SQLException exception