It could be, I don't know. But if so, why is it only the case for this kind of pool? (is this a deliberate feature, or is it a bug?) And does this mean that a bean pool of stateless sessions beans with an async biz method is limited to 3 beans in use at a time...?
Best, Stuart p.s. Howard, not a major point, but the Java EE 6 Tutorial has an example of a stateless session bean with aync methods which runs on Glassfish: http://docs.oracle.com/javaee/6/tutorial/doc/gkiez.html On Tue, Jan 7, 2014 at 4:52 PM, Howard W. Smith, Jr. <[email protected] > wrote: > On Tue, Jan 7, 2014 at 3:59 PM, Stuart Easterling < > [email protected]> wrote: > > > As far as asynchronous biz methods on a stateless bean, at minimum I > don't > > think the Java EE spec excludes this (it is in fact a useful feature), > and > > my guess is other Java EE containers support it. > > > > Are you able to test your code on other containers and report your > findings/test-results? > On Tue, Jan 7, 2014 at 5:18 PM, Romain Manni-Bucau <[email protected]>wrote: > Dont you think it means the async thread pool has a size of 3? (i ask > but...) > Le 7 janv. 2014 21:34, "Howard W. Smith, Jr." <[email protected]> a > écrit : > > > Stuart, > > > > On Tue, Jan 7, 2014 at 3:03 PM, Stuart Easterling < > > [email protected]> wrote: > > > > > Romain, if you add the annotation @Asynchronous to your foo() business > > > method in TestBean it reproduces the behavior I have been having. > > > > > > > I'm definitely not one of the committers (or expert users), but your > > questions/threads, today, remind me of some related topics discussed on > > this tomee user list. > > > > Recent (possibly related) topics are: > > > > @Asynchronous And TransactionRequiredException > > > > and > > > > initial size of pool of stateless beans > > > > You can search google + tomee user list for those topic titles, above, > and > > read them. In one of those topics, I think I stated that I would never > add > > @Asynchronous to @Stateless bean. As a java EE newbie that learned java > EE > > via Java EE 6 tutorial and NetBeans, I never seen the two married > together > > in tutorial or in any working examples, but I've seen others on this list > > marry the two together. > > > > In my understanding/experience of @Asynchronous... use the same > (@Stateless > > test) bean, but execute the @Asynchronous 'method'...later, and hope it > > executes. I think I've even heard David Blevins (TomEE lead/committer) > > state that @Asynchronous is not always/fully reliable. I think Romain > will > > disagree with that though. :) > > > > I use @Asynchronous only with @SessionScoped beans...as > > documented/demonstrated/suggested in Java EE 6 tutorial. I think TomEE > > allows @Asynchronous + @Stateless, because of the DeltaSpike/OpenEJB > > features in TomEE. :) > > >
