better queue handling