[Zope-CMF] DCWorkflow Worklists are very expensive
Chris Withers
chrisw@nipltd.com
Thu, 03 Oct 2002 12:32:09 +0100
John Morton wrote:
> Every time a worklist action is rendered, it must do a catalog query to find
> out if any there are any objects in that state, and how many. This, as Shane
> has noted in the past, is kinda expensive :-)
I'm guessing this is actually "Every time getFilteredActionsFor is called".
One possibility is to only call getFilteredActionsFor once per rendered page.
> Off the top of my head, I can think of a few potential solutions. One is to
> tune up your catalog.
What tuning would you invisige doing?
> Another is to change the worklists to just indicate
> whether there are or are not any items in the worklist, using a catalog query
> that stops on the first item found. I think this is theoretically possible,
> but I don't know enough about the catalog to know for sure.
ZCatalog can't do that.
> Another solution is to create a new action catagory called something like
> 'memberarea', which is only included if you are viewing pages under your own
> personal memberarea, and have the worklist actions appear under that.
I don't think this would help. You'd still be calculating the action each time,
you just wouldn't eb using it unless the memberarea category was visible.
cheers,
Chris