Big refactor to use Thor and hide AMQP implementation