Bug #11140
Reindex needs to handle bad errata and package/packagegroups etc
Description
The reindex task assumes that [Katello::Package, Katello::PuppetModule, Katello::Distribution, Katello::PackageGroup, Katello::Erratum] all have an "each" method in the case of on error. This causes an additional error thrown every time indexing one of those items fail. We just need to report the exception at the bulk level in those cases and not try to index one at a time.
Also we need to handle errata that point to repo memberships that do not exist in katello (as in we need to ignore those associations). This can happen either when user directly create/syncs a private repo via pulp-admin OR deletes a repo and for some reason the membership did not get updated.
Associated revisions
History
#1
Updated by The Foreman Bot over 7 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/Katello/katello/pull/5358 added
- Pull request deleted (
)
#2
Updated by Eric Helms over 7 years ago
- Legacy Backlogs Release (now unused) set to 31
- Triaged changed from No to Yes
#3
Updated by Bryan Kearney over 7 years ago
- Bugzilla link set to 1253006
#4
Updated by Bryan Kearney over 7 years ago
- Bugzilla link changed from 1253006 to 1253010
#5
Updated by Justin Sherrill over 7 years ago
- Assignee changed from Partha Aji to Justin Sherrill
- Pull request https://github.com/Katello/katello/pull/5417 added
- Pull request deleted (
https://github.com/Katello/katello/pull/5358)
#6
Updated by Partha Aji over 7 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset katello|7d3538960c882b1126d610b8548aecb4ab9b1b91.
Fixes #11140 - Improved reindex for backend search classes
Prior this commit the reindex task assumed that [Katello::Package,
Katello::PuppetModule, Katello::Distribution, Katello::PackageGroup,
Katello::Erratum] all have an "each" method in the case of on error.
This caused an additional "No Such Method" error thrown every time indexing one of those
items failed.
This error handling has been fixed in this commit
Also included is a fix for Katello::Erattum import_all
We can now handle errata that point to repo memberships that do not
exist in katello (as in we ignore those associations).
This typically happens either when user directly create/syncs a private repo
via pulp-admin (there by it existing in pulp but not katello) OR deletes a repo
and for some reason the repo membership for that errata did not get updated in pulp.