Answer? Because there is no way to propagate transaction and security contexts to the spawned threads unless J2EE provided a thread creation API.
Bill > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]On Behalf Of LaBanca, > Rick > Sent: Monday, December 09, 2002 10:39 AM > To: '[EMAIL PROTECTED]' > Subject: [JBoss-user] J2ee spec thoughts > > > > While not particular to j2ee, I want to repeat something I've sent to sun > about the spec. Since this is a bleeding edge list, it's the best place to > get my opinion slammed down! > > Regarding ejb's. There are two missing elements I don't understand. > > First, the restriction of threading. It would be very useful to > use threads > in one atomic call to a session bean. For example, a bean that grabs data > from three web sites. I certainly would rather do three parallel requests > instead of sequential. When done, the threads would be gone and my method > would return. > > So why not allow threading within one call, so long as the threads are > terminated before return? Perhaps give a call to start threads from the > container to keep management simple. > > Second, the lack of a "service", "application", "resource" bean > or whatever > you like to call it. It seems the thinking is the container makes mbean > services, and that's good enough. > > But I certainly have apps that have subsystems and caches that act as > application lived servers, usually in normal code implemented as > singletons. > > > Per the spec right now, there is no way for an application to safely do > this. I do it right now by having my session beans access a singleton, but > it's luck that lets me get away with that. > > One could argue I could make a separate rmi server, mbean or whatever, but > it makes no sense to me not to have the capability of an application > scoped/lived bean. > > Rick > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user