Bug 1459107

Summary: subscription-manager list --available displays "Temporary" pools with 1yr validity
Product: Red Hat Enterprise Linux 7 Reporter: Rehana <redakkan>
Component: subscription-managerAssignee: candlepin-bugs
Status: CLOSED NOTABUG QA Contact: John Sefler <jsefler>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.4CC: redakkan, skallesh
Target Milestone: rc   
Target Release: ---   
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-06-06 10:48:19 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 Rehana 2017-06-06 10:27:40 UTC
Description of problem:
 With the recent change bug 1450081 on the validity 24hr Temporary pools , its observed that now the list --available on a unmapped guest displays 1year valid temporary pools instead of 1 week

Version-Release number of selected component (if applicable):
subscription management server: 2.1.1-1
subscription management rules: 5.23
subscription-manager: 1.19.17-1.el7
python-rhsm: 1.19.8-1.el7

How reproducible:
always

Steps to Reproduce:
1.Register a unmapped guest to candlepin server
2.execute `subscription-manager list --available ` on the guest

Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            1
Pool ID:             8ac6a3625c7cdb93015c7cdd9a57020e
Provides Management: No
Available:           20
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Instance Based (Temporary)
Ends:                06/05/2018
System Type:         Virtual

Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            0
Pool ID:             8ac6a3625c7cdb93015c7cdd98c601e0
Provides Management: No
Available:           10
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Instance Based (Temporary)
Ends:                06/05/2018	==> Notice the end date this show 1yr validitiy
System Type:         Virtual

Subscription Name:   Admin OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
                     Admin OS Premium Architecture Bits
                     Admin OS Developer Bits
SKU:                 adminos-onesocketib
Contract:            0
Pool ID:             8ac6a3625c7cdb93015c7cdd90d50149
Provides Management: No
Available:           10
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Instance Based (Temporary)
Ends:                06/05/2018 ==> Notice the end date this show 1yr validitiy
System Type:         Virtual

Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            1
Pool ID:             8ac6a3625c7cdb93015c7cdd9a0601ff
Provides Management: No
Available:           20
Suggested:           1
Service Level:       Standard
Service Type:        L1-L3
Subscription Type:   Instance Based
Ends:                06/05/2018

3.Attach a temporary pool 


[root@dhcp150-207 ~]# subscription-manager attach --pool 8ac6a3625c7cdb93015c7cdd98c601e0
Successfully attached a subscription for: Awesome OS Instance Based one socket

[root@dhcp150-207 ~]# subscription-manager list --consumed
+-------------------------------------------+
   Consumed Subscriptions
+-------------------------------------------+
Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            0
Account:             12331131231
Serial:              1911201777748971513
Pool ID:             8ac6a3625c7cdb93015c7cdd98c601e0
Provides Management: No
Active:              True
Quantity Used:       1
Service Level:       Standard
Service Type:        L1-L3
Status Details:      Guest has not been reported on any host and is using a temporary unmapped guest subscription.
Subscription Type:   Instance Based (Temporary)
Starts:              06/05/2017
Ends:                06/13/2017-- > notice the end date changed to 1 week
System Type:         Virtual

Actual results:
Observed Ends: date on temporary pools were set to 1 yr 

Expected results:
subscription-manager list --available should display the end date of temporary pool with 1 week validity 


Additional info:

Comment 1 Rehana 2017-06-06 10:48:19 UTC
closing as a Not a bug