<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Can I set a maximum query time with Hive JDBC? in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Can-I-set-a-maximum-query-time-with-Hive-JDBC/m-p/119918#M55255</link>
    <description>&lt;P&gt;I recently had a hive query (executed via a JDBC connection) hang for several hours due to a metastore issue.  Is there a way that I set a maximum query time with my JDBC connection?  This query should take just a few seconds, so I'd rather kill it after a few minutes than let it block for hours.&lt;/P&gt;&lt;P&gt;Some searching of the Hive JIRA suggests that this isn't possible, but asking here if anyone has advice.&lt;/P&gt;</description>
    <pubDate>Thu, 23 Feb 2017 01:07:50 GMT</pubDate>
    <dc:creator>Aaron_Dossett</dc:creator>
    <dc:date>2017-02-23T01:07:50Z</dc:date>
    <item>
      <title>Can I set a maximum query time with Hive JDBC?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Can-I-set-a-maximum-query-time-with-Hive-JDBC/m-p/119918#M55255</link>
      <description>&lt;P&gt;I recently had a hive query (executed via a JDBC connection) hang for several hours due to a metastore issue.  Is there a way that I set a maximum query time with my JDBC connection?  This query should take just a few seconds, so I'd rather kill it after a few minutes than let it block for hours.&lt;/P&gt;&lt;P&gt;Some searching of the Hive JIRA suggests that this isn't possible, but asking here if anyone has advice.&lt;/P&gt;</description>
      <pubDate>Thu, 23 Feb 2017 01:07:50 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Can-I-set-a-maximum-query-time-with-Hive-JDBC/m-p/119918#M55255</guid>
      <dc:creator>Aaron_Dossett</dc:creator>
      <dc:date>2017-02-23T01:07:50Z</dc:date>
    </item>
    <item>
      <title>Re: Can I set a maximum query time with Hive JDBC?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Can-I-set-a-maximum-query-time-with-Hive-JDBC/m-p/119919#M55256</link>
      <description>&lt;P&gt;I have not tried this&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;hive.server2.idle.operation.timeoutWith &lt;A href="https://cwiki.apache.org/confluence/display/Hive/Configuration+Properties#ConfigurationProperties-hive.server2.session.check.interval"&gt;&lt;STRONG&gt;hive.server2.session.check.interval&lt;/STRONG&gt;&lt;/A&gt; set to a positive time value, operation will be closed when it's not accessed for this duration of time, which can be disabled by setting to zero value.
With positive value, it's checked for operations in terminal state only (FINISHED, CANCELED, CLOSED, ERROR).
With negative value, it's checked for all of the operations regardless of state.&lt;/LI&gt;&lt;LI&gt;hive.server2.idle.session.timeoutWith &lt;A href="https://cwiki.apache.org/confluence/display/Hive/Configuration+Properties#ConfigurationProperties-hive.server2.session.check.interval"&gt;&lt;STRONG&gt;hive.server2.session.check.interval&lt;/STRONG&gt;&lt;/A&gt; set to a positive time value, session will be closed when it's not accessed for this duration of time, which can be disabled by setting to zero or negative value.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;and if it was metastore issue, did you try:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;hive.metastore.client.socket.timeoutMetaStore Client socket timeout in seconds.&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Sat, 25 Feb 2017 12:17:13 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Can-I-set-a-maximum-query-time-with-Hive-JDBC/m-p/119919#M55256</guid>
      <dc:creator>sunile_manjee</dc:creator>
      <dc:date>2017-02-25T12:17:13Z</dc:date>
    </item>
  </channel>
</rss>

