Homec4science

Add PhutilFactsUpateIterator

Authored by epriestley <git@epriestley.com> on Jul 26 2012, 22:09.

Description

Add PhutilFactsUpateIterator

Summary: This iterator processes objects that have been updated.

Test Plan:
Ran this test script:

$cursor = null;
$table  = new DifferentialRevision();
while (true) {
  $iterator = new PhabricatorFactsUpdateIterator($table, $cursor);
  foreach ($iterator as $new_cursor => $update) {
    echo "{$new_cursor} => D".$update->getID()."\n";
    $cursor = $new_cursor;
  }
  echo "Zzz...\n";
  sleep(5);
}

Verified it iterated over every object and then stopped. Made a comment on a differenial revision, verified it iterated over the object after 15 seconds.

Reviewers: vrana, btrahan

Reviewed By: vrana

CC: aran

Maniphest Tasks: T1562

Differential Revision: https://secure.phabricator.com/D3077

Details

Committed
epriestley <git@epriestley.com>Jul 26 2012, 22:09
Pushed
aubortJan 31 2017, 17:16
Parents
rPHff61dba7acf4: Extend LiskMigrationIterator from PhutilBufferedIterator
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHc614af53bfe9: Add PhutilFactsUpateIterator (authored by epriestley <git@epriestley.com>).Jul 26 2012, 22:09