Bug 1624416
Summary: | Hammer command with content view version --order is not working as expected. | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Varatharaja Perumal G <vgunasek> |
Component: | Hammer - Content | Assignee: | Stephen Benjamin <stbenjam> |
Status: | CLOSED ERRATA | QA Contact: | Jameer Pathan <jpathan> |
Severity: | medium | Docs Contact: | |
Priority: | high | ||
Version: | 6.3.2 | CC: | jpathan, pcreech |
Target Milestone: | 6.5.0 | Keywords: | Regression, Triaged |
Target Release: | Unused | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2019-05-14 12:37:51 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Varatharaja Perumal G
2018-08-31 13:56:22 UTC
I was able to reproduce this behavior on 6.4, but not 6.2 as reported. Example from 6.2: ----------------- hammer> content-view version list --content-view RHEL6 --organization "Reference Satellite" --order 'version ASC' ---|-----------|---------|----------------------- ID | NAME | VERSION | LIFECYCLE ENVIRONMENTS ---|-----------|---------|----------------------- 4 | RHEL6 2.0 | 2.0 | 6 | RHEL6 3.0 | 3.0 | Library, Capsule_Sync ---|-----------|---------|----------------------- production.log: 2018-09-06 16:52:09 3f7f7c40 [app] [I] Processing by Katello::Api::V2::ContentViewsController#index as JSON 2018-09-06 16:52:09 3f7f7c40 [app] [I] Parameters: {"name"=>"RHEL6", "api_version"=>"v2", "organization_id"=>"1", "content_view"=>{}} 2018-09-06 16:52:09 3f7f7c40 [app] [I] Authorized user admin(Admin User) 2018-09-06 16:52:09 3f7f7c40 [app] [I] Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.170/app/views/katello/api/v2/content_views/index.json.rabl within katello/api/v2/layouts/collection (98.5ms) 2018-09-06 16:52:09 3f7f7c40 [app] [I] Completed 200 OK in 174ms (Views: 90.2ms | ActiveRecord: 26.3ms) 2018-09-06 16:52:09 2546c5eb [app] [I] Started GET "/katello/api/content_views/3/content_view_versions?page=1&per_page=1000&order=version+ASC&sort=%7B%22order%22%3D%3E%22version+ASC%22%7D" for 127.0.0.1 at 2018-09-06 16:52:09 -0400 2018-09-06 16:52:09 2546c5eb [app] [I] Processing by Katello::Api::V2::ContentViewVersionsController#index as JSON 2018-09-06 16:52:09 2546c5eb [app] [I] Parameters: {"page"=>"1", "per_page"=>"1000", "order"=>"version ASC", "sort"=>"{\"order\"=>\"version ASC\"}", "api_version"=>"v2", "content_view_id"=>"3", "content_view_version"=>{}} 2018-09-06 16:52:09 2546c5eb [app] [I] Authorized user admin(Admin User) 2018-09-06 16:52:10 2546c5eb [app] [I] Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.170/app/views/katello/api/v2/content_view_versions/index.json.rabl within katello/api/v2/layouts/collection (1046.8ms) 2018-09-06 16:52:10 2546c5eb [app] [I] Completed 200 OK in 1121ms (Views: 550.2ms | ActiveRecord: 514.9ms) Example from 6.4: ----------------- hammer> content-view version list --content-view "composite with versions" --organization "Default Organization" --order 'version DESC' ---|------|---------|----------------------- ID | NAME | VERSION | LIFECYCLE ENVIRONMENTS ---|------|---------|----------------------- (NOTE: there should be 2 versions returned). production.log: (note: no error in production.log, but format "order" parameter is different than on the earlier release.) 2018-09-06T16:55:07 [I|app|] Started GET "/katello/api/content_views/5/content_view_versions?organization_id=1&page=1&per_page=1000&order=version+DESC&sort[order]=version+DESC" for 10.8.0.142 at 2018-09-06 16:55:07 -0400 2018-09-06T16:55:07 [I|app|29622] Processing by Katello::Api::V2::ContentViewVersionsController#index as JSON 2018-09-06T16:55:07 [I|app|29622] Parameters: {"organization_id"=>"1", "page"=>"1", "per_page"=>"1000", "order"=>"version DESC", "sort"=>{"order"=>"version DESC"}, "api_version"=>"v2", "content_view_id"=>"5", "content_view_version"=>{}} 2018-09-06T16:55:07 [I|app|29622] Current user: foreman_admin (administrator) 2018-09-06T16:55:07 [I|app|29622] Authorized user admin(Admin User) 2018-09-06T16:55:07 [I|app|29622] Current user: admin (administrator) 2018-09-06T16:55:07 [I|app|29622] Rendering /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.22/app/views/katello/api/v2/content_view_versions/index.json.rabl within katello/api/v2/layouts/collection 2018-09-06T16:55:07 [I|app|29622] Rendered /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.22/app/views/katello/api/v2/content_view_versions/index.json.rabl within katello/api/v2/layouts/collection (0.8ms) 2018-09-06T16:55:07 [I|app|29622] Completed 200 OK in 35ms (Views: 1.4ms | ActiveRecord: 21.0ms) Created redmine issue https://projects.theforeman.org/issues/25145 from this bug Upstream bug assigned to stbenjam Upstream bug assigned to stbenjam Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/25145 has been resolved. verified @satellite 6.5.0 snap 4 steps: 1. Publish multiple version of a content view. 2. hammer> content-view version list --content-view zoo1 --organization-id 1 --order "version DESC" ---|----------|---------|----------------------- ID | NAME | VERSION | LIFECYCLE ENVIRONMENTS ---|----------|---------|----------------------- 14 | zoo1 3.0 | 3.0 | Library 13 | zoo1 2.0 | 2.0 | DEV 12 | zoo1 1.0 | 1.0 | ---|----------|---------|----------------------- observation: Hammer command with content view version --order is working as expected. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2019:1222 |