Great point! Who goes to a search engine and looks through 50 pages of
results?  If it's for the UI, then you need more restrictive finders
anyways.

If it's for a bulk operation you want to try and avoid doing it using entity
beans as they aren't well suited for the task.

Cheers

-----Original Message-----
From: Alex Paransky
To: [EMAIL PROTECTED]
Sent: 11/2/01 4:36 AM
Subject: Re: result stepping

There are a number of views on this issue:

1) Avoid the issue.  Sure, it's nice to be able to scroll through
thousands
of items, however, how is this adding value to the user?  What use case
is
this satisfying?  To avoid this, perhaps a classification for the items
needs to be designed and a tree-like navigation created to allow user to
navigate to the proper set of items.

2) Another way might be to execute the ejbFind but store the resulting
collection in a state full session bean.  Then get more items from the
state
full session bean as the user is scrolling up or down.  A smart EJB
container will not try to load thousands of items that you have found in
ejbFind unless you attempt to specifically access that item.  Even then,
not
all the items can be kept in memory due to memory limitations.  Assuming
you
are not in a transaction (you might have problems using state full
session
bean in a transaction when it comes to finally remove) the container can
unload those beans which are not being used.

3) Finally, you can go directly to the database and avoid the Entity
beans
altogether.

I am interested in what others have to say on this issue.

-AP_



-----Original Message-----
From: A mailing list for Enterprise JavaBeans development
[mailto:[EMAIL PROTECTED]]On Behalf Of David Levine
Sent: Thursday, November 01, 2001 8:39 AM
To: [EMAIL PROTECTED]
Subject: result stepping


If I were to use entity beans to represent items in a catalog, and the #
of
items was fairly large (tens to hundreds of thousands), the Collection
returned by a findBy might be huge.

I can certainly see how one would build a traditional "paging" mechanism
using BMP (to get only a subset of results, and be able to step forward
or
backwards through the catalog).  But is it possible to do using CMP?  My
instinct is "no", that this is a case where BMP is necessary.  But I
just
thought I'd ask to see if anyone has thoughts to the contrary.

Thanks,
David

========================================================================
===
To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

========================================================================
===
To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to