Skip to content

Commit

Permalink
init the bumped dependency version for Java 11 and above
Browse files Browse the repository at this point in the history
  • Loading branch information
bowenliang123 committed Dec 2, 2023
1 parent 13af6ae commit 0bdb374
Show file tree
Hide file tree
Showing 10 changed files with 54 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@

package org.apache.kyuubi.jdbc;

/** @deprecated Use `KyuubiHiveDriver` instead. */
/**
* @deprecated Use `KyuubiHiveDriver` instead.
*/
@Deprecated
public class KyuubiDriver extends KyuubiHiveDriver {}
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,16 @@ public class JdbcUriParseException extends SQLException {

private static final long serialVersionUID = 0;

/** @param cause (original exception) */
/**
* @param cause (original exception)
*/
public JdbcUriParseException(Throwable cause) {
super(cause);
}

/** @param msg (exception message) */
/**
* @param msg (exception message)
*/
public JdbcUriParseException(String msg) {
super(msg);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -809,12 +809,16 @@ private void openSession() throws SQLException {
isClosed = false;
}

/** @return username from sessConfMap */
/**
* @return username from sessConfMap
*/
private String getUserName() {
return getSessionValue(AUTH_USER, ANONYMOUS_USER);
}

/** @return password from sessConfMap */
/**
* @return password from sessConfMap
*/
private String getPassword() {
return getSessionValue(AUTH_PASSWD, ANONYMOUS_PASSWD);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ public class KyuubiStatement implements SQLStatement, KyuubiLoggable {
private boolean isOperationComplete = false;

private Map<String, String> properties = new TreeMap<>(String.CASE_INSENSITIVE_ORDER);

/**
* We need to keep a reference to the result set to support the following: <code>
* statement.execute(String sql);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@

public class Utils {
static final Logger LOG = LoggerFactory.getLogger(Utils.class);

/** The required prefix list for the connection URL. */
public static final List<String> URL_PREFIX_LIST =
Arrays.asList("jdbc:hive2://", "jdbc:kyuubi://");

/** If host is provided, without a port. */
static final String DEFAULT_PORT = "10000";

// To parse the intermediate URI as a Java URI, we'll give a dummy authority(dummyhost:00000).
// Later, we'll substitute the dummy authority for a resolved authority.
static final String dummyAuthorityString = "dummyhost:00000";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,16 @@ public class ZooKeeperHiveClientException extends Exception {

private static final long serialVersionUID = 0;

/** @param cause (original exception) */
/**
* @param cause (original exception)
*/
public ZooKeeperHiveClientException(Throwable cause) {
super(cause);
}

/** @param msg (exception message) */
/**
* @param msg (exception message)
*/
public ZooKeeperHiveClientException(String msg) {
super(msg);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ public final class HttpAuthUtils {
public static final String AUTHORIZATION = "Authorization";
public static final String NEGOTIATE = "Negotiate";

/** @return Stringified Base64 encoded kerberosAuthHeader on success */
/**
* @return Stringified Base64 encoded kerberosAuthHeader on success
*/
public static String getKerberosServiceTicket(
String serverPrinciple, String host, Subject loggedInSubject) throws Exception {
String spn = KerberosUtils.canonicalPrincipal(serverPrinciple, host);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3132,7 +3132,9 @@ public static byte fastByteValueClip(
}
}

/** @return True when shortValue() will return a correct short. */
/**
* @return True when shortValue() will return a correct short.
*/

/**
* Is the decimal value a short? Range -32,768 to 32,767. Short.MIN_VALUE Short.MAX_VALUE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@ public long getTotalSeconds() {
return totalSeconds;
}

/** @return double representation of the interval day time, accurate to nanoseconds */
/**
* @return double representation of the interval day time, accurate to nanoseconds
*/
public double getDouble() {
return totalSeconds + nanos / 1000000000;
}
Expand Down
21 changes: 21 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2165,6 +2165,27 @@
</properties>
</profile>

<!-- For development only-->
<profile>
<id>libs-for-java11</id>
<activation>
<!-- Activated with Java 11 and above-->
<jdk>[11,18)</jdk>
</activation>
<properties>
<!--Maven Plugins-->
<maven.plugin.spotless.version>2.41.0</maven.plugin.spotless.version>
<spotless.java.googlejavaformat.version>1.18.1</spotless.java.googlejavaformat.version>

<!-- Runtime Dependencies-->
<derby.version>10.15.2.0</derby.version>
<hikaricp.version>4.0.3</hikaricp.version>
<jetty.version>11.0.18</jetty.version>

<!--Test Dependencies-->
</properties>
</profile>

<!-- For development only, not generally applicable for all modules -->
<profile>
<id>scala-2.13</id>
Expand Down

0 comments on commit 0bdb374

Please sign in to comment.