Working sample taken from this article - http://java.dzone.com/articles/connect-rabbitmq-using-scala