Spring @Controller lifecycle?

A controller (as any spring bean) has a scope.

A controller (as any spring bean) has a scope. At best your controllers should be of scope singleton. In that case it is very much like servlets, and: they are created only once, during the application context startup (and destroyed when the context is destroyed) you should not use any instance variables (as this is not thread-safe) If your controller scope is request or session, then you can have instance variables, and an instance of the controller is created on each new request/session.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions