Working on internal queue implementation