This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Servlets and the fly likes servlet config and servlet context Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "servlet config and servlet context" Watch "servlet config and servlet context" New topic

servlet config and servlet context

sitaram irrinki
Ranch Hand

Joined: Feb 16, 2005
Posts: 158
How many servletconfig&servletcontexts are formed when ever 10-clients accessing one servlet program
stan ioffe

Joined: Jun 30, 2005
Posts: 16
Every web application has exactly ONE instance of javax.servlet.ServletContext ... according to java's specification.

Each servlet has its own ServletConfig object. In other words, there is 1 ServletConfig object for each servlet. Think of ServletConfig as a wrapper around servlet's initialization parameters that are passed into the servlet for its instantiation.

subject: servlet config and servlet context