user preferred email address

750 views
Skip to first unread message

gituser

unread,
May 8, 2012, 1:08:19 AM5/8/12
to Repo and Gerrit Discussion
Hi ,

I used my gmail address as an openID to sign into gerrit.

But when I commit code via git I have registered under another email
address. I want to change my author address on gerrit. But it doesnt
seem to allow me to change it. (maybe because I logged in as a gmail
user -> and then when i want to change it , it wont allow me to). Is
there a way around this?

Magnus Bäck

unread,
May 8, 2012, 2:11:19 AM5/8/12
to Repo and Gerrit Discussion
While you can't change the email address registered for an account (at
least not if you use OpenID authentication), you should be able to
register additional email addresses for your account and make any of
them the primary addresses of the account. Use the Register New Email
button from Settings -> Contact Information.

--
Magnus Bäck
ba...@google.com

gituser

unread,
May 8, 2012, 8:45:34 PM5/8/12
to repo-d...@googlegroups.com
Hi ,

Thanks for your reply
I tried the suggested method a number of times. Every time i get the following error

Application Error
Server Error
Connection refused

I am trying to register with my school email address. By looking at the error log it seems that something prevents the email being sent

[2012-05-08 20:39:00,353] ERROR com.google.gerrit.httpd.rpc.account.AccountSecurityImpl : Cannot send email verification message to xxxxxxxxxx(myemail)@xxxxx.edu
com.google.gerrit.server.mail.EmailException: Connection refused
at com.google.gerrit.server.mail.SmtpEmailSender.open(SmtpEmailSender.java:245)
at com.google.gerrit.server.mail.SmtpEmailSender.send(SmtpEmailSender.java:152)
at com.google.gerrit.server.mail.OutgoingEmail.send(OutgoingEmail.java:116)
at com.google.gerrit.httpd.rpc.account.AccountSecurityImpl.registerEmail(AccountSecurityImpl.java:311)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at com.google.gwtjsonrpc.server.MethodHandle.invoke(MethodHandle.java:91)
at com.google.gwtjsonrpc.server.JsonServlet.doService(JsonServlet.java:382)
at com.google.gwtjsonrpc.server.JsonServlet.service(JsonServlet.java:268)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at com.google.inject.servlet.ServletDefinition.doService(ServletDefinition.java:216)
at com.google.inject.servlet.ServletDefinition.service(ServletDefinition.java:141)
at com.google.inject.servlet.ManagedServletPipeline.service(ManagedServletPipeline.java:93)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:63)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.gwtexpui.server.CacheControlFilter.doFilter(CacheControlFilter.java:76)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.gerrit.httpd.RequestCleanupFilter.doFilter(RequestCleanupFilter.java:54)
at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
at com.google.inject.servlet.ManagedFilterPipeline.dispatch(ManagedFilterPipeline.java:122)
at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:110)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1322)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:473)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:921)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:403)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:856)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:114)
at org.eclipse.jetty.server.handler.RequestLogHandler.handle(RequestLogHandler.java:59)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:114)
at org.eclipse.jetty.server.Server.handle(Server.java:352)
at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:596)
at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1069)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:805)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:218)
at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:426)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:510)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.access$000(SelectChannelEndPoint.java:34)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:40)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:450)
at java.lang.Thread.run(Thread.java:679)
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:327)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:193)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:180)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:384)
at java.net.Socket.connect(Socket.java:546)
at org.apache.commons.net.SocketClient.connect(SocketClient.java:163)
at org.apache.commons.net.SocketClient.connect(SocketClient.java:184)
at com.google.gerrit.server.mail.SmtpEmailSender.open(SmtpEmailSender.java:215)
Thanks :)

Magnus Bäck

unread,
May 8, 2012, 8:55:53 PM5/8/12
to repo-d...@googlegroups.com
On Tuesday, May 08, 2012 at 20:45 EDT,
gituser <pra...@gmail.com> wrote:

> Thanks for your reply
> I tried the suggested method a number of times. Every time i get the
> following error
>
> Application Error
> Server Error
> Connection refused
>
> I am trying to register with my school email address. By looking at
> the error log it seems that something prevents the email being sent
>
> [2012-05-08 20:39:00,353] ERROR
> com.google.gerrit.httpd.rpc.account.AccountSecurityImpl : Cannot send
> email verification message to xxxxxxxxxx(myemail)@xxxxx.edu
> com.google.gerrit.server.mail.EmailException: Connection refused

Your SMTP server configuration (the sendemail section of gerrit.config)
is invalid. The server/port combination you have there doesn't listen
to requests.

http://gerrit-documentation.googlecode.com/svn/Documentation/2.3/config-gerrit.html#_a_id_sendemail_a_section_sendemail

--
Magnus Bäck
ba...@google.com

Liu Zheng

unread,
May 8, 2012, 8:56:48 PM5/8/12
to repo-d...@googlegroups.com
Hi,

When I was trying to repo smartsync, I got an error of "error: cannot
smart sync: no manifest server defined in manifest". Any one can help
me, what should I do in my manifest file?

Thanks.

Liu

Pursehouse, David

unread,
May 8, 2012, 9:06:30 PM5/8/12
to Liu Zheng, repo-d...@googlegroups.com
Add the line:

<manifest-server url="http://your-manifest-server:8000"/>

In the default.xml file.

See the documentation of the manifest format [1]:

At most one manifest-server may be specified. The url attribute
is used to specify the URL of a manifest server, which is an
XML RPC service that will return a manifest in which each project
is pegged to a known good revision for the current branch and
target.

[1]
http://code.google.com/p/git-repo/source/browse/docs/manifest-format.txt?spec=svnbca94fd1b0157b07802d4998582a7fed0ba9ca17&name=bca94fd1b0&r=bca94fd1b0157b07802d4998582a7fed0ba9ca17

--
David Pursehouse
Configuration Manager
Sony Mobile Communications Japan, Inc.
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

gituser

unread,
May 8, 2012, 9:34:41 PM5/8/12
to repo-d...@googlegroups.com
Hi Mahnus,


Thanks for your reply.I edited the config file....but still doesnt seem to work.
[sendemail]
    enable = true
    from = MIXED
    smtpServer = 127.0.0.1
    smtpServerPort = 25
    smtpEncryption = none
    sslVerify = true
    smtpUser = xx...@gmail.com
    smtpPass = xxxx

stopped and started the server after the change. Still doesnt seem to work :(
2012-05-08 21:31:18,306] ERROR com.google.gerrit.httpd.rpc.account.AccountSecurityImpl : Cannot send email verification message to xxxxx...@gmail.com
    ... 51 more

Richard Bywater

unread,
May 8, 2012, 9:44:58 PM5/8/12
to gituser, repo-d...@googlegroups.com
If, on the server that Gerrit is running on, you try :
telnet 127.0.0.1 25

does that succeed? (assuming you have telnet installed)

It sounds to me like you don't have a SMTP server running on the same machine as Gerrit.

Richard.

--
Message has been deleted

gituser

unread,
May 8, 2012, 9:55:06 PM5/8/12
to repo-d...@googlegroups.com, gituser


Thanks for your help!

Hmm well I am using a unix machine and it has telnet installed. But to get the email sent via the website what additional steps do i have to perform?
Richard.

Pursehouse, David

unread,
May 8, 2012, 10:10:16 PM5/8/12
to gituser, repo-d...@googlegroups.com

> Hmm well I am using a unix machine and it has telnet installed.

> 

But does it have an smtp server installed and running?

 

You’ve already been given the command that you can use to check that smtp is working with the configuration that you’re using:

 

telnet 127.0.0.1 25

 

Does that work?

 

> But to get the email sent via the website what additional steps do i have to perform?
>

Install and properly configure smtp on your server.   Or use another mail server.

 

See here for how to configure it to use Gmail, for example:

https://groups.google.com/forum/#!topic/repo-discuss/6FSg5XksjaE/discussion

gituser

unread,
May 8, 2012, 10:23:37 PM5/8/12
to repo-d...@googlegroups.com, gituser
Thanks!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1

Your comment and link was really helpful! ..I got it to work with the following config setting

sendemail]
    enable = true
    smtpServer = smtp.gmail.com
    smtpServerPort = 465
    smtpEncryption = SSL
    sslVerify = false
    smtpUser = xx...@gmail.com   
    smtpPass = xxxxxxx

But I generally wonder that this process should be automated in the future.

Thanks again for your reply.

Magnus Bäck

unread,
May 9, 2012, 12:32:39 AM5/9/12
to repo-d...@googlegroups.com
On Tue, May 8, 2012 at 7:23 PM,
gituser <pra...@gmail.com> wrote:

> Your comment and link was really helpful! ..I got it to work with the
> following config setting
>
> sendemail]
>     enable = true
>     smtpServer = smtp.gmail.com
>     smtpServerPort = 465
>     smtpEncryption = SSL
>     sslVerify = false
>     smtpUser = xx...@gmail.com
>     smtpPass = xxxxxxx
>
> But I generally wonder that this process should be automated in the future.

How? The SMTP server configuration is site-specific, and only the
administrator is in the position to make the right choice here.

--
Magnus Bäck
ba...@google.com

Luthander, Fredrik

unread,
May 9, 2012, 4:13:25 AM5/9/12
to Magnus Bäck, repo-d...@googlegroups.com
Hi Magnus!

Some random thoughts here:

> -----Original Message-----
> From: repo-d...@googlegroups.com [mailto:repo-
To play the devils advocate:
I wouldn't consider it to be at all impossible to have a question about this in the installation wizard, querying whether the user is on the open internet or inside a firewalled environment, and if so we can prefill the smtp values with the gmail server values.

That said I personally think that even if we fix that we'll just move the questions in front of us. This opens up for other errors and symptoms when some fresh Gerrit owners just presses enter to get through the annoying wizard.

A viable alternative would be to have the wizard ask whether people want SMTP enabled and if not (the default), hide the SMTP-settings in the wizard and just set SMTPenabled to false. That way they could try Gerrit out for a while without having to get too technical with the SMTP stuff.

The only problem with that would be that new users wouldn't get their new email authentication emails (they wouldn't get them, would they? Do we still require those emails even if SMTP is disabled?). Hmm. How could we fix that scenario? Is it a viable solution to investigate?

--
Best regards,
    Fredrik Luthander
Sony Mobile Communications AB

Magnus Bäck

unread,
May 9, 2012, 12:24:58 PM5/9/12
to repo-d...@googlegroups.com
On Wednesday, May 09, 2012 at 04:13 EDT,
"Luthander, Fredrik" <Fredrik....@sonymobile.com> wrote:

> To play the devils advocate:
> I wouldn't consider it to be at all impossible to have a question
> about this in the installation wizard, querying whether the user is on
> the open internet or inside a firewalled environment, and if so we can
> prefill the smtp values with the gmail server values.

But the question isn't really about open Internet vs. firewalled
sandbox, is it? What people need to understand is "what's my
closest/preferred SMTP server", which is pretty much what we're
asking about now. I suppose we could clarify the questions a bit
and possibly probe the selected configuration before continuing
(i.e. practice fail early), but it's not clear that it's worth
the effort.

What we certainly could do is include a Gmail example in the
documentation.

> That said I personally think that even if we fix that we'll just
> move the questions in front of us. This opens up for other errors
> and symptoms when some fresh Gerrit owners just presses enter to
> get through the annoying wizard.

Yes. That's apparently what happens now. I don't know what can save us
from that.

> A viable alternative would be to have the wizard ask whether people
> want SMTP enabled and if not (the default), hide the SMTP-settings in
> the wizard and just set SMTPenabled to false. That way they could try
> Gerrit out for a while without having to get too technical with the
> SMTP stuff.
>
> The only problem with that would be that new users wouldn't get their
> new email authentication emails (they wouldn't get them, would they?
> Do we still require those emails even if SMTP is disabled?). Hmm. How
> could we fix that scenario? Is it a viable solution to investigate?

Because of the email confirmations you really need to have SMTP enabled
on the server, so making it too easy to disable SMTP would probably just
push the problem in front of us.

--
Magnus Bäck
ba...@google.com

Jason Axelson

unread,
May 9, 2012, 4:57:43 PM5/9/12
to gituser, repo-d...@googlegroups.com
Just a quick word of warning. If you're using gmail's servers directly
it will slow down your gerrit instance because each time gerrit does
an operation (e.g. accept a review, push up a change) gerrit will send
the email out to Gmail (which includes the whole SSL handshake). When
we switched to a local SMTP server from gmail and it made those
operations around 5 times faster.

Jason
> --
> To unsubscribe, email repo-discuss...@googlegroups.com

Magnus Bäck

unread,
May 9, 2012, 5:27:33 PM5/9/12
to repo-d...@googlegroups.com
On Wednesday, May 09, 2012 at 16:57 EDT,
Jason Axelson <jaxe...@referentia.com> wrote:

> Just a quick word of warning. If you're using gmail's servers directly
> it will slow down your gerrit instance because each time gerrit does
> an operation (e.g. accept a review, push up a change) gerrit will send
> the email out to Gmail (which includes the whole SSL handshake). When
> we switched to a local SMTP server from gmail and it made those
> operations around 5 times faster.

Yes, this is certainly true for Gerrit versions prior to 2.4 (which
hasn't been released yet). Starting with commit c26eafc, all email
send operations are asynchronous. That said, there are other reasons
why one should run a local SMTP server that Gerrit submits to; Gerrit
doesn't implement a retrying queue for outgoing email, so temporary
network outages may cause mail to be lost.

--
Magnus Bäck
ba...@google.com
Reply all
Reply to author
Forward
0 new messages