Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / December 2005

Tip: Looking for answers? Try searching our database.

Are custom tags thread-safe?

Thread view: 
Big Slim - 09 Dec 2005 16:42 GMT
Are instance variables in custom tags thread-safe? I need two different
JSPs to use the same custom tag, so I have a setter method for an
instance variable called "page." The tag does things a bit differently
depending on which page called it.

A Java programmer I know told me I don't have to worry about it as long
as I let the tag "fall out of scope." If I'm not mistaken, though, one
instance of the tag will be created for all threads to share, just like
a servlet, right?

Any clarity on this subject would be greatly appreciated. Thanks--Big
Slim
Big Slim - 10 Dec 2005 05:04 GMT
> Are instance variables in custom tags thread-safe? I need two different
> JSPs to use the same custom tag, so I have a setter method for an
[quoted text clipped - 8 lines]
> Any clarity on this subject would be greatly appreciated. Thanks--Big
> Slim

Whoops! Didn't mean to post the same question again. I thought my
original post hadn't gone through.

Thank you both for your responses. I'm awfully glad custom tags are
thread-safe. I was sweating bullets there for a while!

--Big Slim


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.