about SingleThreadModel

3 views
Skip to first unread message

Anil Tiwari

unread,
Jan 20, 2012, 3:42:11 AM1/20/12
to aksforjava
If any servlet implements this interface then what will be behaviour
of that servlet?

abhishek gupta

unread,
Jan 20, 2012, 4:45:37 AM1/20/12
to aksfo...@googlegroups.com
if the servlet implements this interface, the servlet will be thread safe. Note that this is not an ideal solution, since performance may suffer (depending on the size of the instance pool), plus it's more difficult to share data across instances than within a single instance.
Here This empty interface tells the web server to only send one client request at a time into your servlet. If the target servlet is flagged with this interface, the servlet programmer is guaranteed that no two threads will execute concurrently the service method of that servlet.
Reply all
Reply to author
Forward
0 new messages