module

FeedRefresher

Constants

CHECK_EVERY = 1.hour
HTTP_TIMEOUT = 15.seconds
MAX_TTL = 1440
MIN_TTL = 15
STAGGER_DELAY = 2.seconds

Class methods

refresh_for_user(user_id : Int64)

Refresh feeds belonging to a specific user that are past their TTL. Spawns a fiber and returns immediately — safe to call from a request handler.

Source
start

Start the background periodic loop. Call once at boot.

Source