This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Hello Struts People, Any specific pointers on how to make access to the HTTPSession, specifically properties in the session, thread-safe? Should synchronization be used whenever accessing session properties? Is it enough to limit access to session variables just from within the Action Servlet's perform method? -j
"I believe in coyotes and time as an abstract Explain the change the difference between What you want and what you need there's the key"
Thanks Srikanth for your reply. I've heard good things about your Struts book. I guess I'm refering to the Struts API docs for the Action class: Action Where it states, "Access to other resources (JavaBeans, session variables, etc.) MUST be synchronized if those resources require protection. (Generally, however, resource classes should be designed to provide their own protection where necessary." Does this just refer to resources used by more than one session, Singletons, etc?
Joined: Jan 24, 2004
Hi Jason, I had never looked at it before. But it definitely sounds vague. I am not exactly sure what they were trying to convey. I would take a guess: They are probably referring to shared resources, and, as you said, singleton loosely belongs to shared resource category.