[CalendarServer-changes] [7510] CalendarServer/trunk/contrib/performance/loadtest/population.py
source_changes at macosforge.org
source_changes at macosforge.org
Fri May 20 09:07:37 PDT 2011
Revision: 7510
http://trac.macosforge.org/projects/calendarserver/changeset/7510
Author: exarkun at twistedmatrix.com
Date: 2011-05-20 09:07:36 -0700 (Fri, 20 May 2011)
Log Message:
-----------
Also dump the exception that happened
Modified Paths:
--------------
CalendarServer/trunk/contrib/performance/loadtest/population.py
Modified: CalendarServer/trunk/contrib/performance/loadtest/population.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/population.py 2011-05-20 15:52:15 UTC (rev 7509)
+++ CalendarServer/trunk/contrib/performance/loadtest/population.py 2011-05-20 16:07:36 UTC (rev 7510)
@@ -162,7 +162,7 @@
msg(type="status", clientCount=self._user - 1)
- def _dumpLogs(self, loggingReactor):
+ def _dumpLogs(self, loggingReactor, reason):
path = FilePath(mkdtemp())
logstate = loggingReactor.getLogFiles()
i = 0
@@ -170,17 +170,18 @@
path.child('%03d.log' % (i,)).setContent(log.getvalue())
for i, log in enumerate(logstate.active, i):
path.child('%03d.log' % (i,)).setContent(log.getvalue())
+ path.child('reason.log').setContent(reason.getTraceback())
return path
def _clientFailure(self, reason, reactor):
- where = self._dumpLogs(reactor)
+ where = self._dumpLogs(reactor, reason)
err(reason, "Client stopped with error; recent traffic in %r" % (
where.path,))
def _profileFailure(self, reason, profileType, reactor):
- where = self._dumpLogs(reactor)
+ where = self._dumpLogs(reactor, reason)
err(reason, "Profile stopped with error; recent traffic in %r" % (
where.path,))
@@ -262,7 +263,6 @@
import random
from twisted.internet import reactor
- from twisted.internet.task import LoopingCall
from twisted.python.log import addObserver
from twisted.python.failure import startDebugMode
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20110520/912f30f2/attachment.html>
More information about the calendarserver-changes
mailing list