Uploaded image for project: 'CDAP'
  1. CDAP
  2. CDAP-12647

CDAPEntities Stats page is over-counting the number of artifacts

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.3.0
    • Fix Version/s: 5.0.0
    • Component/s: App Fabric
    • Labels:
      None
    • Release Notes:
      Fixed a bug with artifacts count, as when we we get artifact count from a namespace we also include system artifacts count causing the total artifact count to be much larger than real count.
    • Rank:
      1|i0086f:

      Description

      We count the number of artifacts in the system, by calling ArtifactRepository#getArtifactSummaries, for each namespace:
      https://github.com/caskdata/cdap/blob/v4.3.0/cdap-operational-stats-core/src/main/java/co/cask/cdap/operations/cdap/CDAPEntities.java#L121

      However, for each namespace, it is also including the system-scoped artifacts. This makes it so that if there are 10 namespaces (each with 0 artifacts), and 20 system-scoped artifacts, the total number of artifacts that will be returned will be 200, whereas the correct answer is 20.

        Attachments

          Activity

            People

            • Assignee:
              shankar Shankar Selvam
              Reporter:
              ali.anwar Ali Anwar
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: