This ensures that the maintenance on/off happens before all tasks and after all tasks and not intermittently.