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

Prevent Multiple OS Entries For a Single Mpack

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • 3.0.0
    • 3.0.0
    • None

    Description

      The operating systems endpoint allows for creation and deletion of repositories which are associated with a single management pack:

      PUT http://{{ambari-server}}:8080/api/v1/mpacks/1/operating_systems/redhat7
      {
        "OperatingSystems" : {
          "is_ambari_managed" : true,
          "repositories" : [
            {
              "distribution" : null,
              "components" : null,
              "unique" : true,
              "tags" : [ ],
              "base_url" : "http://repo.ambari.apache.org/hdpcore/centos7/HDPCORE-1.0.0-b96/foo",
              "os_type" : "redhat7",
              "repo_id" : "HDPCORE-1.0.0-b96",
              "repo_name" : "HDPCORE",
              "mirrors_list" : null,
              "default_base_url" : null,
              "ambari_managed" : true
            },
            {
              "distribution" : null,
              "components" : null,
              "unique" : false,
              "tags" : [ ],
              "base_url" : "http://repo.ambari.apache.org/hdpcore/centos7/HDP-UTILS-1.1.0.22/foo",
              "os_type" : "redhat7",
              "repo_id" : "HDP-UTILS-1.1.0.21",
              "repo_name" : "HDP-UTILS",
              "mirrors_list" : null,
              "default_base_url" : null,
              "ambari_managed" : true
            }
          ]
        }
      }
      

      However, multiple PUTs causes duplicate entries for the same OS. This should be prevented.

      Attachments

        Issue Links

          Activity

            People

              jonathanhurley Jonathan Hurley
              jonathanhurley Jonathan Hurley
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 10m
                  1h 10m