You should download the JSP 1.0 specification available at http://java.sun.com/products/jsp/index.html
At this point, it is the authoritative guide to JSP and is very well written. The technology is too new so
I haven't found any great books on it. If there are some, I'd like to know.
 
The spec will answer your questions dealing with threads in greater detail. By default, the JSP files
are assumed to be thread safe and are compiled into multi-threaded servlets, but you can set
directivies using the JSP page directive to define a page as not being thread safe.
 
Your instance below shows an automatic variable which is thread safe in this case.
 
What also will help is to create a JSP page and then access it. It will create a Java source
file and then you can examine the source code.
 
-Shawn
-----Original Message-----
From: Mark Coté <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
Date: Tuesday, August 10, 1999 9:04 AM
Subject: JSP-Servlet Threading issues

I would like to find information on Threading issues regarding JSP.

    For instance:

    <%!
             Connection cn = null;
    %>

    Since this is compiled into a servlet, am I to assume the Servlet
doesn't implement the SingleThreadedModel ?
    Does this depend uniquely on the Server implementation of JSP ? How
does JavaWebServer2.0 deal with
    threads in this context ?

    Should this variable be synchronyzed when accessed ?

    Could you point me to some links where I may find some info on this ?

   Also, is there a complete reference guide to JSP. ie: book-online which may answer any question I may
    think of ?

thanks,

    Mark
 
 

Reply via email to