Safe Haskell | None |
---|---|
Language | Haskell2010 |
This package is intended for use cases when cron
is overkill,
but the importance of avoiding drift is still there. No care is
taken w.r.t. GC times.
Documentation
embla :: Int -> IO a -> IO a Source #
Given an IO
action and an interval at which to perform it,
perform the IO
action repeatedly at every interval. This function
is useful when you have an IO
action that can take a significant/variable
amount of time, and you want to avoid drift.
Note: This function will not work as expected if the given IO
action
takes longer than the polling interval.
Note: No care is taken w.r.t. GC times.