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

Subscription Export does not include cloud billing account info

XMLWordPrintable

      Currently we are including the billing_provider & billing_account_id in the data exported for instances but we are not including the corresponding data on subscriptions. This means that customers are unable to help themselves when they are trying to determine why usage isn't being reported properly to a cloud provider. 

      Implementation
      java/com/redhat/swatch/contract/service/export/SubscriptionDataExporterService.java is responsible for creating the export. Steps to include the billing_provider & billing_account_id are:

      • Add the strings into schemas/subscriptions_export_json_item.yaml and schemas/subscriptions_export_csv_item.yaml
      • regenerate SubscriptionsExportCsvItem and SubscriptionsExportJsonItem to include the 2 new fields.
      • The repository is already pulling the data into SubscriptionCapacityView, no change required there.
      • SubscriptionCsvDataMapperService and SubscriptionJsonDataMapperService must populate the SubscriptionExportCsvItem and SubscriptionExportJsonItem from the SubscriptionCapacityView

      Testing

      • The unit test will be able to be expanded to test these 2 new fields SubscriptionDataExporterServiceTest
      • The existing integration test iqe_rhsm_subscriptions/tests/integration/exports/test_export_subscriptions.py can be enhanced to verify the fields.

              buschv Vanessa Busch
              bcourt@redhat.com Barnaby Court
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: