[CalendarServer-changes] [7796] CalendarServer/trunk/contrib/performance
source_changes at macosforge.org
source_changes at macosforge.org
Thu Jul 14 13:59:09 PDT 2011
Revision: 7796
http://trac.macosforge.org/projects/calendarserver/changeset/7796
Author: exarkun at twistedmatrix.com
Date: 2011-07-14 13:59:08 -0700 (Thu, 14 Jul 2011)
Log Message:
-----------
Make the performance code into a sub-package of the contrib package.
Modified Paths:
--------------
CalendarServer/trunk/contrib/performance/benchmark.py
CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence.py
CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence_autoaccept.py
CalendarServer/trunk/contrib/performance/benchmarks/event.py
CalendarServer/trunk/contrib/performance/benchmarks/event_add_attendee.py
CalendarServer/trunk/contrib/performance/benchmarks/event_autoaccept.py
CalendarServer/trunk/contrib/performance/benchmarks/event_change_date.py
CalendarServer/trunk/contrib/performance/benchmarks/event_change_summary.py
CalendarServer/trunk/contrib/performance/benchmarks/event_delete.py
CalendarServer/trunk/contrib/performance/benchmarks/event_delete_attendee.py
CalendarServer/trunk/contrib/performance/benchmarks/event_move.py
CalendarServer/trunk/contrib/performance/benchmarks/find_calendars.py
CalendarServer/trunk/contrib/performance/benchmarks/find_events.py
CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence.py
CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence_autoaccept.py
CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy.py
CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy_vary_attendees.py
CalendarServer/trunk/contrib/performance/loadtest/config.plist
CalendarServer/trunk/contrib/performance/loadtest/ical.py
CalendarServer/trunk/contrib/performance/loadtest/logger.py
CalendarServer/trunk/contrib/performance/loadtest/population.py
CalendarServer/trunk/contrib/performance/loadtest/profiles.py
CalendarServer/trunk/contrib/performance/loadtest/sim.py
CalendarServer/trunk/contrib/performance/loadtest/test_ical.py
CalendarServer/trunk/contrib/performance/loadtest/test_population.py
CalendarServer/trunk/contrib/performance/loadtest/test_profiles.py
CalendarServer/trunk/contrib/performance/loadtest/test_sim.py
CalendarServer/trunk/contrib/performance/loadtest/test_trafficlogger.py
Added Paths:
-----------
CalendarServer/trunk/contrib/performance/__init__.py
Added: CalendarServer/trunk/contrib/performance/__init__.py
===================================================================
Modified: CalendarServer/trunk/contrib/performance/benchmark.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmark.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmark.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -32,7 +32,7 @@
from twisted.python.log import msg
from twisted.python.modules import getModule
-from stats import SQLDuration, Bytes
+from contrib.performance.stats import SQLDuration, Bytes
class DTraceBug(Exception):
@@ -431,7 +431,7 @@
pid.getContent() for pid in run.globChildren('*instance*')]
-_benchmarks = getModule("benchmarks")
+_benchmarks = getModule("contrib.performance.benchmarks")
def resolveBenchmark(name):
for module in _benchmarks.iterModules():
if module.name == ".".join((_benchmarks.name, name)):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -22,7 +22,7 @@
from itertools import count
from datetime import datetime, timedelta
-from _event_create import (
+from contrib.performance._event_create import (
makeAttendees, makeVCalendar, formatDate, measure as _measure)
def makeEvent(i, organizerSequence, attendeeCount):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence_autoaccept.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence_autoaccept.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/bounded_recurrence_autoaccept.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -22,7 +22,7 @@
from itertools import count
from datetime import datetime, timedelta
-from _event_create import (
+from contrib.performance._event_create import (
makeAttendees, makeVCalendar, formatDate, measure as _measure)
def makeEvent(i, organizerSequence, attendeeCount):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -20,7 +20,7 @@
from itertools import count
-from _event_create import makeEvent, measure as _measure
+from contrib.performance._event_create import makeEvent, measure as _measure
def measure(host, port, dtrace, attendeeCount, samples):
calendar = "event-creation-benchmark"
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_add_attendee.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_add_attendee.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_add_attendee.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -14,8 +14,8 @@
# limitations under the License.
##
-from _event_change import measure as _measure
-from _event_create import makeAttendees
+from contrib.performance._event_change import measure as _measure
+from contrib.performance._event_create import makeAttendees
def measure(host, port, dtrace, attendeeCount, samples):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_autoaccept.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_autoaccept.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_autoaccept.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -23,7 +23,7 @@
from uuid import uuid4
from datetime import datetime, timedelta
-from _event_create import (
+from contrib.performance._event_create import (
makeAttendees, makeVCalendar, measure as _measure)
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_change_date.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_change_date.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_change_date.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -21,7 +21,7 @@
import datetime
-import _event_change
+from contrib.performance import _event_change
TIME_FORMAT = '%Y%m%dT%H%M%S'
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_change_summary.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_change_summary.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_change_summary.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -14,8 +14,8 @@
# limitations under the License.
##
-from _event_create import SUMMARY
-from _event_change import measure as _measure
+from contrib.performance._event_create import SUMMARY
+from contrib.performance._event_change import measure as _measure
def replaceSummary(event, i):
return event.replace(SUMMARY, 'Replacement summary %d' % (i,))
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_delete.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_delete.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_delete.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -27,11 +27,11 @@
from twisted.web.http_headers import Headers
from twisted.web.http import NO_CONTENT
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
-from benchlib import initialize, sample
-from event import makeEvent
+from contrib.performance.benchlib import initialize, sample
+from contrib.performance.benchmarks.event import makeEvent
@inlineCallbacks
def measure(host, port, dtrace, attendeeCount, samples):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_delete_attendee.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_delete_attendee.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_delete_attendee.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -14,7 +14,7 @@
# limitations under the License.
##
-import _event_change
+from contrib.performance import _event_change
def measure(host, port, dtrace, attendeeCount, samples):
def deleteAttendees(event, i):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/event_move.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/event_move.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/event_move.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -23,11 +23,11 @@
from twisted.web.http_headers import Headers
from twisted.web.http import CREATED
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
-from benchlib import initialize, sample
-from event import makeEvent
+from contrib.performance.benchlib import initialize, sample
+from contrib.performance.benchmarks.event import makeEvent
@inlineCallbacks
def measure(host, port, dtrace, attendeeCount, samples):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/find_calendars.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/find_calendars.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/find_calendars.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -23,10 +23,10 @@
from twisted.web.http_headers import Headers
from twisted.web.http import MULTI_STATUS
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
-from benchlib import CalDAVAccount, sample
+from contrib.performance.benchlib import CalDAVAccount, sample
PROPFIND = """\
<?xml version="1.0" encoding="utf-8"?>
Modified: CalendarServer/trunk/contrib/performance/benchmarks/find_events.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/find_events.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/find_events.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -24,11 +24,11 @@
from twisted.web.http_headers import Headers
from twisted.web.http import MULTI_STATUS
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
-from benchlib import CalDAVAccount, sample
-from event import makeEvent
+from contrib.performance.benchlib import CalDAVAccount, sample
+from contrib.performance.benchmarks.event import makeEvent
PROPFIND = """\
<?xml version="1.0" encoding="utf-8"?>
Modified: CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -22,7 +22,7 @@
from itertools import count
from datetime import datetime, timedelta
-from _event_create import (
+from contrib.performance._event_create import (
makeAttendees, makeVCalendar, measure as _measure)
def makeEvent(i, organizerSequence, attendeeCount):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence_autoaccept.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence_autoaccept.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/unbounded_recurrence_autoaccept.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -22,7 +22,7 @@
from itertools import count
from datetime import datetime, timedelta
-from _event_create import (
+from contrib.performance._event_create import (
makeAttendees, makeVCalendar, measure as _measure)
def makeEvent(i, organizerSequence, attendeeCount):
Modified: CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -29,9 +29,9 @@
from twisted.web.http_headers import Headers
from twisted.web.http import OK
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
-from benchlib import initialize, sample
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
+from contrib.performance.benchlib import initialize, sample
# XXX Represent these as vobjects? Would make it easier to add more vevents.
event = """\
Modified: CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy_vary_attendees.py
===================================================================
--- CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy_vary_attendees.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/benchmarks/vfreebusy_vary_attendees.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -28,11 +28,11 @@
from twisted.web.client import Agent
from twisted.internet import reactor
-from httpauth import AuthHandlerAgent
-from httpclient import StringProducer
-from benchlib import CalDAVAccount, sample
+from contrib.performance.httpauth import AuthHandlerAgent
+from contrib.performance.httpclient import StringProducer
+from contrib.performance.benchlib import CalDAVAccount, sample
-from benchmarks.vfreebusy import VFREEBUSY, formatDate, makeEventNear
+from contrib.performance.benchmarks.vfreebusy import VFREEBUSY, formatDate, makeEventNear
@inlineCallbacks
def measure(host, port, dtrace, attendees, samples):
Modified: CalendarServer/trunk/contrib/performance/loadtest/config.plist
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/config.plist 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/config.plist 2011-07-14 20:59:08 UTC (rev 7796)
@@ -32,11 +32,11 @@
returns a list of directory service records defining all of the
client accounts to use.
- loadtest.sim.recordsFromCSVFile reads username, password, mailto
+ contrib.performance.loadtest.sim.recordsFromCSVFile reads username, password, mailto
triples from a CSV file and returns them as a list of faked
directory service records. -->
<key>loader</key>
- <string>loadtest.sim.recordsFromCSVFile</string>
+ <string>contrib.performance.loadtest.sim.recordsFromCSVFile</string>
<!-- Keyword arguments may be passed to the loader. -->
<key>params</key>
@@ -46,7 +46,7 @@
directory while still allowing a relative path. This isn't
a great solution. -->
<key>path</key>
- <string>accounts.csv</string>
+ <string>contrib/performance/loadtest/accounts.csv</string>
</dict>
</dict>
@@ -57,19 +57,19 @@
<!-- Specify a class which creates new clients and introduces them into the test.
- loadtest.population.SmoothRampUp introduces groups of new clients at
+ contrib.performance.loadtest.population.SmoothRampUp introduces groups of new clients at
fixed intervals up to a maximum. The size of the group, interval,
and maximum are configured by the parameters below. The total
number of clients is groups * groupSize, which needs to be no larger
than the number of credentials created in the accounts section. -->
<key>factory</key>
- <string>loadtest.population.SmoothRampUp</string>
+ <string>contrib.performance.loadtest.population.SmoothRampUp</string>
<key>params</key>
<dict>
<!-- groups gives the total number of groups of clients to introduce.-->
<key>groups</key>
- <integer>60</integer>
+ <integer>99</integer>
<!-- groupSize is the number of clients in each group of clients. It's
really only a "smooth" ramp up if this is pretty small. -->
@@ -78,7 +78,7 @@
<!-- Number of seconds between the introduction of each group. -->
<key>interval</key>
- <integer>13</integer>
+ <integer>3</integer>
</dict>
</dict>
@@ -95,7 +95,7 @@
<!-- Here is a Snow Leopard iCal simulator. -->
<key>software</key>
- <string>loadtest.ical.SnowLeopard</string>
+ <string>contrib.performance.loadtest.ical.SnowLeopard</string>
<!-- Arguments to use to initialize the SnowLeopard instance. -->
<key>params</key>
@@ -103,7 +103,7 @@
<!-- SnowLeopard can poll the calendar home at some interval. This
is in seconds. -->
<key>calendarHomePollInterval</key>
- <integer>900</integer>
+ <integer>30</integer>
<!-- If the server advertises xmpp push, SnowLeopard can wait for
notifications about calendar home changes instead of polling for
@@ -112,7 +112,7 @@
Still fall back to polling if there is no xmpp push
advertised. -->
<key>supportPush</key>
- <true/>
+ <false/>
</dict>
<!-- The profiles define certain types of user behavior on top of the
@@ -124,7 +124,7 @@
new events at a random time on a random calendar. -->
<dict>
<key>class</key>
- <string>loadtest.profiles.Eventer</string>
+ <string>contrib.performance.loadtest.profiles.Eventer</string>
<key>params</key>
<dict>
@@ -181,7 +181,7 @@
<!-- This profile invites new attendees to existing events. -->
<dict>
<key>class</key>
- <string>loadtest.profiles.Inviter</string>
+ <string>contrib.performance.loadtest.profiles.Inviter</string>
<key>params</key>
<dict>
@@ -232,7 +232,7 @@
<!-- This profile accepts invitations to events. -->
<dict>
<key>class</key>
- <string>loadtest.profiles.Accepter</string>
+ <string>contrib.performance.loadtest.profiles.Accepter</string>
<key>params</key>
<dict>
@@ -269,16 +269,16 @@
<array>
<!-- ReportStatistics generates an end-of-run summary of the HTTP
requests made, their timings, and their results. -->
- <string>loadtest.population.ReportStatistics</string>
+ <string>contrib.performance.loadtest.population.ReportStatistics</string>
<!-- RequestLogger generates a realtime log of all HTTP requests made
during the load test. -->
- <string>loadtest.ical.RequestLogger</string>
+ <string>contrib.performance.loadtest.ical.RequestLogger</string>
<!-- OperationLogger generates an end-of-run summary of the gross
operations performed (logical operations which may span more than
one HTTP request, such as inviting an attendee to an event). -->
- <string>loadtest.profiles.OperationLogger</string>
+ <string>contrib.performance.loadtest.profiles.OperationLogger</string>
</array>
</dict>
Modified: CalendarServer/trunk/contrib/performance/loadtest/ical.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/ical.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/ical.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -41,13 +41,14 @@
from caldavclientlibrary.protocol.caldav.definitions import caldavxml
from caldavclientlibrary.protocol.caldav.definitions import csxml
-from httpclient import StringProducer, readBody
-from httpauth import AuthHandlerAgent
+from calendarserver.tools.notifications import PubSubClientFactory
-from subscribe import Periodical
+from contrib.performance.httpclient import StringProducer, readBody
+from contrib.performance.httpauth import AuthHandlerAgent
-from calendarserver.tools.notifications import PubSubClientFactory
+from contrib.performance.loadtest.subscribe import Periodical
+
def loadRequestBody(label):
return FilePath(__file__).sibling('request-data').child(label + '.request').getContent()
Modified: CalendarServer/trunk/contrib/performance/loadtest/logger.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/logger.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/logger.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -1,5 +1,22 @@
-from stats import mean, median
+##
+# Copyright (c) 2011 Apple Inc. All rights reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+##
+from contrib.performance.stats import mean, median
+
class SummarizingMixin(object):
def printHeader(self, fields):
"""
Modified: CalendarServer/trunk/contrib/performance/loadtest/population.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/population.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/population.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -29,11 +29,11 @@
from twisted.python.util import FancyEqMixin
from twisted.python.log import msg, err
-from stats import mean, median, stddev, mad
-from loadtest.trafficlogger import loggedReactor
-from loadtest.logger import SummarizingMixin
-from loadtest.ical import SnowLeopard, RequestLogger
-from loadtest.profiles import Eventer, Inviter, Accepter
+from contrib.performance.stats import mean, median, stddev, mad
+from contrib.performance.loadtest.trafficlogger import loggedReactor
+from contrib.performance.loadtest.logger import SummarizingMixin
+from contrib.performance.loadtest.ical import SnowLeopard, RequestLogger
+from contrib.performance.loadtest.profiles import Eventer, Inviter, Accepter
class ProfileType(object, FancyEqMixin):
Modified: CalendarServer/trunk/contrib/performance/loadtest/profiles.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/profiles.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/profiles.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -39,9 +39,9 @@
from twisted.internet.task import LoopingCall
from twisted.web.http import PRECONDITION_FAILED
-from stats import NearFutureDistribution, NormalDistribution, UniformDiscreteDistribution, mean, median
-from loadtest.logger import SummarizingMixin
-from loadtest.ical import IncorrectResponseCode
+from contrib.performance.stats import NearFutureDistribution, NormalDistribution, UniformDiscreteDistribution, mean, median
+from contrib.performance.loadtest.logger import SummarizingMixin
+from contrib.performance.loadtest.ical import IncorrectResponseCode
class ProfileBase(object):
Modified: CalendarServer/trunk/contrib/performance/loadtest/sim.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/sim.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/sim.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -27,9 +27,9 @@
from twisted.python.usage import UsageError, Options
from twisted.python.reflect import namedAny
-from loadtest.ical import SnowLeopard
-from loadtest.profiles import Eventer, Inviter, Accepter
-from loadtest.population import (
+from contrib.performance.loadtest.ical import SnowLeopard
+from contrib.performance.loadtest.profiles import Eventer, Inviter, Accepter
+from contrib.performance.loadtest.population import (
Populator, ProfileType, ClientType, PopulationParameters, SmoothRampUp,
CalendarClientSimulator)
Modified: CalendarServer/trunk/contrib/performance/loadtest/test_ical.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/test_ical.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/test_ical.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -34,9 +34,9 @@
from caldavclientlibrary.protocol.caldav.definitions import caldavxml
from caldavclientlibrary.protocol.caldav.definitions import csxml
-from loadtest.ical import XMPPPush, Event, Calendar, SnowLeopard
-from loadtest.sim import _DirectoryRecord
-from httpclient import MemoryConsumer, StringProducer
+from contrib.performance.loadtest.ical import XMPPPush, Event, Calendar, SnowLeopard
+from contrib.performance.loadtest.sim import _DirectoryRecord
+from contrib.performance.httpclient import MemoryConsumer, StringProducer
EVENT_UID = 'D94F247D-7433-43AF-B84B-ADD684D023B0'
Modified: CalendarServer/trunk/contrib/performance/loadtest/test_population.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/test_population.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/test_population.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -21,7 +21,7 @@
from twisted.trial.unittest import TestCase
-from loadtest.population import ReportStatistics
+from contrib.performance.loadtest.population import ReportStatistics
class ReportStatisticsTests(TestCase):
"""
Modified: CalendarServer/trunk/contrib/performance/loadtest/test_profiles.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/test_profiles.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/test_profiles.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -31,10 +31,10 @@
from twisted.web.http import NO_CONTENT, PRECONDITION_FAILED
from twisted.web.client import Response
-from loadtest.profiles import Eventer, Inviter, Accepter, OperationLogger
-from loadtest.population import Populator, CalendarClientSimulator
-from loadtest.ical import IncorrectResponseCode, Calendar, Event, BaseClient
-from loadtest.sim import _DirectoryRecord
+from contrib.performance.loadtest.profiles import Eventer, Inviter, Accepter, OperationLogger
+from contrib.performance.loadtest.population import Populator, CalendarClientSimulator
+from contrib.performance.loadtest.ical import IncorrectResponseCode, Calendar, Event, BaseClient
+from contrib.performance.loadtest.sim import _DirectoryRecord
SIMPLE_EVENT = """\
BEGIN:VCALENDAR
Modified: CalendarServer/trunk/contrib/performance/loadtest/test_sim.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/test_sim.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/test_sim.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -25,19 +25,19 @@
from twistedcaldav.directory.directory import DirectoryRecord
-from stats import NormalDistribution
-from loadtest.ical import SnowLeopard
-from loadtest.profiles import Eventer, Inviter, Accepter
-from loadtest.population import (
+from contrib.performance.stats import NormalDistribution
+from contrib.performance.loadtest.ical import SnowLeopard
+from contrib.performance.loadtest.profiles import Eventer, Inviter, Accepter
+from contrib.performance.loadtest.population import (
SmoothRampUp, ClientType, PopulationParameters, Populator, CalendarClientSimulator,
ProfileType, SimpleStatistics)
-from loadtest.sim import (
+from contrib.performance.loadtest.sim import (
Arrival, SimOptions, LoadSimulator, LagTrackingReactor)
VALID_CONFIG = {
'server': 'tcp:127.0.0.1:8008',
'arrival': {
- 'factory': 'loadtest.population.SmoothRampUp',
+ 'factory': 'contrib.performance.loadtest.population.SmoothRampUp',
'params': {
'groups': 10,
'groupSize': 1,
@@ -254,7 +254,7 @@
accounts.setContent("foo,bar,baz,quux\nfoo2,bar2,baz2,quux2\n")
config = VALID_CONFIG.copy()
config["accounts"] = {
- "loader": "loadtest.sim.recordsFromCSVFile",
+ "loader": "contrib.performance.loadtest.sim.recordsFromCSVFile",
"params": {
"path": accounts.path},
}
@@ -280,7 +280,7 @@
"""
config = VALID_CONFIG.copy()
config["accounts"] = {
- "loader": "loadtest.sim.recordsFromCSVFile",
+ "loader": "contrib.performance.loadtest.sim.recordsFromCSVFile",
"params": {
"path": ""},
}
@@ -305,7 +305,7 @@
"""
config = VALID_CONFIG.copy()
config["accounts"] = {
- "loader": "loadtest.sim.generateRecords",
+ "loader": "contrib.performance.loadtest.sim.generateRecords",
"params": {
"count": 2
},
@@ -331,7 +331,7 @@
"""
config = VALID_CONFIG.copy()
config["accounts"] = {
- "loader": "loadtest.sim.generateRecords",
+ "loader": "contrib.performance.loadtest.sim.generateRecords",
"params": {
"count": 3,
"uidPattern": "USER%03d",
@@ -384,7 +384,7 @@
config = FilePath(self.mktemp())
config.setContent(writePlistToString({
"arrival": {
- "factory": "loadtest.population.SmoothRampUp",
+ "factory": "contrib.performance.loadtest.population.SmoothRampUp",
"params": {
"groups": 10,
"groupSize": 1,
@@ -427,18 +427,18 @@
config = FilePath(self.mktemp())
config.setContent(writePlistToString({
"clients": [{
- "software": "loadtest.ical.SnowLeopard",
+ "software": "contrib.performance.loadtest.ical.SnowLeopard",
"params": {"foo": "bar"},
"profiles": [{
"params": {
"interval": 25,
"eventStartDistribution": {
- "type": "stats.NormalDistribution",
+ "type": "contrib.performance.stats.NormalDistribution",
"params": {
"mu": 123,
"sigma": 456,
}}},
- "class": "loadtest.profiles.Eventer"}],
+ "class": "contrib.performance.loadtest.profiles.Eventer"}],
"weight": 3,
}]}))
@@ -473,7 +473,7 @@
"""
config = FilePath(self.mktemp())
config.setContent(writePlistToString({
- "observers": ["loadtest.population.SimpleStatistics"]}))
+ "observers": ["contrib.performance.loadtest.population.SimpleStatistics"]}))
sim = LoadSimulator.fromCommandLine(['--config', config.path])
self.assertEquals(len(sim.observers), 1)
self.assertIsInstance(sim.observers[0], SimpleStatistics)
Modified: CalendarServer/trunk/contrib/performance/loadtest/test_trafficlogger.py
===================================================================
--- CalendarServer/trunk/contrib/performance/loadtest/test_trafficlogger.py 2011-07-14 20:09:05 UTC (rev 7795)
+++ CalendarServer/trunk/contrib/performance/loadtest/test_trafficlogger.py 2011-07-14 20:59:08 UTC (rev 7796)
@@ -22,7 +22,7 @@
from twisted.test.proto_helpers import StringTransport, MemoryReactor
from twisted.protocols.wire import Discard
-from loadtest.trafficlogger import _TrafficLoggingFactory, loggedReactor
+from contrib.performance.loadtest.trafficlogger import _TrafficLoggingFactory, loggedReactor
class IProbe(Interface):
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20110714/38c0fae3/attachment-0001.html>
More information about the calendarserver-changes
mailing list