evanchueng / gerrit

Automatically exported from code.google.com/p/gerrit
Apache License 2.0
0 stars 0 forks source link

Wanting to obtain email address if gerrit account id is known #604

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I want to be able to email people on our team about failed changes however on 
my server for some reason the authors of changes are not showing but their 
gerrit account ids do, I'm wondering if this is possible and if so what steps 
would i need to take in order to achieve this?

Original issue reported on code.google.com by Andy.Yba...@gmail.com on 21 Jun 2010 at 5:32

GoogleCodeExporter commented 9 years ago
Sounds like your users haven't filled in their preferred
email address.  Have each user go to Settings, Contact
Information tab and select a preferred email address.

Original comment by sop@google.com on 21 Jun 2010 at 5:35

GoogleCodeExporter commented 9 years ago
What we're using is something called dashboard and it simply uses gerrit, so 
its not that i'm accessing gerrit directly, the users of gerrit already have 
their preferred emails setup because they've been able to push changes and 
receive email about them accordingly. The reason I ask my question is because 
the gerrit account id is the only piece of information that is usable for the 
purposes of sending emails. That same gerrit account id is the same person I 
want to send an email to, so thats why I am wondering if gerrit had some means 
of mapping email addresses together with account id's.

Original comment by Andy.Yba...@gmail.com on 21 Jun 2010 at 5:44

GoogleCodeExporter commented 9 years ago
I guess I'm still not following you.

What is this "dashboard"?  How is it integrated with Gerrit?

Gerrit does have a mapping of account id number to preferred
email address for that user, but this mapping is internal in
the database.  Currently to get it you would need to perform
a direct database query.  Most external interfaces however
export the identity of a user as that email address, so I'm a
bit confused as to how you have the internal account id number
and not the email.

Original comment by sop@google.com on 21 Jun 2010 at 5:52

GoogleCodeExporter commented 9 years ago
Thats whats puzzling me also because, (these files are written in ruby) when I 
perform a search and filter to remove changes that do not have authors and then 
print them out I still have many changes that display nothing for an author, 
almost like its not nil but its been declared as " " just an empty pair of 
quotes or perhaps its something that wont display for some reason in my 
terminal. Still the gerrit account id shows up. The objects holding this 
information belong to dashboard, it basically keeps track of the project name, 
the date of last update, change id, patch set, and other misc information.   

Dashboard is an interface that lists changes based on projects and it separates 
them by team and whether they have failed, approved or pending based on certain 
criteria. Gerrit is what stores the actual changes and what we use to review 
the changes.

How would I go about performing a database query?

The goal of what I am doing is to create a script that will email owners of 
failed changes if they haven't been modified in over a week. 

Original comment by Andy.Yba...@gmail.com on 21 Jun 2010 at 6:06

GoogleCodeExporter commented 9 years ago
Sounds like you need to talk to the authors of dashboard.
I have no idea how they are getting data out of gerrit, or
why they don't have an email address for users.

Original comment by sop@google.com on 21 Jun 2010 at 6:13

GoogleCodeExporter commented 9 years ago

Original comment by sop@google.com on 19 Jul 2010 at 11:41