Kenneth Jørgensen created HIVE-16650: ----------------------------------------
Summary: NumberFormatException in AcidUtils.parseBaseBucketFilename Key: HIVE-16650 URL: https://issues.apache.org/jira/browse/HIVE-16650 Project: Hive Issue Type: Bug Components: ORC Affects Versions: 1.2.0 Reporter: Kenneth Jørgensen While running a pig query we ran into the following error: ``` job_1494464639124_0002 clickIps,clickIpsGrouped,clicks GROUP_BY Message: org.apache.pig.backend.executionengine.ExecException: ERROR 2118: serious problem at org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigInputFormat.getSplits(PigInputFormat.java:288) at org.apache.hadoop.mapreduce.JobSubmitter.writeNewSplits(JobSubmitter.java:667) at org.apache.hadoop.mapreduce.JobSubmitter.writeSplits(JobSubmitter.java:691) at org.apache.hadoop.mapreduce.JobSubmitter.submitJobInternal(JobSubmitter.java:526) at org.apache.hadoop.mapreduce.Job$11.run(Job.java:1385) at org.apache.hadoop.mapreduce.Job$11.run(Job.java:1382) 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:1635) at org.apache.hadoop.mapreduce.Job.submit(Job.java:1382) at org.apache.hadoop.mapreduce.lib.jobcontrol.ControlledJob.submit(ControlledJob.java:335) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.pig.backend.hadoop23.PigJobControl.submit(PigJobControl.java:128) at org.apache.pig.backend.hadoop23.PigJobControl.run(PigJobControl.java:191) at java.lang.Thread.run(Thread.java:745) at org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.MapReduceLauncher$1.run(MapReduceLauncher.java:257) Caused by: java.lang.RuntimeException: serious problem at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat$Context.waitForTasks(OrcInputFormat.java:466) at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat.generateSplitsInfo(OrcInputFormat.java:922) at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat.getSplits(OrcInputFormat.java:947) at org.apache.hive.hcatalog.mapreduce.HCatBaseInputFormat.getSplits(HCatBaseInputFormat.java:157) at org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.PigInputFormat.getSplits(PigInputFormat.java:274) ... 18 more Caused by: java.lang.NumberFormatException: For input string: "59027730032546908947033857045786" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:495) at java.lang.Integer.parseInt(Integer.java:527) at org.apache.hadoop.hive.ql.io.AcidUtils.parseBaseBucketFilename(AcidUtils.java:145) at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat$FileGenerator.run(OrcInputFormat.java:534) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) ``` After some investigation we found this file in our S3 directory: `59027730032546908947033857045786_000000`. Slightly different version, but the error occurs here: https://github.com/apache/hive/blob/release-1.2.0/ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java#L162 It would appear the regex `[0-9]+_[0-9]+` i detecting the first hash part of the filenames as all numbers and makes some assumption about it, causing the whole thing to error out with a NumberFormatException. -- This message was sent by Atlassian JIRA (v6.3.15#6346)