aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Servlets/jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Servlets/jsp" Watch "Servlets/jsp" New topic
Author

Servlets/jsp

Shini Akshi
Greenhorn

Joined: Oct 21, 2007
Posts: 11
In the mock exam Chapter 6 of HFJS , I found the following statement is true, but I marked it as false.
Statement is : " Attributes bound into a session are available to any other servlet that belongs to the same Servlet Context"

What I feel is : Attributes bound to a session must be available only to that session . I they are available to the ServeletContext means to many sessions isn't it? Please somebody clarify this to me. Please send a code sample to get this clarified
Ken King
Greenhorn

Joined: Sep 17, 2007
Posts: 13
If this is Question #7, you left out half of the statement...the whole statement reads:

"Attributes bound into a session are available to any other servlet that belongs to the same ServletContext and handles a request identified as being part of the same session.

This statement is word for word out of the Servlet 2.4 specification document (page 59).

To rephrase it, any attributes that are bound into a session are available to all servlets that (a) are a part of the same ServletContext AND (b) handle requests that are a part of the same session.

Hope this clarifies.
Shini Akshi
Greenhorn

Joined: Oct 21, 2007
Posts: 11
Thanks so much this is clarified
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Servlets/jsp