Bug 750872 - Healing Cannot Complete Partial Stack For Products That Are Not Installed
Summary: Healing Cannot Complete Partial Stack For Products That Are Not Installed
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Candlepin
Classification: Community
Component: candlepin
Version: 0.5
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: ---
Assignee: Bryan Kearney
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-11-02 15:50 UTC by Devan Goodwin
Modified: 2016-07-22 14:40 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-22 14:40:10 UTC


Attachments (Terms of Use)

Description Devan Goodwin 2011-11-02 15:50:24 UTC
Description of problem:

If a healing request is made on a client which has manually subscribed to a stacked subscription, but has not completed the stacking requirements (not enough sockets covered), the autobind/healing code cannot complete the stack for them.

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

671dde8af6f06f6d11685c9c543e49373d7d56ec

How reproducible:

100%

Steps to Reproduce:

See included patch for a spec test which exposes the problem, but essentially:

1. Register a consumer with no installed products.
2. Manually bind to a stacked subscription, but with too few entitlements to cover the consumer's sockets.
3. Request an auto-bind/heal. (subscription-manager subscribe --auto)
  
Actual results:

The stack is not completed.

Expected results:

Additional entitlements should be granted.

Additional info:

This is definitely the case for a system with no installed products, I also suspect it would be the case for a system with installed products, but they are not provided by the stacked subscription.

At least two issues involved, one is addressed in the included patch, we were filtering out pools before calling the select best pools rule if they did not provide something installed.

Even after this is applied, select best pools will run but does not return any results. At this point I was not sure how to proceed and due to the low priority of this edge case decided to file a bug.

Use attached patch as a starting point.

Comment 1 Carter Kozak 2013-08-19 17:24:24 UTC
This was fixed in an autobind rewrite.  Here are the commits:

commit fcf4838742aff7db84ce2aeb76b78c884f8baca1
Author: ckozak <ckozak>
Date:   Mon Aug 19 13:00:14 2013 -0400

    style, ===, missing semicolons, typos

commit 74b2f6307e0d37053ff68ffff1cb9b4a93d46e97
Author: ckozak <ckozak>
Date:   Mon Aug 19 10:39:38 2013 -0400

    changed some tests

commit c52de0a3dcf92a82cf36983c59400101dfa1c3c8
Author: ckozak <ckozak>
Date:   Tue Aug 13 15:20:43 2013 -0400

    better removal of unnecessary pools by attribute.  testing

commit 86357662c0103bd07e895b523dd961437445722b
Author: ckozak <ckozak>
Date:   Tue Aug 13 11:50:52 2013 -0400

    added some comments, fixed some edge cases

commit fed5a6a379d0d131525890e009a2faf09afd0a11
Author: ckozak <ckozak>
Date:   Thu Aug 8 16:06:32 2013 -0400

    updating autoheal

Comment 2 Carter Kozak 2013-08-23 19:07:02 UTC
commit 32b5f9eca73b2a4c5b1cd392c0759ac107c26612
Author: ckozak <ckozak>
Date:   Fri Aug 23 12:48:04 2013 -0400

    750872: complete partial stacks with no installed products

Comment 4 Mike McCune 2016-03-28 22:20:08 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 5 Barnaby Court 2016-07-22 14:40:10 UTC
Moving to closed per the updated candlepin process for bugs that have been merged or have been taken care of.


Note You need to log in before you can comment on or make changes to this bug.