Rewritten ActivityMonitor.