Actually, this isn’t true. It all
depends on how you handle the list. All displaytag wants every time around is
a List object (or whatever else it accepts). It’s entirely up to you how
and when that list is populated. For example, you could do the db query, push
the list into the user session, then just use that each time the user does a
sort or page move. The really important thing is that displaytag DOES NOT CARE
where its list comes from. All it wants is its data. It’s up to you
where that list comes from. Now, the solution Ricardo is talking about
is a good one because it doesn’t require you to query the db and cache 50K
records at a time, which in terms of scalability in an application with any
decent number of users will probably be necessary. I haven’t done it
myself, but I’ve seen it discussed on this list so do a search for
PaginatedList in the list archive. What you really want to do is a lazy fetch
on the database, so that you’re really only retrieving the 15 records for
display each time (this causes trouble with sorting within displaytag, since it
doesn’t have all of the items to sort, meaning that you need to actually
do an order by within the SQL; that’s probably OK though, since the
database is better at that sort of thing, but it’s another challenge to
deal with). Doing a lot of small queries like this has its own performance
penalties (with one big fetch you only have one round trip to the server), but
storing 50K records per user is a real resource hog! Rick Herrick From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ricardo Tercero Lozano Yes, It's needed in order
to sort data. If you really want to get from DDBB the showed records you have
to implement PaginatedList interface and send it to DisplayList as any other
list or collection. On 8/24/06, Din Sush
<[EMAIL PROTECTED]> wrote: I tried looking for an answer on the mailing list but |
------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ displaytag-user mailing list displaytag-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/displaytag-user