[Yum-devel] Idea: plugins

seth vidal skvidal at phy.duke.edu
Mon Mar 7 02:22:46 UTC 2005


On Mon, 2005-03-07 at 10:35 +1000, Menno Smits wrote:
initial thought:

we'd have to maintain extremely rigid api compatibility to do this. And,
of course, we'd end up debugging everyone's crazy plugin-of-doom.


> This morning I was thinking about the whole protectbase thing and it 
> occurred to me that this could be handled better if yum supported the 
> concept of plugins for the depsolver (and possibly other stuff too).

where would you plug these items in? Where would you define them? It
seems like no matter how many we define users would want N more
definitions. I guess my primary concern is in making the code
unmaintainable and making test cases incredibly difficult.


> This would allow crazy stuff like protectbase to happen without having 
> to be maintained inside yum. If someone wanted the protectbase feature 
> they could install the yum-plugin-protectbase pkg.

I guess that's part of my concern, it's always been a rule that we try
to keep the crazy stuff out of yum. The crazy stuff is where the code
becomes more horrible not to mention a maintenance nightmare.

> A plugin would just be a Python module with a predefined interface 
> sitting in a yum plugins directory. It could register configuration file 
> extensions (eg. the "protect" option) and various hooks that it's 
> interested in within yum.

I could see this for more superficial mechanism like displaying
information but give me an example of how this would be useful in the
depsolver, for example?

Where besides package exclusions or depsolving do you think this would
be used?


> Is this a stupid idea? What does everyone think?

I'm really worried about the long run, maintaining this could become
extremely tricky.

-sv








More information about the Yum-devel mailing list