Write to queue