hadoop - ClassCastException while using ORC file format with Hive when vectorized.execution.enabled -


i have hive table following properties -

  • orc storage format
  • transactional = true
  • partitioned on 4 keys - year, month, day, hour
  • bucketed groupingkey

i using hive streaming populating data directly table.

now problem - trying run following query

select count(*) table_name; 

i getting following exception

caused by: java.lang.classcastexception:    org.apache.hadoop.hive.ql.io.orc.orcstruct$orcstructinspector cannot cast org.apache.hadoop.hive.serde2.objectinspector.primitiveobjectinspector @ org.apache.hadoop.hive.ql.exec.vector.vectorizedbatchutil.setvector(vectorizedbatchutil.java:295) @ org.apache.hadoop.hive.ql.exec.vector.vectorizedbatchutil.acidaddrowtobatch(vectorizedbatchutil.java:275) @ org.apache.hadoop.hive.ql.io.orc.vectorizedorcacidrowreader.next(vectorizedorcacidrowreader.java:82) 

however if turn off vectorized execution setting following property

set hive.vectorized.execution.enabled = false; 

everything works fine (although takes ages complete).

why happening ? understand, orc format, vectorized execution should work.

hadoop version - 2.7.1

hive version - 1.2.1

seems hive issue has been closed/fixed. please recheck version of hive used.

please check vectorized execution causes classcastexception

enter image description here


Comments