Uploaded image for project: 'Subscription Watch'
  1. Subscription Watch
  2. SWATCH-1519

ReportFiller usage in newer tally endpoint should set hasData true when running totals format is used

XMLWordPrintable

    • False
    • Hide

      None

      Show
      None
    • False

      The semantics around running total measurements on /tally/products/{product_id} calls need to be clarified.  Right now we are returning a record for every day in the time-span requested and marking days that don't have an associated measurement with has_data=false.  This doesn't really make sense with a running total since even if we don't have a measurement, we still do still have data.  Additionally, we shouldn't be returning future days since those would show the running total and we don't want to project that into the future.

      See https://github.com/RedHatInsights/rhsm-subscriptions/blob/76d4b11621d15380d08f162e6df3342a9683f06d/src/main/java/org/candlepin/subscriptions/tally/filler/TallySnapshotAdapter.java#L45-L63.

      The same sort of logic should be applied in https://github.com/RedHatInsights/rhsm-subscriptions/blob/76d4b11621d15380d08f162e6df3342a9683f06d/src/main/java/org/candlepin/subscriptions/tally/filler/TallyReportDataPointAdapter.java#L35 : hasData should be set to true for all dates including today's date and no dates beyond today should be returned.

        1. image-2023-08-21-08-36-19-504.png
          466 kB
          Diego de Oliveira Maranhao
        2. Screenshot from 2023-07-25 11-43-57.png
          353 kB
          Diego de Oliveira Maranhao
        3. Screenshot from 2023-07-31 09-18-47.png
          385 kB
          Diego de Oliveira Maranhao

              awood1@redhat.com Alex Wood
              khowell@redhat.com Kevin Howell
              Diego de Oliveira Maranhao Diego de Oliveira Maranhao
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: