In an internal platform discussion, there is a question of whether all
filters need to be run in the same thread as in servlets.
In Section 6.2 of Servlet 3.0, there is a description on how filters work.
There is "no" explicit requirement that the filters need to be run in
the same thread.
Is it a tacit assumption?
We propose that the spec ought to say either:
- The service method is required to run in the same thread as all filters
that apply to the servlet.
or
- The service method is *not* required to run in the same thread as filters
that apply to the servlet, and filters should not depend on sharing
thread local data with the servlet.
Shing Wai Chan