Project

Profile

Help

Issue #8417

Errata in Pulp2 does not updated _last_updated if copied, it causes problems with re-migration

Added by ttereshc 7 months ago. Updated 7 months ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
High
Assignee:
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Platform Release:
OS:
Triaged:
No
Groomed:
No
Sprint Candidate:
No
Tags:
Katello
Sprint:
Sprint 93
Quarter:
Q1-2021

Description

To reproduce:

  • create and sync rpm_unsigned repo in pulp2
  • migrate it
  • create a repo copy1 and copy all content from rpm_unsigned
  • run a migration with the following plan
  • in the new repo version errata will be removed because it is not found in Pulp2Content for a copy1 repo.
{
    "plan": {
        "plugins": [
            {
                "repositories": [
                    {
                        "name": "rpm_unsigned",
                        "pulp2_importer_repository_id": "rpm_unsigned",
                        "repository_versions": [
                            {
                                "pulp2_distributor_repository_ids": [
                                    "rpm_unsigned"
                                ],
                                "pulp2_repository_id": "rpm_unsigned"
                            },
                            {
                                "pulp2_distributor_repository_ids": [
                                    "copy1"
                                ],
                                "pulp2_repository_id": "copy1"
                            }
                        ]
                    }
                ],
                "type": "rpm"
            }
        ]
    },
}

Alternatively, if you run for the second migration the migrate-all plan, the new repository will lack errata as well.

We likely need to work around it in the migration plugin, since updating _last_updated date for a copy in pulp 2 will cause problems in pulp2 world - publish will be operational for all repositories which contains an erratum if that erratum has been copied (Katello uses copy heavily).

Associated revisions

Revision e21447b7 View on GitHub
Added by ttereshc 7 months ago

Fix errata re-migration when it's been copied to a new repo in Pulp2

closes #8417 https://pulp.plan.io/issues/8417

Required PR:https://github.com/pulp/pulp-2to3-migration-test-fixtures/pull/5

Revision 07d9a3a1 View on GitHub
Added by ttereshc 7 months ago

Adjust pulp2_last_updated date for the copied errata.

Needed in order to allow user (e.g. Katello) to identify content changed since the last run. Pulp 2 copy operation doesn't update timestamps.

re #8417

Revision e21447b7 View on GitHub
Added by ttereshc 7 months ago

Fix errata re-migration when it's been copied to a new repo in Pulp2

closes #8417 https://pulp.plan.io/issues/8417

Required PR:https://github.com/pulp/pulp-2to3-migration-test-fixtures/pull/5

Revision 07d9a3a1 View on GitHub
Added by ttereshc 7 months ago

Adjust pulp2_last_updated date for the copied errata.

Needed in order to allow user (e.g. Katello) to identify content changed since the last run. Pulp 2 copy operation doesn't update timestamps.

re #8417

Revision e21447b7 View on GitHub
Added by ttereshc 7 months ago

Fix errata re-migration when it's been copied to a new repo in Pulp2

closes #8417 https://pulp.plan.io/issues/8417

Required PR:https://github.com/pulp/pulp-2to3-migration-test-fixtures/pull/5

Revision 07d9a3a1 View on GitHub
Added by ttereshc 7 months ago

Adjust pulp2_last_updated date for the copied errata.

Needed in order to allow user (e.g. Katello) to identify content changed since the last run. Pulp 2 copy operation doesn't update timestamps.

re #8417

History

#1 Updated by ttereshc 7 months ago

  • Subject changed from Errata in Pulp2 does not updated _last_updated if copied, it can causes problems with re-migration to Errata in Pulp2 does not updated _last_updated if copied, it causes problems with re-migration

#2 Updated by ttereshc 7 months ago

  • Status changed from NEW to ASSIGNED

#3 Updated by rchan 7 months ago

  • Sprint changed from Sprint 92 to Sprint 93

#4 Updated by ttereshc 7 months ago

  • Status changed from ASSIGNED to POST

#5 Updated by ttereshc 7 months ago

  • Status changed from POST to MODIFIED

#6 Updated by ttereshc 7 months ago

  • Tags Katello added

#7 Updated by ttereshc 7 months ago

  • Sprint/Milestone set to 0.10.0

#8 Updated by pulpbot 7 months ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Please register to edit this issue

Also available in: Atom PDF