[wp-hackers] Auto shutoff comments to be shut off?

Kimmo Suominen kim at tac.nyc.ny.us
Tue Mar 8 04:05:33 GMT 2005


Not that my site has a huge database or anything, but I've been using
that plugin for a "really long" time.  I've converted it to WP 1.5 on
or around December 8, 2004 (based on the timestamp of the file).

Haven't had any problems.  It "only" runs when something is written
to the db, not when it is read:

I guess if you are getting hundreds of trackbacks or pingbacks per
minute it could get pretty bad.

I did optimize it a bit, so that it only changes status for posts that
have comments open.  The old version always changed the status of all
old posts, even if they were closed already (or private)...

I think the best first action would be to ask if the problem cases were
using this plugin, as opposed to wiping the plugin out from existence.

Regards,
+ Kim
-- 
<A HREF="http://kimmo.suominen.com/">Kimmo Suominen</A>


On Mon, Mar 07, 2005 at 12:46:36PM -0500, Carthik Sharma wrote:
> I beleive the auto shutoff comments plugin is evil - no less.
> 
> To quote:
> It's pretty easy to put this into a plugin that runs every time the
> database is changed, so that we don't need a cronjob.
> 
> From: http://wiki.wordpress.org/Auto%20shutoff%20comments
> 
> It is nothing short of treachery to do the update each time there is a
> new post, or comment, or whatever else. The plugin says:
> add_action('publish_post', 'autoclose_comments', 7);
> add_action('edit_post', 'autoclose_comments', 7);
> add_action('delete_post', 'autoclose_comments', 7);
> add_action('comment_post', 'autoclose_comments', 7);
> add_action('trackback_post', 'autoclose_comments', 7);
> add_action('pingback_post', 'autoclose_comments', 7);
> add_action('edit_comment', 'autoclose_comments', 7);
> add_action('delete_comment', 'autoclose_comments', 7);
> add_action('template_save', 'autoclose_comments', 7
> 
> All this, to avoid having a simple cron job!
> 
> I am removing references to this plugin from the Codex Plugins page
> until someone comes up with a more responsible way of doing this.
> Could this be a culprit behind some recently reported mysql problems
> for some users?
> 
> Carthik.


More information about the wp-hackers mailing list