Wednesday, May 26, 2021

How tomcat server handles multiple request?

Ans:A HTTP request is sent by the browser over internet connection and when request comes to tomcat(servlet container) it allocates a thread from thread pool to serve based on URL mapping of servlet. Because tomcat has the URL mapping of all the servlet . thread from thread pool initialize object of servlet ,calls its service method, generate and send response .then thread goes back to the pool ,ready to serve another request from the client.



No comments:

Post a Comment

Fluent interface pattern

 public class UserConfigurationManager {     private String userName;     private String password;     private UserConfigurationManager() { ...