OK, I think I understand what's going on. I don't know whether you are
familiar with the java pet store taglibs, but they are only used in two
files: template.jsp and ScreenDefinitions.jsp. What I notice is that in
the ScreenDefinitions.jsp file some screens use three parameters and other
use four. So I'm guessing that if I create a blank.jsp and use it just as
a filler in the screens that have three parameters (so that they have four
instead) I'll solve the problem and will not need to use the
jsp.reuse.tags flag. Would that work?

Thanks,
Luis

On Tue, 3 Oct 2000, Karl Avedal wrote:

> Hello again,
> 
> Hmm, I should update my own reply, because that example is actually a bad one,
> since it's illegal to reuse the tag in that specific case. However, the
> principle is the same. Tags might be reused under certain circumstances, and
> they assume this isn't done.
> 
> Regards,
> Karl Avedal
> 
> Karl Avedal wrote:
> 
> > Hello Luis,
> >
> > Let's say we have this in a JSP:
> >
> > <foo:bar baz="123" baz2="234"/>
> > Some text
> > <foo:bar baz="123"/>
> >
> > In a JSP container, tags might be reused (the tag instances are pooled), so
> > when the tag foo:bar is used for the second time above, the optional
> > attribute baz2 may still have the value "234" since the same instance as
> > before is used, so when having optional attributes like above, you have to
> > be careful.
> >
> > This is exactly what the pet store is doing and they assume that the tag
> > will not be reused (that they get a clean instance every time). This
> > probably comes from the fact that they implemented using the J2EE RI. The
> > J2EE RI is not meant to be fast, but just to follow the spec, so that
> > implementation does not reuse the tag instances.
> >
> > So when they tested the petstore on the RI it worked fine, but it did not
> > work in containers doing this optimization. For this reason we provided a
> > property for Orion to turn off the tag instance reuse optimization.
> >
> > Regards,
> > Karl Avedal
> >
> > Luis M Bernardo wrote:
> >
> > > hello,
> > >
> > > can someone explain what's wrong with the pet store taglibs that we need
> > > to use the switch -Djsp.reuse.tags=false when running the orion port of
> > > that demo.
> > >
> > > thanx.
> > > luis
> 
> 
> 


Reply via email to