Red Hat Bugzilla – Bug 845941
Custom repository relative path prefix collision
Last modified: 2013-02-27 11:59:19 EST
Created attachment 602456 [details]
Description of problem:
If there is a repository with its relative path being a prefix of a new repository being created, an exception is thrown upon commit. If this is desirable behavior then documentation should mention such a limitation.
Version-Release number of selected component (if applicable):
- build: RHEL-6.3-RHUI-2.1-20120801.0-Server-x86_64-DVD1.iso
- pulp: 0.0.263-25.el6_3
- rh-rhui-tools: 2.1.7-1.el6_3
2 of 2 confirmed, but seems always
Steps to Reproduce:
1. create custom repository, id: 'prefix', with relative path: 'prefix'
2. create custom repository, id: 'prefix-1', with relative path: 'prefix-1/x86_64'
3. error committing repository id: 'prefix-1'
error trying create repository with its relative path being a prefix of another repository relative path
One is either able to create a repository with its relative path being a prefix of another repository relative path or the Documentation should mention the relative path limitation
- see the screen log attached
I recreated the issue with two custom repositories that use the same path.
custom repo1 = /path/unprotected
custom repo2 = /path/protected
It appears that pulp no longer accepts that. We should confirm that the pulp behavior has changed and catch and prompt the user to use a different path if this is the case.
[root@ip-10-70-90-96 ~]# pulp-admin repo create --id unprotected1 --name unprotected1 --relativepath /path1/
Successfully created repository [ unprotected1 ]
[root@ip-10-70-90-96 ~]# pulp-admin repo create --id protected1 --name protected1 --relativepath /path1/
error: operation failed: PulpException: New relative path [path1] conflicts with existing relative path [path1]; paths may not be a parent or child directory of another relative path
A fix in rhui-manager will not be complicated, but confirming pulp's behavior is what we want/expect w/ slagle..
Yes, looks like there's an existing bug in Pulp with how we check the relative path for collisions on repo creation.
Seeing as this is not a regression at this point, I think this is something we can fix in a 2.1.1
From QA POW: is the path-prefix issue a supported case?
commit 4359bc8618e615fe20a284bad33151547d977a9f to github.com/splice/pulp
Created attachment 693384 [details]
Verified in pulp-0.0.263-27.el6_3.noarch (RHUI 2.1.1)
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, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.