dan benanav wrote:

> I have been reading this Threads question thread and I still don't completely
> understand why creation of threads would damage the container's "management" of
> threads and resources and why it is restricted.  I understand somewhat why it
> is usually a bad idea to spawn threads in method calls (see below) but maybe

Dan,

There has been a couple very good posts on this which provide an explanation.  Here
is a link that explains the reasons threads are prohibited
(http://www.jguru.com/jguru/faq/view.jsp?EID=15893) .

Sriram Srinivasan's argument that threads should be allowed has merit (anything he
says is worth listening to), but I believe that a restricted environment protects
developers from themselves. EJB is not meant to be a technology for only the
smartest and most tenacious developers (this is CORBA's domain). Its meant to be a
technology for the masses just as Microsoft's MTS is a technology for the masses.
That said, I believe that vendors should allow explicit thread management by the
bean, with the understanding that the code may not be portable to other EJB servers
-- I think most EJB servers will allow the deployer to manage permissions this way
already.

Richard
--
Author of Enterprise JavaBeans
Published by O'Reilly & Associates
http://www.EjbNow.com

EJB FAQ
http://www.jguru.com/faq/EJB

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to