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

Gour Saha commented on YARN-4205:
---------------------------------

Thanks [~rohithsharma]. A few minor cosmetic follow-up comments, and 2 
additional fundamental questions.

h6. \[ApplicationTimeouts.java\]
{code}
   * Get life timeout of an application. The application will be killed
{code}
Change *life timeout* to lifetime.

{code}
   * @param lifeTimeout of an application in seconds.
{code}
Change *lifeTimeout* to lifetime.

{code}
  public abstract void setLifetime(long lifeTime);
{code}
Change *lifeTime* to lifetime (lowercase t)

h6. \[yarn-default.xml\]
{code}
    The RMAppLifeTimeMonitor Service uses this value as monitor interval.
{code}
Change to "The RMAppLifetimeMonitor Service uses this value as lifetime monitor 
interval." (note, lower-cased t in RMAppLifetimeMonitor and added lifetime 
after "value as")

h6. \[TestApplicationLifetimeMonitor.java\]
{code}
      Assert.assertTrue("Applicaiton killed before life timeout value",
{code}
Change "life timeout" to "lifetime" (note, this change is needed in 2 lines)

{code}
  public void testApplicationLifeTimeMonitor() throws Exception {
{code}
testApplicationLifeTimeMonitor -> testApplicationLifetimeMonitor (lowercase t)

{code}
  public void testApplicationLifeTimeOnRMRestart() throws Exception {
{code}
testApplicationLifeTimeOnRMRestart -> testApplicationLifetimeOnRMRestart 
(lowercase t)

h6. \[RMContextImpl.java\]
{code}
      RMAppLifetimeMonitor rmAppLifeTimeMonitor) {
{code}
rmAppLifeTimeMonitor -> rmAppLifetimeMonitor (lowercase t)

h6. \[MockRM.java\]
{code}
      long applicationLifeTime) throws Exception {
{code}
applicationLifeTime -> applicationLifetime (lowercase t)

There are 2 fundamental questions that come to my mind and I wanted to run 
across with you -

1. Should *AMRMClientAsync.onShutdownRequest* callback be raised to give AM to 
do some last minute work/cleanup/graceful-shutdown-opportunity? I don't think 
we need to, but still wanted to call it out and know your thoughts on this.

2. Seems like the lifetime is counted from the start of the application 
submission. Shouldn't it be counted from the time YARN allocates resource for 
the AM and launches it? What if YARN takes more time than the lifetime to 
allocate resource for the app? Seems like the KILL event will be raised 
immediately after the app reaches the RUNNING state in this case. Am I correct?


> Add a service for monitoring application life time out
> ------------------------------------------------------
>
>                 Key: YARN-4205
>                 URL: https://issues.apache.org/jira/browse/YARN-4205
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: scheduler
>            Reporter: nijel
>            Assignee: Rohith Sharma K S
>         Attachments: 0001-YARN-4205.patch, 0002-YARN-4205.patch, 
> 0003-YARN-4205.patch, 0004-YARN-4205.patch, 0005-YARN-4205.patch, 
> YARN-4205_01.patch, YARN-4205_02.patch, YARN-4205_03.patch
>
>
> This JIRA intend to provide a lifetime monitor service. 
> The service will monitor the applications where the life time is configured. 
> If the application is running beyond the lifetime, it will be killed. 
> The lifetime will be considered from the submit time.
> The thread monitoring interval is configurable.



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

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

Reply via email to