Skip to:
Content
Pages
Categories
Search
Top
Bottom

Short of a cron job, need a recurring event to schedule db maintenance

  • Profile photo of Erwin Gerrits
    Erwin Gerrits
    Participant

    @egerrits

    I need to perform regular maintenance (once a day or so) on my database. I do not want users to set up a cron job to do this, so what would be a suitable wp or buddypress “event” (or hook) that would give me a reasonable frequence of occurring, without it occurring every time each user clicks on anything.

    I suppose it would be something happening when the admin logs into the back-end or something once a day type of thing.

    Any ideas?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Profile photo of Simon
    Simon
    Participant

    @conceptfusion

    Could you not just use a high traffic event and put some basic logic around it?

    Perhaps a check to see if a given timestamp has passed? You could create a simple db table and add the timestamp as a “flag” updating it when the criteria is met and the action completed, thus re-setting the task schedule for the next time-stamped period.

    Profile photo of Burt Adsit
    Burt Adsit
    Participant

    @burtadsit

    Profile photo of meenotuss
    meenotuss
    Participant

    @meenotuss

    I found a great plugin in the repsitory wp-dbmanager.2.50, seems to do everything you would want with your database

    Profile photo of Erwin Gerrits
    Erwin Gerrits
    Participant

    @egerrits

    wp-cron functions would do it! Thanks for your suggestions!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Short of a cron job, need a recurring event to schedule db maintenance’ is closed to new replies.
Skip to toolbar