modify scheduling ans asynchronous execution code.