struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From new2you <new2...@gmx.de>
Subject Weird s:iterator behavior
Date Sat, 31 Mar 2007 14:25:35 GMT

Hi!
I've got quite the strange problem, in particular with the "iterator"-tag
Outline:
I'm having a arraylist of objects in the session; accessing this list via
the iterator-tag; within the iterator, accessing some attributes of the
objects; the following happens:  Sometimes, the list is not iterated at
all(as if it was empty), sometimes it iterates, but all the attributes of
the object are empty Strings, sometimes everything iterates just like I want
it. All this in completely random order.

Of course you can say, if you change the arraylist of objects in the action
the appropriate way, willingly or not, this behaviour is pretty plausible,
BUT this even happens when submitting a completely empty refresh-method, not
doing anything except redirecting, especially nothing with the session or
session attributes.


If I should guess what is happining, I would say that the iterator-tag
hasent quit iterating, but the page is already submitted to the browser.
Thread-safety issue so to speak.

Weird thing is also, if I change the list of objects into an list of
strings, everything works fine. (At least it seems)

Is there ANYTHING I could be doing wrong that causes this behavior? Always
hearing "S2 is thread-safe"... and not using any threads by myself... so no
idea what this could be causing...

I will later post more specific examples if it's already not clear what I
mean or what is going on.

Thanks
Toby
-- 
View this message in context: http://www.nabble.com/Weird-s%3Aiterator-behavior-tf3497039.html#a9767662
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message