Merge https://bugzilla.mozilla.org/show_bug.cgi?id=666367 to production production-0.8 FENNEC_7_0_1_BUILD1 FENNEC_7_0_1_RELEASE FENNEC_7_0_BUILD1 FENNEC_7_0_BUILD2 FENNEC_7_0_RELEASE FENNEC_8_0b1_BUILD1 FENNEC_8_0b1_RELEASE FENNEC_8_0b2_BUILD1 FENNEC_8_0b2_RELEASE FENNEC_8_0b3_BUILD1 FENNEC_8_0b3_RELEASE FENNEC_8_0b4_BUILD1 FENNEC_8_0b4_RELEASE FIREFOX_7_0_1_BUILD1 FIREFOX_7_0_1_RELEASE FIREFOX_7_0_BUILD1 FIREFOX_7_0_BUILD2 FIREFOX_7_0_RELEASE FIREFOX_8_0b1_BUILD1 FIREFOX_8_0b1_RELEASE FIREFOX_8_0b2_BUILD1 FIREFOX_8_0b2_BUILD2 FIREFOX_8_0b2_RELEASE FIREFOX_8_0b3_BUILD1 FIREFOX_8_0b3_RELEASE FIREFOX_8_0b4_BUILD1 FIREFOX_8_0b4_RELEASE
authorBen Hearsum <bhearsum@mozilla.com>
Wed, 21 Sep 2011 05:30:44 -0700
branchproduction-0.8
changeset 303 aeaa057e9df6f7453ae745bf73d245a19764a5ba
parent 195 3dc678eecd11a2adc1e51221887eb7cdc45b4b6d (current diff)
parent 302 93b5fefe8474861bce5f1b2b709bc28e7367e092 (diff)
child 336 a2045101fe7a3bec7dd382fed870306ea0c1dac8
push id143
push userbhearsum@mozilla.com
push dateWed, 21 Sep 2011 12:31:20 +0000
bugs666367
Merge https://bugzilla.mozilla.org/show_bug.cgi?id=666367 to production
--- a/.hgtags
+++ b/.hgtags
@@ -71,8 +71,116 @@ aa65fddf81ca11684505fa59673fe14a505a3432
 aa65fddf81ca11684505fa59673fe14a505a3432 FIREFOX_3_6_17_RELEASE
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_3_6_17_RELEASE
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_3_6_17_BUILD3
 aa65fddf81ca11684505fa59673fe14a505a3432 FIREFOX_3_5_19_RELEASE
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_3_5_19_RELEASE
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_3_5_19_BUILD2
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_5_0b1_RELEASE
 509eed75bf25f2d9c28575e4075b10bfd5d01c36 FIREFOX_5_0b1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b3_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b4_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b5_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b5_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_18_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_18_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b6_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b6_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b7_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0b7_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_18_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_18_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_18_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0_1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_5_0_1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_19_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_19_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b3_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b3_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b3_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b3_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b4_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b4_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_20_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_20_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b5_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b5_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b5_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0b5_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b6_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0b6_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_21_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_21_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_1_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_1_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b3_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b3_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b3_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_2_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_22_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_22_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b4_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b4_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_6_0_2_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_2_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_6_0_2_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_22_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_22_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_22_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b4_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b4_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b4_BUILD2
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b5_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b5_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b5_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b5_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b6_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FENNEC_7_0b6_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b6_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_7_0b6_BUILD1
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_23_RELEASE
+3dc678eecd11a2adc1e51221887eb7cdc45b4b6d FIREFOX_3_6_23_BUILD1
--- a/master/buildbot/process/builder.py
+++ b/master/buildbot/process/builder.py
@@ -939,16 +939,18 @@ class Builder(pb.Referenceable, service.
             self._resubmit_buildreqs(build).addErrback(log.err) # returns Deferred
         else:
             brids = [br.id for br in build.requests]
             self.db.retire_buildrequests(brids, results)
 
         if sb.slave:
             sb.slave.releaseLocks()
 
+        self.updateBigStatus()
+
         self.triggerNewBuildCheck()
 
     def _resubmit_buildreqs(self, build):
         brids = [br.id for br in build.requests]
         return self.db.resubmit_buildrequests(brids)
 
     def setExpectations(self, progress):
         """Mark the build as successful and update expectations for the next
--- a/slave/buildslave/pbutil.py
+++ b/slave/buildslave/pbutil.py
@@ -2,16 +2,17 @@
 """Base classes handy for use with PB clients.
 """
 
 from twisted.spread import pb
 
 from twisted.spread.pb import PBClientFactory
 from twisted.internet import protocol, reactor
 from twisted.python import log
+from twisted.cred import error
 
 class ReconnectingPBClientFactory(PBClientFactory,
                                   protocol.ReconnectingClientFactory):
     """Reconnecting client factory for PB brokers.
 
     Like PBClientFactory, but if the connection fails or is lost, the factory
     will attempt to reconnect.
 
@@ -51,33 +52,34 @@ class ReconnectingPBClientFactory(PBClie
         RCF.clientConnectionLost(self, connector, reason)
 
     def startedConnecting(self, connector):
         self.startHungConnectionTimer(connector)
 
     def clientConnectionMade(self, broker):
         self.resetDelay()
         PBClientFactory.clientConnectionMade(self, broker)
-        self.doLogin(self._root)
+        self.doLogin(self._root, broker)
         self.gotRootObject(self._root)
 
     # newcred methods
 
     def login(self, *args):
         raise RuntimeError, "login is one-shot: use startLogin instead"
 
     def startLogin(self, credentials, client=None):
         self._credentials = credentials
         self._client = client
 
-    def doLogin(self, root):
+    def doLogin(self, root, broker):
         # newcred login()
         d = self._cbSendUsername(root, self._credentials.username,
                                  self._credentials.password, self._client)
-        d.addCallbacks(self.gotPerspective, self.failedToGetPerspective)
+        d.addCallbacks(self.gotPerspective, self.failedToGetPerspective,
+                errbackArgs=(broker,))
 
     # timer for hung connections
 
     def startHungConnectionTimer(self, connector):
         self.stopHungConnectionTimer()
         def hungConnection():
             log.msg("connection attempt timed out (is the port number correct?)")
             self.hungConnectionTimer = None
@@ -98,23 +100,30 @@ class ReconnectingPBClientFactory(PBClie
         self.stopHungConnectionTimer()
 
     def gotRootObject(self, root):
         """The remote root object (obtained each time this factory connects)
         is now available. This method will be called each time the connection
         is established and the object reference is retrieved."""
         self.stopHungConnectionTimer()
 
-    def failedToGetPerspective(self, why):
+    def failedToGetPerspective(self, why, broker):
         """The login process failed, most likely because of an authorization
         failure (bad password), but it is also possible that we lost the new
         connection before we managed to send our credentials.
         """
         log.msg("ReconnectingPBClientFactory.failedToGetPerspective")
         self.stopHungConnectionTimer()
+        # put something useful in the logs
         if why.check(pb.PBConnectionLost):
             log.msg("we lost the brand-new connection")
-            # retrying might help here, let clientConnectionLost decide
+            # fall through
+        elif why.check(error.UnauthorizedLogin):
+            log.msg("unauthorized login; check slave name and password")
+            # fall through
+        else:
+            log.err(why, 'While trying to connect:')
+            self.stopTrying()
+            reactor.stop()
             return
-        # probably authorization
-        self.stopTrying() # logging in harder won't help
-        log.err(why)
-        reactor.stop()
+
+        # lose the current connection, which will trigger a retry
+        broker.transport.loseConnection()