This bug comes out of discussion on
MDL-27809 about the number of times the navigation goes to the database, and the amount of content it is collecting from it.
Ideally the navigation should only go the database when it really needs to and should only ever request what it is going to use (fields).
Areas to focus on include the retrieving of courses and categories. Certainly for categories we only need 2 or 3 fields and for courses if it is same to same thing.