Implemented the first version of background tasks