Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-7351

ANALYZE TABLE statement fails on postgres metastore

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 0.13.0, 0.13.1
    • 1.2.0
    • Metastore
    • postgresSQL

    • Users who use Postgres as the RDBMS for their metastore and who wish to collect stats must set hive.stats.jdbc.timeout -1.

    Description

      Metastore code use method PreparedStatement.setQueryTimeout(int) of JDBC Driver :

      Current JDBC driver doesn't implements this method.

      2014-07-07 17:52:38,239 ERROR org.apache.hadoop.hive.ql.stats.jdbc.JDBCStatsPublisher: Error during JDBC connection to jdbc:postgresql://nc-h04:5432/metastore?user=hiveuser&password=mvsmt4521. 
      org.postgresql.util.PSQLException: Method org.postgresql.jdbc4.Jdbc4PreparedStatement.setQueryTimeout(int) is not yet implemented.
      	at org.postgresql.Driver.notImplemented(Driver.java:753)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.setQueryTimeout(AbstractJdbc2Statement.java:666)
      	at org.apache.hadoop.hive.ql.stats.jdbc.JDBCStatsPublisher$1.run(JDBCStatsPublisher.java:80)
      	at org.apache.hadoop.hive.ql.stats.jdbc.JDBCStatsPublisher$1.run(JDBCStatsPublisher.java:77)
      	at org.apache.hadoop.hive.ql.exec.Utilities.executeWithRetry(Utilities.java:2637)
      	at org.apache.hadoop.hive.ql.stats.jdbc.JDBCStatsPublisher.connect(JDBCStatsPublisher.java:96)
      	at org.apache.hadoop.hive.ql.exec.TableScanOperator.publishStats(TableScanOperator.java:280)
      	at org.apache.hadoop.hive.ql.exec.TableScanOperator.closeOp(TableScanOperator.java:226)
      	at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:583)
      	at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:595)
      	at org.apache.hadoop.hive.ql.exec.mr.ExecMapper.close(ExecMapper.java:227)
      	at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:57)
      	at org.apache.hadoop.mapred.MapTask.runOldMapper(MapTask.java:430)
      	at org.apache.hadoop.mapred.MapTask.run(MapTask.java:366)
      	at org.apache.hadoop.mapred.Child$4.run(Child.java:255)
      	at java.security.AccessController.doPrivileged(Native Method)
      	at javax.security.auth.Subject.doAs(Subject.java:415)
      	at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1190)
      	at org.apache.hadoop.mapred.Child.main(Child.java:249)
      

      Attachments

        1. HIVE-7351.1.patch.txt
          3 kB
          Navis Ryu
        2. HIVE-7351.2.patch.txt
          3 kB
          Navis Ryu

        Issue Links

          Activity

            People

              navis Navis Ryu
              damien.carol Damien Carol
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: