Background thread and timers.