I have a query regarding Spring 3 MVC @Controllers
. When a request comes in, does the container create a new instance of the controller for each request (Similar to an Action in Struts 2 - ThreadLocal ActionContext
) or a single instance responds to all requests? By default are the controller beans singletons in a context?
What are the guidelines/ best practices for a Spring 3 MVC application? Are these settings configurable? Should those be configured?
Does it change much if my environment is a clustered environment - I guess it should not as the jvm/containers would be different- but some authoritative suggestion would be welcome.
I have read Spring documentation but probably I missed it. Any 'this is how we implemented kind of' answers/ pointers/ links would be helpful
Thanks.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…