I have a question that, i have a spring-mvc based project which is accessible by multiple user. My question is that when more than one user access that application then for each user there is separate controller class object or all user access the same controller class object.
Asked
Active
Viewed 2,414 times
2 Answers
1
There will be multiple controller instances for different requests.
Please read: http://docs.spring.io/spring-framework/docs/2.5.x/reference/mvc.html
Related answer: How does Spring MVC handle multiple users

Community
- 1
- 1

user1933888
- 2,897
- 3
- 27
- 36
1
If the controller is a bean (which is the usual case) then the default is one bean per Spring container context.
If you set the controller/bean to scope=prototype
then you would get a new instance from the factory each time.

Lee
- 738
- 3
- 13
-
Thanks for providing solution.It's Work. – Mihir Prakash May 16 '16 at 05:31