Project

General

Profile

Actions

Bug #35572

closed

Make cv publish fail on invalid/non existent content

Added by Partha Aji about 2 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Content Views
Target version:
Difficulty:
medium
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

Customers who have upgraded from katello 3.18 and above in some instances seem to have repositories that do not have any candlepin content. This is possibly related to manifest expiration (which deletes the subs in candlepin but keeps the repo in Katello db)

We need the content view publish Not to happen with a clear message if any of the repositories in that content view has no content.

Not able to exactly reproduce this situation but here are some rails commands to try
1) Create a custom product and repository
2) foreman-rake console
3)

> root = ::Katello::RootRepository.last
> ::Katello::Resources::Candlepin::Product.remove_content(root.product.organization.label, root.product.cp_id, root.content_id)
> ::Katello::Resources::Candlepin::Content.destroy(root.product.organization.label, root.content_id)

4) Add this repo to a content view and publish.

Expected:
Error asking the invalid repo to be removed before publish starts

Actual:
Error in finalize pausing the task and causing all kinds of side effects.

Actions #1

Updated by Partha Aji about 2 years ago

  • Bugzilla link set to 2032040
Actions #2

Updated by The Foreman Bot about 2 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Partha Aji
  • Pull request https://github.com/Katello/katello/pull/10294 added
Actions #3

Updated by Chris Roberts about 2 years ago

  • Target version set to Katello 4.7.0
  • Difficulty set to medium
  • Triaged changed from No to Yes
Actions #4

Updated by The Foreman Bot about 2 years ago

  • Fixed in Releases Katello 4.7.0 added
Actions #5

Updated by Partha Aji about 2 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF