[Yum-devel] [PATCH] repo.async=False for RHN repositories

tim.lauridsen at gmail.com tim.lauridsen at gmail.com
Mon Apr 16 08:14:30 UTC 2012


2012/4/13 Zdeněk Pavlas <zpavlas at redhat.com>

> rhnplugin.py subclasses YumRepository in a way that's
> incompatible with parallel downloader, so turn it off.
>
> This should make multi-downloader work out-of box
> on systems with unpatched rhnplugin.
> ---
>  yum/yumRepo.py |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/yum/yumRepo.py b/yum/yumRepo.py
> index fdeb84d..4d64275 100644
> --- a/yum/yumRepo.py
> +++ b/yum/yumRepo.py
> @@ -252,6 +252,10 @@ class YumRepository(Repository, config.RepoConf):
>
>     def __init__(self, repoid):
>         config.RepoConf.__init__(self)
> +        if self.async and self.__class__.__name__ == 'RhnRepo':
> +            # should be done in rhnplugin.py, but..
> +            logger.warning(_('Disabling parallel downloading for repo
> %s'), repr(repoid))
> +            self.async = False
>         Repository.__init__(self, repoid)
>
>         self.repofile = None
> --
> 1.7.4.4
>
>
Is this really the baste way to solve that, It should be solved in the
rhnplugin, not in base :)
it is kind of a very dirty hack IMO.

Tim
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.baseurl.org/pipermail/yum-devel/attachments/20120416/d7b196d8/attachment.html>


More information about the Yum-devel mailing list