Bug 1294534

Summary: [Disconnected] Uploading new manifest does not appear to replace the previous manifest
Product: Red Hat Quickstart Cloud Installer Reporter: Thom Carlin <tcarlin>
Component: WebUIAssignee: Erik Nelson <ernelson>
Status: CLOSED ERRATA QA Contact: Thom Carlin <tcarlin>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 1.0CC: ernelson, jesusr, jmagen, jmatthew, tsanders
Target Milestone: gaKeywords: Triaged
Target Release: 1.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-13 16:23:44 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:

Description Thom Carlin 2015-12-28 20:49:16 UTC
Description of problem:

When problems occur with a manifest, going back to Content Provider allows upload of new manifest.  However, the manifest does not appear to be updated

Version-Release number of selected component (if applicable):

TP2

How reproducible:

100%

Steps to Reproduce:
1. Install in disconnected mode up to Installation resulting in a manifest error.
2. Go back to "Content Provider" and upload a new manifest
3. Examine Review Subscriptions

Actual results:

Old manifest information is displayed
Old manifest is used during installation

Expected results:

New manifest information is displayed
New manifest is used during installation

Additional info:

Workaround: Delete deployment and recreate

Comment 1 John Matthews 2016-06-14 19:23:25 UTC
Please re-test, if still a problem recommend we reassign to Sat 6 component.

Comment 2 Thom Carlin 2016-07-13 20:48:06 UTC
For QCI 1.2, used manifest from 12/2015 resulting in "{:basearch=>"x86_64", :releasever=>"7Server"} are not valid substitutions for /content/dist/rhel/server/7/$releasever/$basearch/rh-common/os. No valid metadata files found for /content/dist/rhel/server/7/7Server/x86_64/rh-common/os"

Uploaded a new manifest at https://<<sat6_fqdn>>/r/#/deployments/<<deployment_number>>/subscriptions/credentials

Both old and new manifests are displayed [see private screenshot]

Installation didn't restart -- was stuck at error [see private screenshot]

Failed QA, moving back to assigned

Comment 5 jmagen@redhat.com 2016-07-20 13:18:55 UTC
I can't duplicate this bug. I uploaded a manifest and then went to "Review Subscriptions" and then uploaded a new manifest and saw different data in "Review Subscriptions"

Comment 12 Jesus M. Rodriguez 2016-08-05 19:49:55 UTC
What joseph states in comment #5 is correct. You can upload a new manifest as many times as you want BEFORE hitting deploy on the deployment. I have confirmed what he saw that the review screen properly shows the updated subscription information.

Comment 13 Jesus M. Rodriguez 2016-08-05 19:52:41 UTC
With the updated subscription validation, the original comment is no longer a valid scenario. You are not allowed to upload a new manifest once a deployment has started, even if it fails. You are supposed to go to the Satellite subscription and delete the manifest first.

Having said that I have been able to get the UI into a state that would allow me to get back to the upload screen after a deployment failed. The good news is I was not able to upload a new manifest, the system ignored it because of the safety validations we put in. But the UI shouldn't have let me get to the credentials page.

Comment 14 Erik Nelson 2016-08-08 18:05:04 UTC
PR: https://github.com/fusor/fusor/pull/1135

Comment 15 John Matthews 2016-08-08 21:56:29 UTC
Will be in evening compose of 8/8

Comment 16 Thom Carlin 2016-09-01 11:14:36 UTC
FailedQA in QCI-1.0-RHEL-7-20160830.t.0

Since the web UI changed substantially from TP2, here are the new reproducer steps:
1. Install/configure QCI
2. Deploy RHV in disconnected mode
3. At Subscriptions > Content Provider, upload a manifest.  I used 10 SKU A and 10 SKU B subscriptions
4. Receive "Successful upload" message
5. At Subscriptions > Review Subscriptions, verify correct subscriptions appear
6. Navigate to Subscriptions > Content Provider [again]
7. At "You successfully uploaded manifest /usr/share/foreman/tmp/import_<<uuid>>.zip
You may upload a different manifest.", click on "Upload" hyperlink
8. Choose a new manifest file.  I used 1 x 5 SKU A subscriptions
9. Click Upload button
10. Receive "Successful upload" message [again]
11. Click Next
12. At Subscriptions > Review Subscription page, verify correct subscriptions appear:

Actual results

* 5 SKU A
* 10 SKU B

Expected results

* 5 SKU A
[No SKU B]

Workaround:
Content > Red Hat Subscriptions
Delete Manifest

Comment 17 Erik Nelson 2016-09-01 19:28:11 UTC
PR to address stale subscription data:

https://github.com/fusor/fusor/pull/1202

Comment 18 Thom Carlin 2016-09-10 15:17:10 UTC
Verified in fusor-release-1.0.0-3.el7_2:

You successfully uploaded manifest /usr/share/foreman/tmp/import_5c9f0b8149ca5d55a1be.zip
Subscription Name	Contract Number	Start Date	End Date	Quantity Attached	Total Quantity
Red Hat Cloud Infrastructure (without guest OS), Premium (2-sockets)	10864524	Jan 19, 2016	Jan 18, 2017	10	100
OpenShift Business Partner Self-Supported NFR	10981564	May 31, 2016	May 30, 2017	10	500

You successfully uploaded manifest /usr/share/foreman/tmp/import_a930533fd819f04c686f.zip
You may upload a different manifest.
Red Hat Cloud Infrastructure (without guest OS), Premium (2-sockets)	10864524	Jan 19, 2016	Jan 18, 2017	5	100

Could not upload the second time without logging out and logging back in.  Please create a new bz if the new issue reoccurs

Comment 20 errata-xmlrpc 2016-09-13 16:23:44 UTC
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/RHEA-2016:1862