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

Refactor Repository/Desired FK for All Tables

    XMLWordPrintableJSON

Details

    • Epic
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • None
    • None
    • None
    • None
    • Management Packs: Repository Version Refactor

    Description

      We need to remove/refactor the repo_version table. This means the relationships tied to repo_version will also need to be replaced. Some of the high-level work items are:

      • Associate MPack's with Repositories
      • Remove host_version and add new relationships for mpack installations on hosts
      • Change Upgrades to track Mpacks not repos


      • Removed repo_version table as it no longer serves a purpose (multiple mpacks of different versions can now come from the same repo)
      • Replaced the host_version table with mpack_host_state to represent whether an mpack was correct installed on appropriate hosts
      • Changed upgrade history to track the differences between 2 mpacks for a service group. This links back to an upgrade as well so we can have 2 SG's with 2 mpack source/targets in a single upgrade (think HDPCore and EDW in 1 upgrade plan)

      The entity associations would look like:

      /*
      Each Mpack has a collection of OS's, each OS with different URLs
      Redhat6, Redhat7, Ubuntu12
      */
      MPackEntity.getRepos() -> List<RepoOSEntity>
      
      /* 
      The OS can have any number of URLs
      HDP: http://repo.ambari.apache.org/hdp
      HDP-UTILS: http://repo.ambari.apache.org/hdp-utils
      HDP-GPL: http://repo.ambari.apache.org/hdp-gpl
      */
      RepoOsEntity.getRepoDefinitions() -> List<RepoDefinitionEntity>
      
      
      /*
      HDP-Core-Default
        Mpack 3.0.0.0 -> 3.0.0.1
        MPack 3.0.0.1 -> 3.1.0.0
      */
      ServiceGroupEntity.getUpgradeHistory() -> List<UpgradeHistory>
      UpgradeHistoryEntity.getSourceMPack() -> MPackEntity
      UpgradeHistoryEntity.getTargetMPack() -> MPackEntity
      
      /*
      Mpack HDP Core 3.0.0.0 -> Hosts 1, 2, and 3 are OK
      Mpack HDP Core 3.1.0.0 -> Hosts 1 and 2 are OK, Host 3 is INSTALL_FAILED
      */
      MPackEntity.getHostInstallState() -> List<MPackInstallState>
      

      Attachments

        1. ERD.png
          40 kB
          Jonathan Hurley

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: