ayushtkn commented on code in PR #6412:
URL: https://github.com/apache/hive/pull/6412#discussion_r3043764573


##########
jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java:
##########
@@ -163,6 +164,12 @@
  */
 public class HiveConnection implements java.sql.Connection {
   private static final Logger LOG = 
LoggerFactory.getLogger(HiveConnection.class);
+
+  /**
+   * Sentinel: no {@code SET hive.query.timeout.seconds} has been observed on 
this connection yet.
+   */
+  static final long SESSION_QUERY_TIMEOUT_NOT_TRACKED = -1L;
+  private final AtomicLong sessionQueryTimeoutSeconds = new 
AtomicLong(SESSION_QUERY_TIMEOUT_NOT_TRACKED);

Review Comment:
   a single JDBC Connection can be shared across multiple threads, and it is 
entirely possible to have multiple HiveStatement objects executing concurrently 
on the same connection (which maps to a single session on the HS2 side).
   
   via Beeline or so maybe not but In Hive Server 2 (HS2), a single JDBC 
Connection corresponds to a single HS2 Session. You can absolutely execute 
multiple queries concurrently within the same session by spawning multiple 
threads on the client side, each using a different HiveStatement created from 
that single HiveConnection.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to