• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

The Single threadModel Interface.

 
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HOW the below highlighted implemented: :
1. During the lifetime of a servlet that does not implement Single threadModel interface,the container may send multiple service requests in different threads to a single instance
2. Single threadModel follow instance pooling approach to ensure each servlet instance is invoked in a separarte thread. in this approach the container maintains a pool of servlet instance
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
These things are implemented by the builders of servlet containers (Tomcat, Websphere, etc..) not application developers. How they're implemented is really up to the the container builders and can vary from container to container. Luckily, if this is really of interest to you, there are several popular, open source, containers available for you to study.
Tomcat, Resin, and Jetty are the first three that come to mind.

Keep in mind that the SingleThreadModel interface is deprecated so, with the exception of needing to understand it in order to work with legacy code, there isn't much point in studying it.
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic