Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Is Struts Action class Thread Safe?

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


Please Help Members By Posting Answers For Below Questions

What are the benefits of Interceptors in Struts2?

1173


What is the default suffix for struts2 action uri ?

968


What does action do in struts?

996


When do I need “struts.jar” on my classpath?

971


How can duplicate form submission be handled in struts 2?

985


in struts how to use hibernate with struts>

2222


What are the components of struts framework?

1020


What is used to display the intermediate result in an interceptor?

954


Are struts still used?

931


How can you create your custom interceptor in struts 2?

943


What are result types in struts?

991


What is the difference between session scope and request scope when saving formbean ?

990


When should be opt for struts framework?

1046


Explain how can we upload files in struts2 application?

1058


How you will make available any message resources definitions file to the struts framework environment?

978