added inQueue and outQueue processing