Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.

Bug 1366523

Summary: GUI: contract selection dialogue doesnot let you change the quantity of the subscription
Product: Red Hat Enterprise Linux 7 Reporter: Shwetha Kallesh <skallesh>
Component: subscription-managerAssignee: William Poteat <wpoteat>
Status: CLOSED ERRATA QA Contact: Jan Stavel <jstavel>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.3CC: csnyder, jstavel, khowell, redakkan, skallesh, wpoteat
Target Milestone: rcKeywords: Triaged
Target Release: 7.4   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-01 19:18:42 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:
Attachments:
Description Flags
Contract selection dialogue before trying the adjust the quantity
none
Contract selection dialogue after trying the adjust the quantity
none
My subscriptions tab when you click on attach without trying to modify the quantity in contract selection dialogue
none
Contract Selection dialog none

Description Shwetha Kallesh 2016-08-12 08:35:14 UTC
Created attachment 1190300 [details]
Contract selection dialogue before trying the adjust the quantity

Description of problem:
contract selection dialogue doesnot let you change the quantity of the subscription(Multi-entitled) of type Both

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


How reproducible:


Steps to Reproduce:
a)launch GUI -----> register the system without auto-attaching the subscriptions

b)Go to All Available Subscriptions Tab ------> Select a multi-entitled subscription of type both 

c) Increase the quantity using the quantity spinner in the All Available Subscriptions Tab 

d)Now click on Attach button --------> contract selection dialogue opens ------> Try to adjust the quantity


Actual results:
Quantity is set to 1 and quantity spinner is disabled
P.S attachment 1 [details], 2

Expected results:
should be allowed to adjust quantity

Additional info:
If you click on attach button without adjusting the quantity on contract selection dialogue , the quantity set using the quantity spinner in the All Available Subscriptions Tab is attached , which is greater than 1 

P.S attachment 3 [details]

Comment 1 Shwetha Kallesh 2016-08-12 08:35:50 UTC
Created attachment 1190301 [details]
Contract selection dialogue after trying the adjust the quantity

Comment 2 Shwetha Kallesh 2016-08-12 08:37:50 UTC
Created attachment 1190302 [details]
My subscriptions tab when you click on attach without trying to modify the quantity in contract selection dialogue

Comment 4 John Sefler 2016-08-12 15:27:09 UTC
Adding some more info to this issue....
This is being reported against SKU MCT2887 which is a stackable SKU with an unlimited virt_limit but is not host_limited.  Moreover, there is only 1 available quantity left in the pool.  And the bug issue is being reported against sub-man-gui running on a guest.

Here is the physical pool with a remaining quantity of 1 and it's unlimited bonus pool...

[root@jsefler-rhel7 ~]# subscription-manager list --avail --matches=MCT2887
+-------------------------------------------+
    Available Subscriptions
+-------------------------------------------+
Subscription Name:   Red Hat Enterprise Linux OpenStack Platform, Standard (2-sockets)
Provides:            Red Hat Beta
                     Red Hat OpenStack Beta
                     dotNET on RHEL Beta (for RHEL Server)
                     Red Hat Software Collections (for RHEL Server)
                     Red Hat Ceph Storage MON
                     Red Hat Ceph Storage
                     Oracle Java (for RHEL Server)
                     Red Hat Ceph Storage Calamari
                     Red Hat OpenStack
                     Red Hat Enterprise MRG Messaging
                     Red Hat Enterprise Linux High Availability (for RHEL Server)
                     Red Hat Enterprise Linux Server
                     dotNET on RHEL (for RHEL Server)
                     Red Hat Software Collections Beta (for RHEL Server)
                     Red Hat Enterprise Linux Load Balancer (for RHEL Server)
                     Red Hat CloudForms
SKU:                 MCT2887
Contract:            10800894
Pool ID:             8a85f98150676ebd01506846bd44779d
Provides Management: No
Available:           1
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Stackable
Ends:                10/13/2016
System Type:         Physical

Subscription Name:   Red Hat Enterprise Linux OpenStack Platform, Standard (2-sockets)
Provides:            Red Hat Beta
                     Red Hat OpenStack Beta
                     dotNET on RHEL Beta (for RHEL Server)
                     Red Hat Software Collections (for RHEL Server)
                     Red Hat Ceph Storage MON
                     Red Hat Ceph Storage
                     Oracle Java (for RHEL Server)
                     Red Hat Ceph Storage Calamari
                     Red Hat OpenStack
                     Red Hat Enterprise MRG Messaging
                     Red Hat Enterprise Linux High Availability (for RHEL Server)
                     Red Hat Enterprise Linux Server
                     dotNET on RHEL (for RHEL Server)
                     Red Hat Software Collections Beta (for RHEL Server)
                     Red Hat Enterprise Linux Load Balancer (for RHEL Server)
                     Red Hat CloudForms
SKU:                 MCT2887
Contract:            10800894
Pool ID:             8a85f98150676ebd01506846bdee77be
Provides Management: No
Available:           Unlimited
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Stackable
Ends:                10/13/2016
System Type:         Virtual



When I ran sub-man-gui on a physical system for this account, the spinner box correctly did not spin limiting me to the max quantity available of 1.  This is the expected behavior.

When I ran sub-man-gui on a virtual system for this account, the spinner box actually allows me to increment the spinner on the "available subscriptions" tab where both pools are consolidated which is technically correct behavior since the available quantity is unlimited on my virtual system.  Keeping the spinner incremented to a value > 1 (say 8) and clicking attach will bring up the contract selection dialog with 8 on the virtual pool and 1 on the physical pool.  This is also correct behavior.  Then clicking the spinner on the virtual contract will warp the value to 1 making it unspinable because the max avail on the physical pool is 1.  This is technically wrong and is definitely a corner case.   This is a bug on the contract quantity spinner corresponding to the virtual pool, not the physical pool (which should and is limited to the physical quantity available).

Hence this bug only applies to the virtual contract of an unlimited guest pool.

Comment 6 Shwetha Kallesh 2017-04-07 06:29:44 UTC
Created attachment 1269573 [details]
Contract Selection dialog

Comment 7 Shwetha Kallesh 2017-04-07 06:34:20 UTC
Spinner in the contract selection box now allows to increment the quantity of virtual pool and does not restrict to only quantity of physical pools availables

[root@dhcp70-154 ~]# subscription-manager version
server type: Red Hat Subscription Management
subscription management server: 0.9.51.21-1
subscription management rules: 5.15.1
subscription-manager: 1.19.4-1.el7
python-rhsm: 1.19.2-1.el7

Comment 8 errata-xmlrpc 2017-08-01 19:18:42 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/RHBA-2017:2083