Page MenuHomePhabricator

Separate repository updates from the pull daemon
ClosedPublic

Authored by epriestley on Apr 15 2014, 11:16 PM.
Tags
None
Referenced Files
F12842282: D8780.id20838.diff
Thu, Mar 28, 9:54 PM
Unknown Object (File)
Sun, Mar 10, 10:19 AM
Unknown Object (File)
Feb 8 2024, 6:26 PM
Unknown Object (File)
Feb 2 2024, 4:13 PM
Unknown Object (File)
Feb 2 2024, 4:04 PM
Unknown Object (File)
Jan 31 2024, 11:18 PM
Unknown Object (File)
Dec 23 2023, 5:09 PM
Unknown Object (File)
Dec 22 2023, 6:22 PM
Subscribers

Details

Summary

Ref T4605. Currently, the PullLocal daemon is responsible for two relatively distinct things:

  • scheduling repository updates; and
  • actually updating repositories.

Move the "actually updating" part into a new bin/repository update command, which basically runs the pull, discover, refs and mirror commands. This will let the parent process focus on scheduling in a more understandable way and update multiple repositories at once. It also makes it easier to debug and understand update behavior since the non-scheduling pipeline can be run separately.

Test Plan
  • Ran update --trace on SVN, Mercurial and Git repos.
  • Ran PullLocal daemon for a while without issues.

Diff Detail

Repository
rP Phabricator
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

epriestley retitled this revision from to Separate repository updates from the pull daemon.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: btrahan.
btrahan edited edge metadata.

Nice re-factor. If the answer to my inline question is "no" can we change the phlog to log to the daemon console?

src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
140

this ends up showing up in the daemon log?

This revision is now accepted and ready to land.Apr 16 2014, 6:10 PM
src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
140

Yeah, phlog() from daemons goes to the console (or, if it doesn't, that's a bug). I'll double-check.

Here's a screenshot of it hitting the daemon logs under real-world conditions:

Screen_Shot_2014-04-16_at_11.13.30_AM.png (344×1 px, 102 KB)

epriestley updated this revision to Diff 20857.

Closed by commit rP118c696f727a (authored by @epriestley).