tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Curwen" <mi...@gb-im.com>
Subject RE: Threaded servlets okay in a compliant container?
Date Tue, 30 Dec 2003 23:55:11 GMT
Just found this while searching for something else...
 
http://www-1.ibm.com/support/docview.wss?rs=180&context=SSEQTP&q=J2CA007
5W&uid=swg21109248&loc=en_US&cs=utf-8&lang=en+en
 
It doesn't look related at first, but keep reading the 'Cause' section.
 
Does anyone know what's the 'real' story regarding threads in servlet
containers.  It seems that what IBM is saying is that "they are
supported within a transactional context", but I can't find this in the
newest spec. Did I miss it? (or is it in a broader J2EE spec somewhere?)


> -----Original Message-----
> From: David Ramsey [mailto:david_l_ramsey@yahoo.com] 
> Sent: Tuesday, December 30, 2003 1:10 PM
> To: Tomcat Users List
> Subject: Re: Threaded servlets okay in a compliant container?
> 
> 
> SRV.9.11 says the same thing in the 2.4 spec so it's still 
> not defined as of Tomcat 5 either.
> 
> 
> --- Tim Funk <funkman@joedog.org> wrote:
> > Also ... (From 2.3 spec)
> > 
> > In SRV.1.2 What is a Servlet Container?
> > ... "For example, high-end application servers may limit 
> the creation 
> > of a Thread object, to insure that other components of the 
> container 
> > are not
> > negatively impacted."
> > 
> > SRV.9.11 Web Application Environment
> > ... "Such servlet containers should support this behavior when 
> > performed on threads created by the developer, but are not 
> currently 
> > required to do so.
> > Such a requirement will be added in the next version of this
> > specification. 
> > Developers are cautioned that depending on this capability for 
> > application-created threads is nonportable."
> > 
> > -Tim
> > 
> > Shapira, Yoav wrote:
> > 
> > > Howdy,
> > > One thing to note is that a servlet container and a J2EE 
> server are
> > not
> > > the same.  Tomcat is the former but not the latter.  Weblogic, 
> > > websphere, jboss, etc. are the latter.  They implement the whole
> > J2EE
> > > spec which places more restrictions on thread creation by
> > applications:
> > > read the spec if you want the actual text (I don't remember if 
> > > off-hand).
> > > 
> > > In a servlet containr, you can create your own threads.  Just like
> > in
> > > other environments, you must be careful with how you manage them, 
> > > especially making sure they are appropriately terminated by your 
> > > application or by the JVM itself if they're daemons.
> > > 
> > > Yoav Shapira
> > > Millennium ChemInformatics
> > > 
> > > 
> > > 
> > >>-----Original Message-----
> > >>From: David Wall [mailto:d.wall@computer.org]
> > >>Sent: Tuesday, December 30, 2003 12:15 PM
> > >>To: tomcat-user@jakarta.apache.org
> > >>Subject: Threaded servlets okay in a compliant container?
> > >>
> > >>I recall reading that conformant servlets and such (EJBs?) do not
> > > 
> > > create
> > > 
> > >>their own threads, something about being a container issue.
> > >>
> > >>Does anybody know the primary objection to launching threads that
> > take
> > >>on a life of their own?  The container doesn't really need to
> > manage
> > > 
> > > it,
> > > 
> > >>per
> > >>se.
> > >>I suppose a container can drop servlet objects from memory, but as
> > that
> > >>wouldn't necessarily affect a daemon thread, it seems that doesn't
> > harm
> > >>launching them at startup, and of course the servlet could even
> > stop
> > > 
> > > the
> > > 
> > >>threads when told to destroy itself if that makes sense.
> > >>
> > >>Does anybody know if most servlet containers today (Tomcat 4+,
> > > 
> > > WebLogic,
> > > 
> > >>WebSphere...) have a real problem with such new threads being
> > created
> > > 
> > > or
> > > 
> > >>not?  What would be the risk in my using them?
> > >>
> > >>I previously posted this by accident on the PostgreSQL JDBC list
> > and I
> > > 
> > > got
> > > 
> > >>mixed answers.  Some say it's fine, others say there's no spec
> > saying
> > > 
> > > such
> > > 
> > >>threads can't be used, and others say that BEA complained about
> > support
> > >>issues related to apps that created their own threads.
> > >>
> > >>Any feedback is much appreciated.
> > >>
> > >>Thanks,
> > >>David
> > >>
> > >>
> >
> >>------------------------------------------------------------
> ---------
> > >>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > >>For additional commands, e-mail:
> > tomcat-user-help@jakarta.apache.org
> > > 
> > > 
> > > 
> > > 
> > > 
> > > This e-mail, including any attachments, is a confidential business
> > communication, and may contain information that is confidential, 
> > proprietary and/or privileged.  This e-mail is intended only for the
> > individual(s) to whom it is addressed, and may not be 
> saved, copied, 
> > printed, disclosed or used by anyone else.  If you are not the(an) 
> > intended recipient, please immediately delete this e-mail from your 
> > computer system and notify the sender.  Thank you.
> > > 
> > > 
> > >
> > 
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail:
> > tomcat-user-help@jakarta.apache.org
> > > 
> > > 
> > > 
> > 
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> > 
> 
> 
> __________________________________
> Do you Yahoo!?
> Find out what made the Top Yahoo! Searches of 2003 
http://search.yahoo.com/top2003

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message