By default with James spring, ActiveMQ is activated, an mailqueuefactory is searched in the class path, see import and initialisation.
Initialisation
You have to declare a bean identified as mailqueuefactory with the type
org.apache.james.queue.activemq.ActiveMQMailQueueFactory with the following indexed-arguments: