[Zodb-checkins] CVS: ZEO/ZEO/tests - testZEO.py:1.16.4.13

Jeremy Hylton jeremy@zope.com
Tue, 29 Jan 2002 10:14:35 -0500


Update of /cvs-repository/ZEO/ZEO/tests
In directory cvs.zope.org:/tmp/cvs-serv19570

Modified Files:
      Tag: Standby-branch
	testZEO.py 
Log Message:
Add some extra zLOG calls to track the progress of
checkReconnection().


=== ZEO/ZEO/tests/testZEO.py 1.16.4.12 => 1.16.4.13 ===
         obj = MinPO(12)
         revid1 = self._dostore(oid, data=obj)
+        zLOG.LOG("checkReconnection", zLOG.INFO,
+                 "About to shutdown server")
         self.shutdownServer()
         self.running = 1
+        zLOG.LOG("checkReconnection", zLOG.INFO,
+                 "About to restart server")
         self._startServer(create=0)
         oid = self._storage.new_oid()
         obj = MinPO(12)
@@ -311,6 +315,9 @@
                 break
             except (Disconnected, select.error, thread.error, socket.error), \
                    err:
+                zLOG.LOG("checkReconnection", zLOG.INFO,
+                         "Error after server restart; retrying.",
+                         error=sys.exc_info())
                 get_transaction().abort()
                 time.sleep(0.1) # XXX how long to sleep
             # XXX This is a bloody pain.  We're placing a heavy burden
@@ -318,6 +325,7 @@
             # write robust code.  Need to think about implementing
             # John Heintz's suggestion to make sure all exceptions
             # inherit from POSException.
+        zLOG.LOG("checkReconnection", zLOG.INFO, "finished")
 
 class UnixConnectionTests(ConnectionTests):