I'm looking at a performance issue with a site. Part of the problem seems to be the time taken to load all the attributes to construct a large number of brain objects.

I think I remember reading somewhere once that if you slice a sequence of catalog results as follows:

rs = portal_catalog.searchResults(portal_type='my_type')
return rs[10:30]

or even

<dtml-in "portal_catalog.searchResults(portal_type='my_type')" start=10 size=20>

that this "undoes" the advantage of the lazy sequence, as it has to iterate over all the items in the sequence to produce the slice.

Is this correct or have I just imagined it - can anyone confirm?! And if I haven't imagined it, how can I do this more efficiently?



Zope maillist  -  Zope@zope.org
**   No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to