File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Is Filter Mutli-threaded and Requiring Synchronization? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Customer Requirements for Developers this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Is Filter Mutli-threaded and Requiring Synchronization?" Watch "Is Filter Mutli-threaded and Requiring Synchronization?" New topic
Author

Is Filter Mutli-threaded and Requiring Synchronization?

Alec Lee
Ranch Hand

Joined: Jan 28, 2004
Posts: 569
According to Servlet 2.4 Spec6.2.1, only one instance per <filter> in DD is created. But if there are 2 concurrent requests made to 2 servlets sharing the same <filter> definition, would the filter executed in multiple threads (just like servlet)? I cannot find related information in the specification. Could anyone point me to the appropriate location for more information.

Thx
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
A crosspost.

Similar thread found: http://www.coderanch.com/t/361170/Servlets/java/Filter-Mutli-threaded
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Is Filter Mutli-threaded and Requiring Synchronization?
 
It's not a secret anymore!