Zhijie Shen commented on YARN-2209:

[~djp], thanks for sharing the your idea.

bq.  However, I checked our previous releases that even since in 2.2 (may 
earlier), AM_RESYNC and AM_SHUTDOWN is already a public API that could be used 
in customers' application.

I think AMCommand is in the codebase since 2.1. I think [~jianhe] meant the new 
logic for RESYNC case is committed recently.

bq. i.e. add a new API to ApplicationMasterProtocol which throw exceptions 
instead of AMCommand. The old API still get supported for backward 

IMHO, it sounds an overcorrection for code refactoring work.

I think the essential problem here is whether throwing new sub exception which 
may not be handled before is an acceptable incompatible change, and therefore 
whether it is worth trading it for code refactoring. Thoughts?

> Replace AM resync/shutdown command with corresponding exceptions
> ----------------------------------------------------------------
>                 Key: YARN-2209
>                 URL: https://issues.apache.org/jira/browse/YARN-2209
>             Project: Hadoop YARN
>          Issue Type: Improvement
>            Reporter: Jian He
>            Assignee: Jian He
>         Attachments: YARN-2209.1.patch, YARN-2209.2.patch, YARN-2209.3.patch, 
> YARN-2209.4.patch, YARN-2209.5.patch
> YARN-1365 introduced an ApplicationMasterNotRegisteredException to indicate 
> application to re-register on RM restart. we should do the same for 
> AMS#allocate call also.

This message was sent by Atlassian JIRA

Reply via email to