@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at recaptime-dev/main 29 lines 647 B view raw
1<?php 2 3final class PhabricatorDaemonLogGarbageCollector 4 extends PhabricatorGarbageCollector { 5 6 const COLLECTORCONST = 'daemon.logs'; 7 8 public function getCollectorName() { 9 return pht('Daemon Logs'); 10 } 11 12 public function getDefaultRetentionPolicy() { 13 return phutil_units('7 days in seconds'); 14 } 15 16 protected function collectGarbage() { 17 $table = new PhabricatorDaemonLog(); 18 $conn_w = $table->establishConnection('w'); 19 20 queryfx( 21 $conn_w, 22 'DELETE FROM %T WHERE dateModified < %d LIMIT 100', 23 $table->getTableName(), 24 $this->getGarbageEpoch()); 25 26 return ($conn_w->getAffectedRows() == 100); 27 } 28 29}