Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-10316

Stack-advisor mechanism when recommending configuration-dependencies has incorrect services.json content

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • 2.1.0
    • 2.1.0
    • ambari-server, stacks
    • None

    Description

      When the POST call is made for recommending configuration-dependencies, we generate the services.json file with following extra content:

        "changed-configurations" : [ {
          "type" : "yarn-site",
          "name" : "yarn.scheduler.maximum-allocation-mb"
        } ],
        "depended-configurations" : [ {
          "type" : "mapred-site",
          "name" : "yarn.app.mapreduce.am.resource.mb"
        }, {
          "type" : "yarn-site",
          "name" : "yarn.scheduler.maximum-allocation-mb"
        }, {
          "type" : "mapred-site",
          "name" : "yarn.app.mapreduce.am.admin-command-opts"
        }, {
          "type" : "mapred-site",
          "name" : "mapreduce.map.memory.mb"
        }, {
          "type" : "mapred-site",
          "name" : "yarn.app.mapreduce.am.command-opts"
        }, {
          "type" : "mapred-site",
          "name" : "mapreduce.reduce.java.opts"
        }, {
          "type" : "mapred-site",
          "name" : "mapreduce.reduce.memory.mb"
        }, {
          "type" : "mapred-site",
          "name" : "mapreduce.task.io.sort.mb"
        }, {
          "type" : "mapred-site",
          "name" : "mapreduce.map.java.opts"
        } ]
      

      The configuration depended-by should not be added on to the services.json like this. All the configuration dependencies should be got from manipulating the org.apache.ambari.server.api.services.stackadvisor.commands.StackAdvisorCommand.GET_SERVICES_INFO_URI value. Changing the value to include configuration depends_on and depended_by information. Then the python script should build the dependency-chain inside itself instead of doing it in Java and adding to services.json.

      The reason this is important is that for future functionality, we need services.json and hosts.json to faithfully represent the cluster's services and hosts information. The custom stack-advisor scripts should have logic to interpret it for their own needs. If we do some processing in Java, then stack-providers will not have chance to make their own interpretations.

      Attachments

        1. AMBARI-10316.patch
          16 kB
          Dmytro Sen

        Issue Links

          Activity

            People

              dsen Dmytro Sen
              dsen Dmytro Sen
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: