Sync not complete due to a package missing in upstream jenkins mirror

Problem:
Repo sync not completed because some packages are missing in upstream

Expected outcome:
Skip on packages that are not available and not delete everything.

Foreman and Proxy versions:
Foreman 3.7. no proxy. all in one setup

Foreman and Proxy plugin versions:
Foreman 3.7 & Katello 4.9

Distribution and version:
Rocky 8.8

Other relevant data:

Hi

I have created a repo in a product for jenkins. the main upstream url for this is Redhat Jenkins Packages which will forward the request to a mirror.
On the mirror seems like only the recent packages are kept as this is a weekly release repository, but the metadata still exists and repo info is probably not updated. So I’m getting a 404 for a package not being available and nothing is synced.

is there a way to be able to skip on packages that are not available or should I just change this repository download policy to “On-Demand”?

Thanks

The best thing would be if you could open a ticket with the owner of that upstream repository and ask them to provide consistent metadata.

AFAIK your only short term option is “On-Demand” policy. I remember there have been discussions about providing this kind of feature (skip packages that fail to download, filter during sync, or similar) before, but the Pulp team is not too enthusiastic about it. If you do want to advocate for this, you should probably open a feature request here: Issues · pulp/pulp_rpm · GitHub

Yes. I’ve already set it as on-demand.

Thanks for replying.