Page MenuHomePhabricator

Clean up overseer modules slightly and provide a throttling support method
ClosedPublic

Authored by epriestley on Mar 23 2017, 1:57 AM.
Tags
None
Referenced Files
F19052216: D17539.id42197.diff
Fri, Nov 28, 3:59 AM
F19039279: D17539.id42197.diff
Wed, Nov 26, 7:08 AM
F18980889: D17539.diff
Mon, Nov 17, 1:31 AM
F18830607: D17539.id.diff
Oct 25 2025, 7:38 AM
F18829691: D17539.diff
Oct 24 2025, 11:55 PM
F18810953: D17539.diff
Oct 20 2025, 12:15 AM
F18575016: D17539.id42185.diff
Sep 10 2025, 12:09 PM
F18437691: D17539.id42185.diff
Aug 31 2025, 12:24 PM
Subscribers
None

Details

Summary

Ref T12298. Make it slightly easier to write overseer modules:

  • You don't need to implement shouldReloadDaemons(), since you can now just implement shouldWakePool() and get useful behavior.
  • It looks like most modules want to do checks only every X seconds, where X is at least somewhat module/use-case dependent, so add a helper for that.
Test Plan

Ran bin/phd debug pull --trace, saw config check fire properly every 10 seconds after updating it to use shouldThrottle() in the next change.

Diff Detail

Repository
rPHU libphutil
Lint
Lint Not Applicable
Unit
Tests Not Applicable