Michael Andres wrote:
On Thu, Sep 11, Jan Kupec wrote:
Hi Hackers,
the support for *path* in repositories (the piece appended to baseurl) is still not perfect in libzypp. I am about to fix it, but first i've got a few questions.
- DO WE NEED THIS AT ALL? :O)
AFAICT, we needed this for multi-product media (like patch-CDs probably). I'm not sure why, though, can't we just go about it with two different URLs? If some 'conent' file references the other repo with a relative path, it should be no problem for libzypp to just use the baseurl+this_path, no need to treat them separately(?).
To handle a media set we need to to know 2 urls.
1) the media root
- This is the location of media.<n>/media. We need it to check e.g whether the correct media is inserted.
There are also other files like the gpg-keys, releasenotes,.. kept in the media root directory and not per repository.
- In case you copy a media set to your disk (to offer it via http, nfs,...)
/somewhere/DVD1 /DVD2 ... /DVD<N>
this is the place where you have to change DVD1 to DVD2 when changing from media 1 to 2.
2) the repositories root on the media
This is the path to acces the repository on the media. If the media has just one repo at /, you don't need the path.
Libzypp could live without 'path'. We could simply guess the media root when changing or verifying media. For CD/DVD it's obvious. And for disc copies we could probe for a ending in digits, or for a media.<n> directory.
But you also have to adapt YaST (and maybe other tools), which currently expect the url pointing to the media root. They download e.g
repo.url()/control.xml
OK, so this is what escaped my attention, some metadata only in the media root, and multiple-media repos (mutliple CDs/DVDs). Thanx!
Or we have to change the media layout an keep certain files per repo and not per media. This might even be reasonable, but...
We would still have problem with changing media http://foo/DVD1/ http://foo/DVD2/ http://foo/DVD1/repo2 http://foo/DVD2/repo2 currently we expect the media number at the end of the URL. We use this regexp: "^(.*)(cd|dvd)[0-9]+(/)?$". But you're right, this is not hard to solve.
It's not a zypp local change. If we want to go for this, we have to convince some people. But it could be worth trying to do this.
I agree. At this point i can't asses whether keeping and fixing the path in libzypp is more tricky than getting rid of it, i would need info from affected people. But i guess some people will say it is too late for 11.1. But another thing is, we never dealt with this kind of media layout since libzypp's refactoring after 10.2. So we really need to do something about it one way or the other. A side question: would we add such multi-product repository as two zypp repos? -- cheers, jano -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org