Bug #25143
closedcomposite_content_view_ids field of a content_view_version is always empty
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1553105
Description of problem:
Assume the following setup:Composite Content View "Capsule 6.3 with RHEL7 Server" with
- Content View "RHEL7"
- Content View "Tools 6.3 RHEL7"
- Content View "Capsule 6.3 RHEL7"
For some housekeeping, I'd like to remove old versions of "RHEL7" and "Capsule 6.3 RHEL7", which are not used by the CCV anymore.
To do so, I'd request all versions of said CVs (/katello/api/content_views/:content_view_id/content_view_versions) and delete all that have an empty composite_content_view_ids, assuming the version is not used by any CCV.
The field is also empty when looking at a specific version via /katello/api/content_view_versions/:content_view_version_id.
This worked fine in 6.2.z, but fails in 6.3.0, as composite_content_view_ids is always [].
hammer shows the info correctly:- hammer content-view info --name "Capsule 6.3 with RHEL7 Server" --organization Sat6-CI
ID: 54
Name: Capsule 6.3 with RHEL7 Server
Label: Capsule_6_3_with_RHEL7_Server
Composite: true
Description:
Content Host Count: 0
Organization: Sat6-CI
Yum Repositories:
…
Docker Repositories:
OSTree Repositories:
Puppet Modules:
Lifecycle Environments:
1) ID: 2
Name: Library
Versions:
…
Components:
1) ID: 4365
Name: Capsule 6.3 RHEL7 248.0
2) ID: 4362
Name: Tools 6.3 RHEL7 247.0
3) ID: 4297
Name: RHEL7 18.0
And so does the API at /katello/api/content_views/:content_view_id in the "components" field.
Version-Release number of selected component (if applicable):
satellite-6.3.0-23.0.el7sat.noarch
How reproducible:
100%
Steps to Reproduce:
1. create (and publish) a CV
2. create (and publish) a CCV that includes the CV from step 1
3. fetch /katello/api/content_views/:content_view_id/content_view_versions for the CV
Actual results:
composite_content_view_ids is empty
Expected results:
composite_content_view_ids shows that it's used in CCV
Additional info:
Updated by The Foreman Bot about 6 years ago
- Status changed from New to Ready For Testing
- Assignee set to Andrew Kofink
- Pull request https://github.com/Katello/katello/pull/7740 added
Updated by Andrew Kofink about 6 years ago
- Has duplicate Bug #23458: content_view_versions is not showing correct data for composite_content_view_id added
Updated by Justin Sherrill about 6 years ago
- Subject changed from composite_content_view_ids field of a content_view_version is always empty to composite_content_view_ids field of a content_view_version is always empty
- Target version set to Katello 3.9.0
- Fixed in Releases Katello 3.9.0 added
Updated by Andrew Kofink about 6 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset katello|cd99f28a3270995ce607403b27f39124cc49d058.