hadoop-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hitesh Shah <hit...@hortonworks.com>
Subject Re: YARN Container's App ID
Date Tue, 11 Jun 2013 18:54:21 GMT
Hello Brian,

org.apache.hadoop.yarn.api.ApplicationConstants.Environment should have a list of all the
information set in the environment. 

One of these is the container ID. ApplicationAttemptID can be obtained from a container ID
object which in turn can be used to get the App Id. 

-- Hitesh

On Jun 11, 2013, at 11:47 AM, Brian C. Huffman wrote:

> How can a YARN container get its own Application ID?
> I tried getting the ApplicationConstants.AM_APP_ATTEMPT_ID_ENV similar to how the Distributed
Shell example does for the AppMaster, but that variable doesn't seem to exist in the environment
for the container.  Does the App Master have to set it?
> Thanks,
> Brian

View raw message