[ 
https://issues.apache.org/jira/browse/MAPREDUCE-7299?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

leafeonia updated MAPREDUCE-7299:
---------------------------------
    Attachment:     (was: MAPREDUCE-7299-001.patch)

> data type of parameter 'mapreduce.task.exit.timeout' is inconsistent
> --------------------------------------------------------------------
>
>                 Key: MAPREDUCE-7299
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-7299
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>            Reporter: leafeonia
>            Priority: Minor
>         Attachments: MAPREDUCE-7299-001.patch
>
>
> *Problem:*
> The data type of parameter `mapreduce.task.exit.timeout` is inconsistent in 
> the code relevant to the parameter.
> In `TaskAttemptFinishingMonitor.java`, getInt() is used to load the parameter 
> value:
> {code:java}
> int expireIntvl = conf.getInt(MRJobConfig.TASK_EXIT_TIMEOUT,
>   MRJobConfig.TASK_EXIT_TIMEOUT_DEFAULT);{code}
> However, in `TaskHeartbeatHandler.java`, the code uses getLong() instead and 
> stores the value in a long-type variable.
> {code:java}
> private long unregisterTimeOut;
> ...
> unregisterTimeOut = conf.getLong(MRJobConfig.TASK_EXIT_TIMEOUT,
>   MRJobConfig.TASK_EXIT_TIMEOUT_DEFAULT);{code}
>  
> *Solution:*
> Convert the type explicitly to avoid inconsistency and potential problems:
> {code:java}
> unregisterTimeOut = (long)conf.getInt(MRJobConfig.TASK_EXIT_TIMEOUT, 
>   MRJobConfig.TASK_EXIT_TIMEOUT_DEFAULT);{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: mapreduce-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: mapreduce-issues-h...@hadoop.apache.org

Reply via email to