Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F99060133
PhabricatorDaemonLockLogGarbageCollector.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, Jan 18, 19:34
Size
618 B
Mime Type
text/x-php
Expires
Mon, Jan 20, 19:34 (2 d)
Engine
blob
Format
Raw Data
Handle
23691252
Attached To
rPH Phabricator
PhabricatorDaemonLockLogGarbageCollector.php
View Options
<?php
final
class
PhabricatorDaemonLockLogGarbageCollector
extends
PhabricatorGarbageCollector
{
const
COLLECTORCONST
=
'daemon.lock-log'
;
public
function
getCollectorName
()
{
return
pht
(
'Lock Logs'
);
}
public
function
getDefaultRetentionPolicy
()
{
return
0
;
}
protected
function
collectGarbage
()
{
$table
=
new
PhabricatorDaemonLockLog
();
$conn
=
$table
->
establishConnection
(
'w'
);
queryfx
(
$conn
,
'DELETE FROM %T WHERE dateCreated < %d LIMIT 100'
,
$table
->
getTableName
(),
$this
->
getGarbageEpoch
());
return
(
$conn
->
getAffectedRows
()
==
100
);
}
}
Event Timeline
Log In to Comment