[dev] [Nic] Added feature: purge old records

Jan Schneider jan at horde.org
Fri Oct 29 09:13:33 PDT 2004


Zitat von Roel Gloudemans <roel at gloudemans.info>:

>> and the purging should be integrated into statusMonitor.php. Not
>> that it should be run each time the status gets updated, but with some
>> clever interval depending on the purge days.
> I'm wondering. If you run it each time with statusMonitor, it will delete one
> monitoring cycle and add another, this then will be a kind of round robin
> database. I don't know how e.g. mysql is handling this exactly, but it
> is using
> freed space from earlier deletes. Also, if the information per cycle 
> differs a
> lot; fragmentation could take place.
>
> Options to do it otherwise:
> 2) if the oldest record is more than a day older than set set treshold
> run purge
> 3) Create an entry in the datatree; or a file in vfs to record the last
> time run
>
> I'm leaning towards 2 since it requires no extra storage elements

Ah, I didn't have in mind that the script doesn't know how often it runs.
Yeah, 2 sounds good in this case.

Jan.

-- 
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/


More information about the dev mailing list