when the several requests comes to server..how it manage
the requests

Answer Posted / goutham

When several requests comes to the server,I am assuming here
the requests coming to the same servlet,then the
webcontainer sees whether the Servlet is instantiated if it
is not the servlet is instantiated (only for the first time)
then a thread is spawned for each request and assigned to it.

*servlets does not implement singlethreadmodel , this
interface is depricated and hits the performance very
badly..instead of singlethreadmodel you can use sychronized
blocks(not methods)

Is This Answer Correct ?    15 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When Servlet is unloaded?

628


What is Request Dispatcher?

805


Explain the role of dispatcherservlet and contextloaderlistener.

605


What are the two important api's in for servlets?

588


Why session tracking is needed?

584






What is cgi and what are its drawbacks?

553


how to link html file to sevlet file.one name is textbox,c&c++ is cheakbox,bc&mca is radio button and one submit buttonis ok why in this programme use in servelt file

2083


What are the servlet events?

592


What is the dispatcher servlet?

512


How we can get ip address of client in servlet?

537


Can a jsp be called using a servlet?

580


How do cookies work in servlets?

580


What's the servlet interface?

596


What is httpservlet class?

540


What is http servlet in java?

560