Bug 1276367

Summary: RFE: Add priority for each plugin hook
Product: [Fedora] Fedora EPEL Reporter: Ray Logel <rlogel>
Component: mockAssignee: Copr Team <copr-team>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: epel7CC: Frodox, jdisnard, mebrown, msuchy, praiskup, williams
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Feature: Add priority for each plugin hook Reason: Control order plugins are triggered Result: Allow the user to define order.
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-07-08 22:20:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Potential way to add priority ordering to plugin hooks none

Description Ray Logel 2015-10-29 14:32:39 UTC
Created attachment 1087563 [details]
Potential way to add priority ordering to plugin hooks

There isn't any way to control the order that plugins execute.  I created a plugin which was triggered using the 'postinit' hook.  I wanted it to be trigger before the root_cache plugin so that my changes can also be cached.  Unfortunately the plugin just stores an array of hooks with no way to control the order they are run.

Attached is a possible solution it could be further extended so that the priority was configurable via the config file.  But if all the existing hooks had a priority of 0, then a new hook could be added with -1 to make sure it went before them or +1 to make sure it when after.

Comment 1 Fedora Admin XMLRPC Client 2020-03-17 04:43:24 UTC
This package has changed maintainer in the Fedora.
Reassigning to the new maintainer of this component.

Comment 2 Troy Dawson 2024-07-08 22:20:10 UTC
EPEL 7 entered end-of-life (EOL) status on 2024-06-30.\n\nEPEL 7 is no longer maintained, which means that it\nwill not receive any further security or bug fix updates.\n As a result we are closing this bug.