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

IndexOutOfBoundsException with add a new jar to HIVE_AUX_JARS_PATH

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 3.1.0
    • None
    • Tez
    • None
    • HDP-3.0.0

    Description

      The steps to reproduce are as follows:

      1. Add phoenix-5.0.0-hive.jar to HIVE_AUX_JARS_PATH  in hive-env and restart hive server

      export HIVE_AUX_JARS_PATH=/usr/local/phoenix/phoenix-5.0.0-hive.jar 

      2. Create a table in Phoenix:

      CREATE TABLE TEST (ID VARCHAR PRIMARY KEY, COL VARCHAR);

      3. Create a table in Hive that's based on the table in Phoenix created in the step 2:

      CREATE EXTERNAL TABLE test (id STRING, col STRING)
      STORED BY 'org.apache.phoenix.hive.PhoenixStorageHandler'
      TBLPROPERTIES (
        "phoenix.table.name" = "TEST",
        "phoenix.zookeeper.quorum" = "<quorum string>",
        "phoenix.zookeeper.znode.parent" = "/hbase-unsecure",
        "phoenix.zookeeper.client.port" = "2181",
        "phoenix.rowkeys" = "ID",
        "phoenix.column.mapping" = "id:ID, col:COL"
      );

      4. Intert data to the Phoenix table :

      UPSERT INTO TEST VALUES('id', 'col');

      5. Run CREATE TABLE AS SELECT in Hive

      CREATE TABLE TEST1 
      AS 
      SELECT * FROM TEST;

      After the step 5, I face the following error:

      2021-12-24 13:55:13,100 INFO  [HiveServer2-Background-Pool: Thread-19227] tez.DagUtils: Skipping vertex resource file:/usr/local/phoenix/phoenix-5.0.0-hive.jar that already exists in the session
      2021-12-23 11:55:23,323 ERROR [HiveServer2-Background-Pool: Thread-274] exec.Task: Failed to execute tez graph.
      java.lang.IndexOutOfBoundsException: Index: 23, Size: 23
              at java.util.ArrayList.rangeCheck(ArrayList.java:653)
              at java.util.ArrayList.get(ArrayList.java:429)
              at org.apache.hadoop.hive.ql.exec.tez.TezSessionState.ensureLocalResources(TezSessionState.java:717)
              at org.apache.hadoop.hive.ql.exec.tez.TezSessionState.openInternal(TezSessionState.java:414)
              at org.apache.hadoop.hive.ql.exec.tez.TezSessionPoolSession.openInternal(TezSessionPoolSession.java:124)
              at org.apache.hadoop.hive.ql.exec.tez.TezSessionState.open(TezSessionState.java:373)
              at org.apache.hadoop.hive.ql.exec.tez.TezTask.ensureSessionHasResources(TezTask.java:368)
              at org.apache.hadoop.hive.ql.exec.tez.TezTask.execute(TezTask.java:195)
              at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:205)
              at org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:97)
              at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:2668)
              at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:2339)
              at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:2015)
              at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1713)
              at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1707)
              at org.apache.hadoop.hive.ql.reexec.ReExecDriver.run(ReExecDriver.java:157)
              at org.apache.hive.service.cli.operation.SQLOperation.runQuery(SQLOperation.java:224)
              at org.apache.hive.service.cli.operation.SQLOperation.access$700(SQLOperation.java:87)
              at org.apache.hive.service.cli.operation.SQLOperation$BackgroundWork$1.run(SQLOperation.java:316)
              at java.security.AccessController.doPrivileged(Native Method)
              at javax.security.auth.Subject.doAs(Subject.java:422)
              at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1688)
              at org.apache.hive.service.cli.operation.SQLOperation$BackgroundWork.run(SQLOperation.java:329)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
              at java.util.concurrent.FutureTask.run(FutureTask.java:266)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
              at java.util.concurrent.FutureTask.run(FutureTask.java:266)
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
              at java.lang.Thread.run(Thread.java:748)
      2021-12-23 11:55:23,324 INFO  [HiveServer2-Background-Pool: Thread-274] reexec.ReOptimizePlugin: ReOptimization: retryPossible: false
      FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.tez.TezTask2021-12-23 11:55:23,324 INFO  [Hive Hook Proto Event Handler 0] hooks.HiveProtoLoggingHook: Received post-hook notification for: hive_20211223115520_d1242fe1-9b25-4b10-b935-135d437a5d14

      Attachments

        Activity

          People

            Unassigned Unassigned
            axexie Axe Xie
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: