Efficient queries for notification menu items
One of the things the performance investigations of su92l turned up is that the queries used to determine the contents of the notification menu (e.g. has the user run a pipeline task yet?) are very expensive. While we want to improve the performance of the collection API, anything done this frequently should be super lightweight.
One possible solution would be to make this, and things like it, a flag on the user profile -- either a virtual flag computed at login time or an actual flag bit like is_active, is_admin, etc.
The results of the original investigation are here: https://dev.arvados.org/issues/10078#note-5