Author: dblevins
Date: Tue Jul 2 01:34:00 2013
New Revision: 1498752
URL: http://svn.apache.org/r1498752
Log:
forgot to yank import
Modified:
tomee/tomee/trunk/examples/async-postconstruct/README.md
Modified: tomee/tomee/trunk/examples/async-postconstruct/README.md
URL:
http://svn.apache.org/viewvc/tomee/tomee/trunk/examples/async-postconstruct/README.md?rev=1498752&r1=1498751&r2=1498752&view=diff
==============================================================================
--- tomee/tomee/trunk/examples/async-postconstruct/README.md (original)
+++ tomee/tomee/trunk/examples/async-postconstruct/README.md Tue Jul 2
01:34:00 2013
@@ -1,6 +1,13 @@
Title: @Asynchronous @PostConstruct
-Placing `@Asynchronous` on the `@PostConstruct` of an EJB is not a supported
part of Java EE, but this example shows a patter which works just as well with
little effort.
+Placing `@Asynchronous` on the `@PostConstruct` of an EJB is not a supported
part of Java EE, but this example shows a pattern which works just as well with
little effort.
+
+The heart of this pattern is to:
+
+ - pass the construction "logic" to an `@Asynchronous` method via a
`java.util.concurrent.Callable`
+ - ensure the bean does not process invocations till construction is complete
via an `@AroundInvoke` method on the bean and the `java.util.concurrent.Future`
+
+Simple and effective. The result is a faster starting application that is
still thread-safe.
package org.superbiz.asyncpost;