Task status not updated if php client loses connection with DB