Saturday, July 19, 2003 10:05 AM
Value objects are probably the way to go because you don't want to expose the result set back to the struts/JSP layer. Not only would you have serialization issues, as you mentioned, but you would also have a dirtier architecture because you'd be exposing the inner workings of the persistence layer's result set.
If you have a big result set, you may consider using stateful session beans. The bean would conserve the result set in memory and allow the struts/JSP layer to make multiple calls to get a page of result set - one invocation at a time. Each page would be returned in value objects. If, on the other hand, you don't expect large result sets, simply return everything in one shot.