Are Servlets by default thread safe or not?
thanks in advance
regards
Sudhakar
Answers were Sorted based on User's Feedback
No.
By default Servlets are not thread safe...Bcoz Servlet is
concept of Single instance multiple threads concept.
Multiple thread are acting on single object means its not
thread safe....
| Is This Answer Correct ? | 7 Yes | 3 No |
Answer / nilofar
no by default servlets are not threads safe .oly particular
lines of service method can be synchronised to make it
thread safe
| Is This Answer Correct ? | 3 Yes | 3 No |
Answer / naresh
Yes By Default Servlets Are ThreadSafe.....
If you use Insatance VAriables then only Servlets is having Thread Related Problems
Thats way dont recommended to use Instance VAriables in servlets...Its DAnagerous
| Is This Answer Correct ? | 1 Yes | 1 No |
What is the use of Servlets?
What is the process for chaining servlet?
How to generate the server side programming and the advantages of it over the other languages?
What are the annotations used in servlet 3?
How to get the current httpsession object?
Write the code to get the server information in servlet.
What is servlet instance?
Define the servlet mapping.
What is difference between get and post method?
What is generic servlet class?
What are the differences between forward() method and sendredirect() methods?
i have 500 jsp in my application ,with same forward name,it lokks for appropritae jsp from 1 to 500,but i want to send response to 498 page,what should i do