If your configuration is correct, all you have to do is return a new AsyncResult object with a receipt as an input parameter.
@Asynchronous public Future<Receipt> execute(Job job) { Receipt receipt = timeConsumingWork(job); return new AsyncResult<Receipt>(receipt); }
Spring processes both @Async and @Asynchronous using the <task:annotation-driven /> element.
Espen source share