Bug 4517 - Rule instrumentation plugins
Summary: Rule instrumentation plugins
Status: RESOLVED FIXED
Alias: None
Product: Spamassassin
Classification: Unclassified
Component: Plugins (show other bugs)
Version: SVN Trunk (Latest Devel Version)
Hardware: Other other
: P3 enhancement
Target Milestone: 3.2.0
Assignee: SpamAssassin Developer Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-04 17:55 UTC by John Gardiner Myers
Modified: 2005-11-07 16:53 UTC (History)
0 users



Attachment Type Modified Status Actions Submitter/CLA Status
Proposed enhancement patch None John Gardiner Myers [HasCLA]
Sample timing plugin text/plain None John Gardiner Myers [HasCLA]

Note You need to log in before you can comment on or make changes to this bug.
Description John Gardiner Myers 2005-08-04 17:55:26 UTC
Allow plugins to instrument the rule testing process.  This is primarily in
order to get various types of timing information.
Comment 1 John Gardiner Myers 2005-08-04 17:55:57 UTC
Created attachment 3054 [details]
Proposed enhancement
Comment 2 John Gardiner Myers 2005-08-04 17:59:40 UTC
Created attachment 3055 [details]
Sample timing plugin
Comment 3 Daniel Quinlan 2005-08-14 14:04:52 UTC
Do the additions have any effect on overall performance?
Comment 4 John Gardiner Myers 2005-08-14 14:15:33 UTC
Since in the case where no loaded plugin uses the new callbacks the additions do
nothing but rename ran_rule_debug_code() to hit_rule_debug_code() and add a few
calls to the newly created have_callback() during rule compilation, I can't see
how there could posibly be any effect on overall performance.
Comment 5 John Gardiner Myers 2005-08-14 14:16:54 UTC
Correction, that's hit_rule_plugin_code(), not hit_rule_debug_code().
Comment 6 Justin Mason 2005-08-14 14:22:02 UTC
interesting!  ok.

I'd still like to see a benchmark mass-check with and without these hooks in
place ;)
Comment 7 Justin Mason 2005-10-04 19:05:58 UTC
applied patch 3054.  I took a good look and I see that it can't affect speed
unless a timing plugin is loaded (due to the conditional compilation).

I'm not sure what to do with the sample plugin -- wiki?  Mail::SA::Plugin
directory in svn?  I think I'd lean towards the latter.

John, still waiting for that ASF committer account.  however I saw it move into
the "really to do soon" queue today btw ;)

Sending        lib/Mail/SpamAssassin/PerMsgStatus.pm
Sending        lib/Mail/SpamAssassin/Plugin.pm
Sending        lib/Mail/SpamAssassin/PluginHandler.pm
Sending        lib/Mail/SpamAssassin.pm
Transmitting file data ....
Committed revision 294971.
Comment 8 John Gardiner Myers 2005-11-07 21:00:15 UTC
Also instrumented eval rules.

Committed revision 331591.
Comment 9 Justin Mason 2005-11-08 01:53:05 UTC
worth noting that this is being used at the new rule-QA system at
http://buildbot.spamassassin.org/ruleqa/