improve queue interface