struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Calvin G. Dodge" <>
Subject changing scope of custom JSTL class variables
Date Wed, 14 Jun 2006 21:31:24 GMT
I'm maintaining and upgrading an existing Struts application (written by someone else long
ago, with no chance of contacting the authors).

I just discovered that our custom tag class variables have global scope - when a tag class
(derived from javax.servlet.jsp.tagext.TagSupport) is used, an instance of that class is created
- but then reused, rather than having a new instance created every time the tag is used in
a JSP page.

This puzzles and troubles me - it means that getters and setters are dealing with global values,
rather than session values, and could lead to real trouble when we have enough users that
2 or more are using pages with the same tags at the same time.

Is there some configuration issue I'm missing?  I know that you can declare variable scope
for form beans - is there a way to do this with custom tag classes?


Calvin Dodge
Prosocial Applications, Inc.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message