Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1919417

Summary: [candlepin] Manifest delete takes 24 hours or more in large environment (60k consumers in owner)
Product: Red Hat Satellite Reporter: James Jeffers <jjeffers>
Component: CandlepinAssignee: ojanus
Status: CLOSED ERRATA QA Contact: Danny Synk <dsynk>
Severity: high Docs Contact:
Priority: high    
Version: 6.7.0CC: bbuckingham, bcourt, egolov, hhudgeon, jdickers, jjeffers, ltran, mmccune, nmoumoul, ojanus, pcreech
Target Milestone: 6.8.4Keywords: Performance, PrioBumpField, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: candlepin-3.1.24 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1840803 Environment:
Last Closed: 2021-02-24 12:47:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 2 Mike McCune 2021-02-06 16:36:43 UTC
Lai,

curious why this failedQA? I tested this with the dogfood server clone upgraded to 6.8.4 and did a delete and re-import. Was relatively quick and had no errors.

Comment 3 Lai 2021-02-08 13:49:35 UTC
Sorry guys, this was a mistake made on my part when I was training someone.  Changing this back.

Comment 4 Danny Synk 2021-02-17 18:56:12 UTC
Steps to retest:

1. Configure a Satellite with 60K entitled Candlepin consumers.

2. Double the default values for Tomcat's Java heap memory minimum and maximum:

    # grep JAVA_OPTS /etc/tomcat/tomcat.conf
    JAVA_OPTS="-Xms2048m -Xmx8192m"

3. Delete the manifest:

    # hammer subscription delete-manifest --organization-id 1

Expected Results:
On a Satellite 6.8.2 with 60K Candlepin consumers, deleting the manifest takes a relatively long time, if it finishes successfully at all. On a Satellite 6.8.4 with 60K Candlepin consumers, manifest deletion should finish successfully in a timely fashion.

Actual Results:
On a Satellite 6.8.2 with 60K Candlepin consumers, deleting the manifest creates a task that runs for over 24 hours with no apparent progress. On a Satellite 6.8.4 snap 1 with 60K Candlepin consumers, deleting the manifest completes successfully in just under 2 hours. 

Note: 
In testing Bug #1919418, I found that deleting the manifest completes in about 10 seconds if the deletion is initiated immediately after refreshing the manifest. This behavior appears reproducible: deleting the manifest on a Satellite 6.8.4 with 60K entitled Candlepin consumers consistently takes about 10 seconds if the manifest is refreshed immediately before deleting, while deleting the manifest without refreshing it first consistently takes just under 2 hours.

Verified on Satellite 6.8.4, snap 1 (candlepin 3.1.24-1).

Comment 9 errata-xmlrpc 2021-02-24 12:47:13 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 (Satellite 6.8.4 Async Bug Fix Update), 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-2021:0654