Answer Posted / shrikant kale
ApplicationContoller/RequestProcessor will create & use the
only instance of each Action class [hence: Singleton in
nature] .
Also the Action class has to handle the multiple request
(most of time simultaniously.) so it cant be Thread-Safe.
Hence we must not declare class instance variable in Action
class.If declared so then Action class state becomes non-
thread safe.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is action class? What are the types of action class?
What is the purpose of @element annotation annotation?
Which design pattern is implemented by Struts2 interceptors?
How the exceptions are handled in struts?
Why we use struts in java?
What is the difference between plain-validator and field-validator?
List some struts tag libraries?
What is struts.devmode?
What validate() and reset() method does ?
Give an example where struts tiles may be used?
What is role of actionservlet?
What’s the difference between validation.xml and validator-rules.xml files in struts validation framework?
What’s the difference between struts and turbine? What’s the difference between struts and espresso?
Which interceptor is responsible for i18n support?
What is actioncontext?