Can you please explain me how the HTTP request will be served in servlet?
Asked
Active
Viewed 174 times
0
-
Related: http://stackoverflow.com/questions/3106452/java-servlet-instantiation-and-session-variables – BalusC Nov 02 '10 at 08:23
-
1Please be more specific. "How" could mean many things, ranging through request interpreation, threading, business logic, response formatting, socket level network access, security, session management and so on. – djna Nov 02 '10 at 09:00
1 Answers
1
Every request get a new Thread to a instance of servlet. The servlet service methods DOGET OR DOPOST which takes the request and reads the request headers as to what all things a browser accepts. On the basis of request. The servlet creates a responses and send it to the client browser on the same thread.
![](../../users/profiles/759866.webp)
BenMorel
- 30,280
- 40
- 163
- 285
![](../../users/profiles/337522.webp)
sushil bharwani
- 27,522
- 29
- 88
- 122