[CalendarServer-changes] [6652] CalendarServer/trunk/contrib/performance/benchmark.py
source_changes at macosforge.org
source_changes at macosforge.org
Thu Nov 18 13:15:32 PST 2010
Revision: 6652
http://trac.macosforge.org/projects/calendarserver/changeset/6652
Author: exarkun at twistedmatrix.com
Date: 2010-11-18 13:15:27 -0800 (Thu, 18 Nov 2010)
Log Message:
-----------
Only trace for pgsql i/o if the calendar server processes are also being traced
Modified Paths:
--------------
CalendarServer/trunk/contrib/performance/benchmark.py
Modified: CalendarServer/trunk/contrib/performance/benchmark.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmark.py 2010-11-18 19:29:53 UTC (rev 6651)
+++ CalendarServer/trunk/contrib/performance/benchmark.py 2010-11-18 21:15:27 UTC (rev 6652)
@@ -228,12 +228,16 @@
ready.append(started)
self.finished.append(stopped)
- # Also trace postgres i/o operations. This involves no
- # target, because the dtrace code just looks for processes
- # named "postgres".
- started, stopped = self._startDTrace("pgsql.d", None)
- ready.append(started)
- self.finished.append(stopped)
+ if self.pids:
+ # If any tracing is to be done, then also trace postgres
+ # i/o operations. This involves no target, because the
+ # dtrace code just looks for processes named "postgres".
+ # We skip it if we don't have any pids because that's
+ # heuristically the "don't do any dtracing" setting (it
+ # might be nice to make this explicit).
+ started, stopped = self._startDTrace("pgsql.d", None)
+ ready.append(started)
+ self.finished.append(stopped)
return gatherResults(ready)
@@ -397,6 +401,7 @@
pids = whichPIDs(source, plistlib.PlistParser().parse(conf.open()))
else:
pids = []
+ msg("Using dtrace to monitor pids %r" % (pids,))
startLogging(file('benchmark.log', 'a'), False)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20101118/aa792db5/attachment.html>
More information about the calendarserver-changes
mailing list