File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Servlet 3.0 specs doubt ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Servlet 3.0 specs doubt ?" Watch "Servlet 3.0 specs doubt ?" New topic

Servlet 3.0 specs doubt ?

gurpeet singh
Ranch Hand

Joined: Apr 04, 2012
Posts: 924

this is in context of Asynchronous processing.

the specs says that

Thread safety
Be aware that other than the
startAsync, and complete methods, the request and response objects are not
thread safe.

i'm not able to understand what it means ? what does other than startAsync and complete methods means ?
Paul Clapham

Joined: Oct 14, 2005
Posts: 19858

In English, "Other than X" means that "X" is excluded from whatever follows in the sentence.

So in this case it means that in all methods except for startAsync and complete, those objects are not thread-safe.
gurpeet singh
Ranch Hand

Joined: Apr 04, 2012
Posts: 924

thanks for the reply Paul. but my problem was not in the wording/english. my doubt was that "what does inside the methods(othe than startAsync, complete) the objects are not thread safe means ? can you tel me a scenario when the request/response objects are accessed by more than 1 thread concurrently ?
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Servlet 3.0 specs doubt ?
It's not a secret anymore!