Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within OCPJWCD
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Ron McLeod
Paul Clapham
Devaka Cooray
Liutauras Vilda
Sheriffs:
Jeanne Boyarsky
paul wheaton
Henry Wong
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Tim Moores
Carey Brown
Mikalai Zaikin
Bartenders:
Lou Hamers
Piet Souris
Frits Walraven
Forum:
Web Component Certification (OCEJWCD)
Thread Safe
Gowher Naik
Ranch Hand
Posts: 643
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Following are
thread
Safe
request attributes
response Object
local variables
Following are not thread Safe
servletcontext attributes
session attributes
instance variables
What about ServletConfig parameters?
Are they access by multiple threads at a single time?
i know ServletConfig parameters are
Read Only constants
.
Thanks
Ali Gohar
Ranch Hand
Posts: 572
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
ServletConfig Parameters are readonly then i think it doesn't matter
Elan Ram
Ranch Hand
Posts: 40
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hey, we can set only the attributes. Not parameters. There are no setter methods to set the same.
Hence, Thread safety is applied only to attributes and not a paramters.
Thanks and regards,
Elan
Manikandan Jayaraman
Ranch Hand
Posts: 230
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
More to note ...
As said, Parameters are thread-safe as there are no setters for the same.
Only in SingleThreadModel, instance variables are thread-safe.
Static Variables, Context Attributes and Session Attributes are never thread safe.
Regards,<br />Mani<br />SCJP 1.4 (95%)<br />SCWCD 1.4 (94%)
Whoever got anywhere by being normal? Just ask this exceptional tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
Thread safety
Which attribute scopes are thread-safe ?
Mock Question about thread-safe
threads and static varibles
request atributes are always thread-safe?
More...