Comment 3 for bug 5415

Revision history for this message
Guilherme Salgado (salgado) wrote : Re: [Bug 5415] Launchpad times out while searching for a person

> I also get (whatever it may be) OOPS-S26. The query I pasted above takes
> nothing to run on staging's psql prompt and returns only one row.
>
> Another one:
> RequestExpired: (('SELECT EmailAddress.id, EmailAddress.status, EmailAddress.person, EmailAddress.email FROM EmailAddress WHERE ((EmailAddress.person = 98) AND (EmailAddress.status = 4)) ORDER BY email',), {})
>
> This also runs immediately. I think we are bombing on something else..

This is the query that gets the preferred email of one of the persons/teams
whose name/email matched the text you entered. In case of Matthew (not sure if
yours is the same), this query (and some others) had to be executed almost
1400 times, so that's probably what causes the problem.

The problem here is that the vocabulary is dumb enough to try and fetch all
the results from the database and put that in a selectbox. What we need to do,
IMO, is to ask the user to try a search using the popup window, as that has a
batched list and thus won't time out.