Multiple profiles sharing same email address and index getting out of sync

Bug #944011 reported by Paul Everitt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KARL3
Won't Fix
Low
Chris Rossi

Bug Description

Carol at 6FU reported that, despite her being in a community, she wasn't allowed to email in. Chris did some research.

Mailin figures gets the profile of an email's author by getting the profiles folder and calling profiles.getProfileByEmail(), which in turn relies on a datastructure on the profiles folder, an OOBTree, email_to_name, which is used as a local index for looking up a user's id given their email address. The email_to_name structure is updated in an event handler, models.subscribers.profile_added, which is registered for IObjectAddedEvent and IObjectModifiedEvent. Although, I haven't fully traced the code, there must exist a path through the code where you can add a profile without triggering one of those events (or trigger it before the email is set on the profile). When I looked just now, we had 6032 profiles but only 5739 entries in the email_to_name index, so obviously we're out of sync.

So, what I've done is I've compiled a list of all of the users who were not in the index and saved out to disk so that we can go back and refer it to later, in case we want to search for a pattern there. I've also gone ahead and rebuilt the email_to_name index by hand, so it is now up to date. This means Carol, among others, should now be able to post to Karl via mailin. This has also led me to my next sad discovery. The size of the index after rebuilding it was still only 5937 entries. It turns out the reason for *that* is there are multiple profiles with the same email addresses. So for those users with more than one Karl profile, it is now a crapshoot which of their profiles wound up in the index. This, obviously, has implications for mailin behaving sanely.

So, to sum up:

1) Carol can emailin to Karl.
2) We need to figure out how/why multiple profiles can share the same email address and what we should do about that.
3) We need to figure out why the email_to_name index gets out of sync and fix that.

Changed in karl3:
milestone: m95 → m97
Changed in karl3:
milestone: m97 → m100
Changed in karl3:
milestone: m100 → m104
Changed in karl3:
milestone: m104 → m108
Changed in karl3:
milestone: m108 → m112
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

Let's at least look at this next week and decide to either call the janitor and clean it up, or wontfix it.

Changed in karl3:
milestone: m112 → m110
Changed in karl3:
milestone: m110 → m111
Changed in karl3:
milestone: m111 → m114
JimPGlenn (jpglenn09)
Changed in karl3:
milestone: m114 → m115
Changed in karl3:
milestone: m115 → m116
Changed in karl3:
milestone: m116 → m118
JimPGlenn (jpglenn09)
Changed in karl3:
milestone: m118 → m119
Revision history for this message
Paul Everitt (paul-agendaless) wrote :

We need to slow everything down until we get clarity on the Q4 budget.

Changed in karl3:
milestone: m119 → m120
Changed in karl3:
milestone: m120 → m123
Changed in karl3:
milestone: m123 → m124
Tres Seaver (tseaver)
Changed in karl3:
milestone: m124 → m999
Changed in karl3:
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.