I then turned to my bookmarks index page that still was quite slow. It turned out permissions was the problem again. By removing a check of whether the user can write in any of the displayed folders I cut the response time by seconds. The bookmarks select query still takes about 400 ms though and I'd like to remove that if possible.
So thus, finally my question - what is the best way to cache a multirow? I know Don has used caching for the db API for Greenpeace - can we use that already, or should I use a different approach such as manually convert the multirow to a list and cache that?