hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chaoyu Tang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-15139) HoS local mode fails with NumberFormatException
Date Mon, 07 Nov 2016 15:18:59 GMT

    [ https://issues.apache.org/jira/browse/HIVE-15139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15644452#comment-15644452
] 

Chaoyu Tang commented on HIVE-15139:
------------------------------------

Thanks [~lirui] for the patch, it looks good to me. I ran into the exactly same issue when
playing with the HoS statistics, and worked it around by passing 0 instead of Integer.parseInt(stageId)
to metricsCollection.addMetrics just like the taskId. I thought stageId would not be used
anyway when we get all metrics from metricsCollection (metricsCollection.getAllMetrics())
in getSparkStatistics. My change is like following:
{code}
@@ -143,7 +143,7 @@ public SparkStatistics getSparkStatistics() {
       List<TaskMetrics> taskMetrics = jobMetric.get(stageId);
       for (TaskMetrics taskMetric : taskMetrics) {
         Metrics metrics = new Metrics(taskMetric);
-        metricsCollection.addMetrics(jobId, Integer.parseInt(stageId), 0, metrics);
+        metricsCollection.addMetrics(jobId, 0, 0, metrics);
       }
     }
     SparkJobUtils sparkJobUtils = new SparkJobUtils();
{code}
Your patch removes the stageAttemptId from jobMetrics, I wonder if it might still be useful
for some other metrics (e.g. average times a stage attempted)? It is my first time to look
into HoS, I wonder if my question makes sense. Thanks.

> HoS local mode fails with NumberFormatException
> -----------------------------------------------
>
>                 Key: HIVE-15139
>                 URL: https://issues.apache.org/jira/browse/HIVE-15139
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Rui Li
>            Assignee: Rui Li
>         Attachments: HIVE-15139.1.patch
>
>
> It's because we store {{stageId_attemptNum}} in JobMetricsListener but expect only {{stageId}}
in LocalSparkJobStatus.
> {noformat}
> java.lang.NumberFormatException: For input string: "0_0"
> 	at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
> 	at java.lang.Integer.parseInt(Integer.java:580)
> 	at java.lang.Integer.parseInt(Integer.java:615)
> 	at org.apache.hadoop.hive.ql.exec.spark.status.impl.LocalSparkJobStatus.getSparkStatistics(LocalSparkJobStatus.java:146)
> 	at org.apache.hadoop.hive.ql.exec.spark.SparkTask.execute(SparkTask.java:104)
> 	at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:199)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message