hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jian He (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-5610) Initial code for native services REST API
Date Tue, 04 Oct 2016 05:22:20 GMT

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

Jian He commented on YARN-5610:

- The component name is used in the compNameArtifactIdMap but then the name is overridden
by the artifact Id, is the component name expected to be overridden? the API document says
this field is mandatory 
          compNameArtifactIdMap.put(comp.getName(), comp.getArtifact().getId());

- comments seems not matching code
    // If artifact is of type APPLICATION, then in the POST JSON there will
    // be no component definition for that artifact. Hence it's corresponding id
    // field is added. Every external APPLICATION has a unique id field.
    List<String> convertedDeps = new ArrayList<>();
    for (String dep : component.getDependencies()) {
      if (compNameArtifactIdMap.containsKey(dep)) {
      } else {
bq. I have some TODOs on global config which I wanted to get back to. Let me check and remove
if not required.
I don't see the TODOs in this method, should it be removed ? similarly configPrefix
- why is queueName set to label_expression ? Also queueName is not being set anywhere
    if (queueName != null) {
          ResourceKeys.YARN_LABEL_EXPRESSION, queueName));
- why is the PROPERTY_APP_RUNAS_USER variable needed? Usually we switch to the correct user
and then start the service. Also, it's not appropriate to run it as root if user is not set.
IIUC, I think setting "SLIDER_USER = UserGroupInformation.getCurrentUser();" is enough.  
  private static String getUserToRunAs() {
    String user = System.getenv(PROPERTY_APP_RUNAS_USER);
    if (StringUtils.isEmpty(user)) {
      user = "root";
    return user;
- sorry, didn't get it. why you need to bind "help", when creating slider client ?
If you see ActionHelpArgs you will see that it overrides getHadoopServicesRequired and returns
false. Help is the safest action to bind since there are hardly any other action which does
not need any additional params
- why here in deleteApplication, it needs to wait for the appName to appear? I'm afraid such
short sleep interval with a getAllApplcations call will overwhelm RM if any bug appears and
the loop doesn't break. 
      while (getSliderList(appName) == 0) {
        Thread.sleep(100); // don't use thread sleep

> Initial code for native services REST API
> -----------------------------------------
>                 Key: YARN-5610
>                 URL: https://issues.apache.org/jira/browse/YARN-5610
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Gour Saha
>            Assignee: Gour Saha
>             Fix For: yarn-native-services
>         Attachments: YARN-4793-yarn-native-services.001.patch, YARN-5610-yarn-native-services.002.patch,
> This task will be used to submit and review patches for the initial code drop for the
native services REST API 

This message was sent by Atlassian JIRA

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

View raw message