added logging and updates to properly update queue