Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2005-05-05 12:32:44 -0400
committerMichael Valenta2005-05-05 12:32:44 -0400
commit0d27ae126bb1543febd890a7340709cfdaf50a34 (patch)
tree4862317dac5b754a6b6f76ce8e21ff990b3c1e49
parentdfd24417e85d7a035bb3465c94255f608ff6060f (diff)
downloadeclipse.platform.team-0d27ae126bb1543febd890a7340709cfdaf50a34.tar.gz
eclipse.platform.team-0d27ae126bb1543febd890a7340709cfdaf50a34.tar.xz
eclipse.platform.team-0d27ae126bb1543febd890a7340709cfdaf50a34.zip
Releasing code to serialize CVS server access
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/launchConfigurations/CVS UI Tests.launch41
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/launchConfigurations/Performance - SyncTests.launch4
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/performance.txt439
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/EclipseTest.java164
-rw-r--r--tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/ui/benchmark/BenchmarkTestSetup.java2
5 files changed, 479 insertions, 171 deletions
diff --git a/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/CVS UI Tests.launch b/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/CVS UI Tests.launch
index ec3eeea25..75be4ce03 100644
--- a/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/CVS UI Tests.launch
+++ b/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/CVS UI Tests.launch
@@ -1,16 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<launchConfiguration type="org.eclipse.pde.ui.JunitLaunchConfig">
-<booleanAttribute key="clearws" value="true"/>
+<stringAttribute key="product" value="org.eclipse.platform.ide"/>
<stringAttribute key="bootstrap" value=""/>
-<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.team.tests.ccvs.core.AllTests"/>
+<booleanAttribute key="useProduct" value="false"/>
<booleanAttribute key="tracing" value="false"/>
-<stringAttribute key="location1" value="C:\Eclipse\Latest-Eclipse-Drop\eclipse\runtime-test-workspace"/>
<listAttribute key="org.eclipse.debug.ui.favoriteGroups">
<listEntry value="org.eclipse.debug.ui.launchGroup.debug"/>
</listAttribute>
-<stringAttribute key="vmargs" value="-Declipse.cvs.properties=c:\eclipse\repository.properties -Declipse.cvs.testName2=testFileAdditions"/>
-<booleanAttribute key="default" value="true"/>
-<booleanAttribute key="clearConfig" value="true"/>
<stringAttribute key="org.eclipse.jdt.junit.CONTAINER" value=""/>
<mapAttribute key="tracingOptions">
<mapEntry key="org.eclipse.core.boot/monitor/classes" value="false"/>
@@ -59,19 +55,19 @@
<mapEntry key="org.eclipse.help.ui/debug/ieadapter/inprocess" value="false"/>
<mapEntry key="org.eclipse.jface/trace/actions" value="false"/>
<mapEntry key="org.eclipse.core.runtime/registry/debug/events/extension" value="false"/>
-<mapEntry key="org.eclipse.jdt.core/debug/hierarchy" value="false"/>
<mapEntry key="org.eclipse.help.webapp/debug" value="true"/>
+<mapEntry key="org.eclipse.jdt.core/debug/hierarchy" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/debug" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/cpresolution" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/threading" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/warning" value="false"/>
<mapEntry key="org.eclipse.core.resources/save" value="false"/>
-<mapEntry key="org.eclipse.update.core/debug/install" value="false"/>
<mapEntry key="org.eclipse.ui/debug/internalerror/openDialog" value="false"/>
+<mapEntry key="org.eclipse.update.core/debug/install" value="false"/>
<mapEntry key="org.eclipse.core.resources/debug" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/parsing" value="false"/>
-<mapEntry key="org.eclipse.core.resources/restore/syncinfo" value="false"/>
<mapEntry key="org.eclipse.core.boot/trace/filters" value="trace.properties"/>
+<mapEntry key="org.eclipse.core.resources/restore/syncinfo" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/cvsprotocol" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/postaction" value="false"/>
<mapEntry key="org.eclipse.core.runtime/url/debug/cachelookup" value="false"/>
@@ -81,15 +77,15 @@
<mapEntry key="org.eclipse.core.resources/save/syncinfo" value="false"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/filter/resource" value="*"/>
<mapEntry key="org.eclipse.team.ftp/list" value="true"/>
-<mapEntry key="org.eclipse.core.runtime/loader/debug/activateplugin" value="false"/>
<mapEntry key="org.eclipse.team.cvs.ssh/debug" value="false"/>
+<mapEntry key="org.eclipse.core.runtime/loader/debug/activateplugin" value="false"/>
<mapEntry key="org.eclipse.core.resources/monitor/builders" value="false"/>
<mapEntry key="org.eclipse.core.resources/save/markers" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/installhandler" value="false"/>
-<mapEntry key="org.eclipse.jdt.core/debug/javadelta" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/selection" value="false"/>
-<mapEntry key="org.eclipse.core.resources/restore/tree" value="false"/>
+<mapEntry key="org.eclipse.jdt.core/debug/javadelta" value="false"/>
<mapEntry key="org.eclipse.ui/trace/workbench.restore" value="false"/>
+<mapEntry key="org.eclipse.core.resources/restore/tree" value="false"/>
<mapEntry key="org.eclipse.ui/trace/part.create" value="false"/>
<mapEntry key="org.eclipse.help/debug/protocols" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore/snapshots" value="false"/>
@@ -97,13 +93,13 @@
<mapEntry key="org.eclipse.team.cvs.core/dirtycaching" value="false"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/filter/native" value="*"/>
<mapEntry key="org.eclipse.jdt.core/debug/zipaccess" value="false"/>
-<mapEntry key="org.eclipse.core.runtime/url/debug/cachecopy" value="false"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/properties" value="false"/>
+<mapEntry key="org.eclipse.core.runtime/url/debug/cachecopy" value="false"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/create" value="false"/>
<mapEntry key="org.eclipse.core.runtime/jobs/beginend" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/metafiles" value="false"/>
-<mapEntry key="org.eclipse.team.ftp/responses" value="true"/>
<mapEntry key="org.eclipse.team.core/debug" value="false"/>
+<mapEntry key="org.eclipse.team.ftp/responses" value="true"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/prefixes/success" value="false"/>
<mapEntry key="org.eclipse.core.runtime/jobs" value="false"/>
<mapEntry key="org.eclipse.core.boot/monitor/plugins" value="false"/>
@@ -129,8 +125,8 @@
<mapEntry key="org.eclipse.core.runtime/config/debug" value="false"/>
<mapEntry key="org.eclipse.help.ui/debug" value="true"/>
<mapEntry key="org.eclipse.core.resources/restore/metainfo" value="false"/>
-<mapEntry key="org.eclipse.core.resources/save/mastertable" value="false"/>
<mapEntry key="org.eclipse.debug.ui/debug" value="true"/>
+<mapEntry key="org.eclipse.core.resources/save/mastertable" value="false"/>
<mapEntry key="org.eclipse.jdt.debug/debug" value="true"/>
<mapEntry key="org.eclipse.core.runtime/debug" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/buffermanager" value="false"/>
@@ -142,15 +138,26 @@
<mapEntry key="org.eclipse.core.runtime/jobs/timing" value="false"/>
<mapEntry key="org.eclipse.core.runtime/loader/debug/prefixes/failure" value="false"/>
</mapAttribute>
+<booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
+<booleanAttribute key="automaticAdd" value="true"/>
+<booleanAttribute key="includeFragments" value="false"/>
+<booleanAttribute key="clearws" value="true"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.team.tests.ccvs.core.AllTests"/>
+<stringAttribute key="location1" value="C:\Eclipse\Latest-Eclipse-Drop\eclipse\runtime-test-workspace"/>
+<stringAttribute key="vmargs" value="-Declipse.cvs.properties=c:\eclipse\repository.properties -Declipse.cvs.testName2=testFileAdditions"/>
+<booleanAttribute key="default" value="true"/>
+<booleanAttribute key="clearConfig" value="true"/>
<booleanAttribute key="org.eclipse.debug.core.appendEnvironmentVariables" value="true"/>
+<booleanAttribute key="useDefaultConfigArea" value="true"/>
<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.pde.ui.workbenchClasspathProvider"/>
-<booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
<stringAttribute key="onePluginID" value=""/>
-<booleanAttribute key="useDefaultConfig" value="true"/>
<stringAttribute key="progargs" value="-os win32 -ws win32 -arch x86 -nl en_CA"/>
+<booleanAttribute key="useDefaultConfig" value="true"/>
+<stringAttribute key="org.eclipse.jdt.junit.TESTNAME" value=""/>
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.eclipse.team.tests.cvs.core"/>
<booleanAttribute key="askclear" value="false"/>
<booleanAttribute key="onePlugin" value="false"/>
+<booleanAttribute key="includeOptional" value="true"/>
<booleanAttribute key="maximized" value="false"/>
<stringAttribute key="location0" value="C:\Eclipse\Latest-Eclipse-Drop\eclipse\runtime-test-workspace"/>
</launchConfiguration>
diff --git a/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/Performance - SyncTests.launch b/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/Performance - SyncTests.launch
index 89575ba31..8e0cb6cba 100644
--- a/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/Performance - SyncTests.launch
+++ b/tests/org.eclipse.team.tests.cvs.core/launchConfigurations/Performance - SyncTests.launch
@@ -10,7 +10,7 @@
<stringAttribute key="checked" value="[NONE]"/>
<booleanAttribute key="includeFragments" value="false"/>
<booleanAttribute key="clearws" value="true"/>
-<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.team.tests.ccvs.ui.benchmark.SyncTests"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests"/>
<stringAttribute key="location1" value="C:\Eclipse\Latest\eclipse-0924\runtime-test-workspace"/>
<booleanAttribute key="default" value="true"/>
<stringAttribute key="vmargs" value="-Declipse.cvs.properties=c:\eclipse\repository.properties -DInternalPrintPerformanceResults"/>
@@ -24,5 +24,5 @@
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.eclipse.team.tests.cvs.core"/>
<booleanAttribute key="askclear" value="false"/>
<booleanAttribute key="includeOptional" value="true"/>
-<stringAttribute key="location0" value="C:\Eclipse\Latest\eclipse-0924\runtime-test-workspace"/>
+<stringAttribute key="location0" value="C:\Eclipse\Latest\eclipse-30\runtime-test-workspace"/>
</launchConfiguration>
diff --git a/tests/org.eclipse.team.tests.cvs.core/performance.txt b/tests/org.eclipse.team.tests.cvs.core/performance.txt
index f64c2e66c..08845568d 100644
--- a/tests/org.eclipse.team.tests.cvs.core/performance.txt
+++ b/tests/org.eclipse.team.tests.cvs.core/performance.txt
@@ -1,168 +1,311 @@
-Connecting to: fiji:extssh
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update4' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 3.6 s
- Working Set Peak: 0
- Working Set: 25K
- Used Java Heap: 1.34M
- Committed: -40960
- Elapsed Process: 8.64 s
- Kernel time: 510 ms
- Page Faults: 185
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace3' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 2.6 s
- Working Set Peak: 0
- Working Set: 56K
- Used Java Heap: 5.29M
- Committed: 1.6M
- Elapsed Process: 3.82 s
- Kernel time: 552 ms
- Page Faults: 271
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Share' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 21.97 s
- Working Set Peak: 6.39M
- Working Set: 4.64M
- Used Java Heap: 3.85M
- Committed: 4.23M
- Elapsed Process: 35.77 s
- Kernel time: 5.54 s
- Page Faults: 106K
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit2' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 1.74 s
- Working Set Peak: 25K
- Working Set: 45K
- Used Java Heap: -6227077
- Committed: 53K
- Elapsed Process: 4.11 s
- Kernel time: 62 ms
- Page Faults: 255
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update3' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 3.29 s
- Working Set Peak: 0
- Working Set: 44K
- Used Java Heap: 3.49M
- Committed: -1365
- Elapsed Process: 8.22 s
- Kernel time: 177 ms
- Page Faults: 301
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace2' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 3.44 s
- Working Set Peak: 0
- Working Set: -648533
- Used Java Heap: 9.01M
- Committed: -1660245
- Elapsed Process: 7.75 s
- Kernel time: 578 ms
- Page Faults: 149
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit3' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 2.41 s
- Working Set Peak: 0
- Working Set: 25K
- Used Java Heap: -591608
- Committed: -30037
- Elapsed Process: 6.2 s
- Kernel time: 344 ms
+Connecting to: wsmvalentalnx:pserver
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update4' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -3141652
+ Committed: 12K
+ Kernel time: 2.43 s
+ Working Set: -85196
+ Page Faults: 257
+ CPU Time: 6.01 s
+ Elapsed Process: 9.07 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -1058664
+ Committed: -72908
+ Kernel time: 2.31 s
+ Working Set: -94208
+ Page Faults: 130
+ CPU Time: 4.93 s
+ Elapsed Process: 6.08 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Share' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 4.38M
+ Used Java Heap: 7.14M
+ Committed: 7.9M
+ Kernel time: 5.1 s
+ Working Set: 7.21M
+ Page Faults: 102K
+ CPU Time: 18.31 s
+ Elapsed Process: 26.7 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit2' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 5.66M
+ Committed: -47513
+ Kernel time: 56 ms
+ Working Set: -2457
+ Page Faults: 42
+ CPU Time: 1.69 s
+ Elapsed Process: 3.4 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -2819814
+ Committed: 56K
+ Kernel time: 1.98 s
+ Working Set: 72K
+ Page Faults: 196
+ CPU Time: 5.29 s
+ Elapsed Process: 8.18 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace2' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 7.08M
+ Committed: 82K
+ Kernel time: 2.46 s
+ Working Set: 42K
+ Page Faults: 297
+ CPU Time: 5.6 s
+ Elapsed Process: 6.55 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 4.34M
+ Committed: 26K
+ Kernel time: 309 ms
+ Working Set: -6553
Page Faults: 1K
+ CPU Time: 2.12 s
+ Elapsed Process: 5.29 s
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update2' (average over 3 samples):
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update2' (average over 5 samples):
GDI Objects: 0
- CPU Time: 2.48 s
Working Set Peak: 0
- Working Set: -281258
- Used Java Heap: 5.19M
- Committed: -315392
- Elapsed Process: 6.7 s
- Kernel time: 98 ms
- Page Faults: 36
+ Used Java Heap: -3165134
+ Committed: 30K
+ Kernel time: 1.95 s
+ Working Set: 39K
+ Page Faults: 202
+ CPU Time: 5.12 s
+ Elapsed Process: 7.56 s
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit4' (average over 3 samples):
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit4' (average over 5 samples):
GDI Objects: 0
- CPU Time: 3.33 s
Working Set Peak: 0
- Working Set: -401408
- Used Java Heap: 1.58M
- Committed: -218453
- Elapsed Process: 7.47 s
- Kernel time: 614 ms
+ Used Java Heap: 2.12M
+ Committed: -783155
+ Kernel time: 597 ms
+ Working Set: -799539
Page Faults: 2K
+ CPU Time: 3.01 s
+ Elapsed Process: 6.38 s
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Checkout' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 13.39 s
- Working Set Peak: 56K
- Working Set: 321K
- Used Java Heap: 3.2M
- Committed: 5K
- Elapsed Process: 22.43 s
- Kernel time: 5.38 s
- Page Faults: 8K
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update1' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 3.94 s
- Working Set Peak: 784K
- Working Set: 217K
- Used Java Heap: 4.39M
- Committed: -79189
- Elapsed Process: 8.08 s
- Kernel time: 224 ms
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Checkout' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 1.11M
+ Used Java Heap: -6433462
+ Committed: 2.46M
+ Kernel time: 5.25 s
+ Working Set: 1.44M
+ Page Faults: 7K
+ CPU Time: 12.53 s
+ Elapsed Process: 19.54 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Update1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 687K
+ Used Java Heap: -7446966
+ Committed: -855244
+ Kernel time: 2.08 s
+ Working Set: -742195
Page Faults: 1K
+ CPU Time: 6.18 s
+ Elapsed Process: 9.84 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -4083076
+ Committed: 29K
+ Kernel time: 1.88 s
+ Working Set: 30K
+ Page Faults: 105
+ CPU Time: 4.7 s
+ Elapsed Process: 5.28 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Tag1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -5506099
+ Committed: -6553
+ Kernel time: 18 ms
+ Working Set: 4K
+ Page Faults: 19
+ CPU Time: 625 ms
+ Elapsed Process: 1.31 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit1' (average over 5 samples):
+ GDI Objects: 11
+ Working Set Peak: 2.41M
+ Used Java Heap: 5.64M
+ Committed: 1.12M
+ Kernel time: 284 ms
+ Working Set: 954K
+ Page Faults: 2K
+ CPU Time: 5.2 s
+ Elapsed Process: 7.14 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Update4' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 3.16M
+ Committed: 121K
+ Kernel time: 2.4 s
+ Working Set: 4K
+ Page Faults: 78
+ CPU Time: 5.99 s
+ Elapsed Process: 8.38 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Replace3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 45K
+ Committed: -13926
+ Kernel time: 2.4 s
+ Working Set: -3276
+ Page Faults: 75
+ CPU Time: 5.19 s
+ Elapsed Process: 6.31 s
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Replace1' (average over 3 samples):
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Share' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 1.53M
+ Used Java Heap: 12.67M
+ Committed: 4.14M
+ Kernel time: 5.03 s
+ Working Set: 3.15M
+ Page Faults: 86K
+ CPU Time: 17.43 s
+ Elapsed Process: 24.75 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Commit2' (average over 5 samples):
GDI Objects: 0
- CPU Time: 1.95 s
Working Set Peak: 0
+ Used Java Heap: 2.87M
+ Committed: 41K
+ Kernel time: 52 ms
+ Working Set: 5K
+ Page Faults: 15
+ CPU Time: 1.43 s
+ Elapsed Process: 4.78 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Update3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 1.03M
+ Committed: -50790
+ Kernel time: 2.1 s
Working Set: 8K
- Used Java Heap: -3417498
- Committed: 37K
- Elapsed Process: 3.51 s
- Kernel time: 83 ms
- Page Faults: 27
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Tag1' (average over 3 samples):
- GDI Objects: 0
- CPU Time: 921 ms
- Working Set Peak: 0
- Working Set: 24K
- Used Java Heap: -5212554
- Committed: 1,002K
- Elapsed Process: 3.06 s
- Kernel time: 98 ms
- Page Faults: 31
-
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflow()Commit1' (average over 3 samples):
- GDI Objects: 18
- CPU Time: 6.11 s
- Working Set Peak: 1.85M
- Working Set: 4.65M
- Used Java Heap: -1832648
- Committed: 3.88M
- Elapsed Process: 7.64 s
- Kernel time: 359 ms
+ Page Faults: 85
+ CPU Time: 5.62 s
+ Elapsed Process: 7.4 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Replace2' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -510673
+ Committed: 118K
+ Kernel time: 2.42 s
+ Working Set: -4096
+ Page Faults: 128
+ CPU Time: 5.4 s
+ Elapsed Process: 6.43 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Commit3' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 499K
+ Committed: -289996
+ Kernel time: 322 ms
+ Working Set: -284262
+ Page Faults: 1K
+ CPU Time: 2.06 s
+ Elapsed Process: 4.16 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Update2' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 2.87M
+ Committed: -12288
+ Kernel time: 1.99 s
+ Working Set: -4096
+ Page Faults: 15
+ CPU Time: 5.36 s
+ Elapsed Process: 7.04 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Commit4' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -11205686
+ Committed: -11468
+ Kernel time: 612 ms
+ Working Set: 7K
+ Page Faults: 2K
+ CPU Time: 2.72 s
+ Elapsed Process: 4.95 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Checkout' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -130521
+ Committed: 648K
+ Kernel time: 5.23 s
+ Working Set: -296550
Page Faults: 5K
+ CPU Time: 11.53 s
+ Elapsed Process: 16.37 s
-Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowForSummary()' (average over 42 samples):
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Update1' (average over 5 samples):
GDI Objects: 0
- CPU Time: 4.7 s
- Working Set Peak: 49K
- Working Set: 161K
- Used Java Heap: 139K
- Committed: 110K
- Elapsed Process: 9.63 s
- Kernel time: 1.08 s
- Page Faults: 7K
+ Working Set Peak: 0
+ Used Java Heap: -3274598
+ Committed: 135K
+ Kernel time: 2.22 s
+ Working Set: 22K
+ Page Faults: 51
+ CPU Time: 5.95 s
+ Elapsed Process: 8.78 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Replace1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: -6445904
+ Committed: 6K
+ Kernel time: 2.03 s
+ Working Set: 0
+ Page Faults: 11
+ CPU Time: 4.48 s
+ Elapsed Process: 5 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Tag1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 0
+ Used Java Heap: 6.63M
+ Committed: 81K
+ Kernel time: 25 ms
+ Working Set: 1K
+ Page Faults: 10
+ CPU Time: 659 ms
+ Elapsed Process: 1.16 s
+
+Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.WorkflowTests#testBigWorkflowNoUI()Commit1' (average over 5 samples):
+ GDI Objects: 0
+ Working Set Peak: 8K
+ Used Java Heap: -531385
+ Committed: -1733427
+ Kernel time: 215 ms
+ Working Set: -1124761
+ Page Faults: 1K
+ CPU Time: 4.5 s
+ Elapsed Process: 9.51 s
Connecting to: fiji:extssh
Scenario 'org.eclipse.team.tests.ccvs.ui.benchmark.SyncTests#testSync10()RemovedFiles' (average over 3 samples):
diff --git a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/EclipseTest.java b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/EclipseTest.java
index 12d4b2224..34ee1e8a0 100644
--- a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/EclipseTest.java
+++ b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/core/EclipseTest.java
@@ -36,9 +36,15 @@ import org.eclipse.ui.IWorkbenchPart;
public class EclipseTest extends EclipseWorkspaceTest {
- protected static IProgressMonitor DEFAULT_MONITOR = new NullProgressMonitor();
+ private static final int LOCK_WAIT_TIME = 1000;
+ private static final String CVS_TEST_LOCK_FILE = ".lock";
+ private static final String CVS_TEST_LOCK_PROJECT = "cvsTestLock";
+ protected static IProgressMonitor DEFAULT_MONITOR = new NullProgressMonitor();
protected static final int RANDOM_CONTENT_SIZE = 3876;
protected static String eol = System.getProperty("line.separator");
+ private static final long LOCK_EXPIRATION_THRESHOLD = 1000 * 60 * 10; // 10 minutes
+ private static final int MAX_LOCK_ATTEMPTS = 60 * 30; // 30 minutes
+ private String lockId;
public static Test suite(Class c) {
String testName = System.getProperty("eclipse.cvs.testName");
@@ -842,10 +848,17 @@ public class EclipseTest extends EclipseWorkspaceTest {
throw new OperationCanceledException();
}
}
- /* (non-Javadoc)
+
+ protected void setUp() throws Exception {
+ obtainCVSServerLock();
+ super.setUp();
+ }
+
+ /* (non-Javadoc)
* @see junit.framework.TestCase#tearDown()
*/
protected void tearDown() throws Exception {
+ releaseCVSServerLock();
super.tearDown();
if (CVSTestSetup.logListener != null) {
try {
@@ -860,8 +873,153 @@ public class EclipseTest extends EclipseWorkspaceTest {
}
}
}
+
+ private void obtainCVSServerLock() {
+ IProject project = null;
+ boolean firstTry = true;
+ while (project == null) {
+ try {
+ project = checkoutProject(null, CVS_TEST_LOCK_PROJECT , null);
+ } catch (TeamException e) {
+ // The checkout of the lock project failed so lets create it if it doesn't exist
+ if (firstTry) {
+ try {
+ createTestLockProject(DEFAULT_MONITOR);
+ } catch (TeamException e1) {
+ // We couldn't check out the project or create it
+ // It's possible someone beat us to it so we'll try the checkout again.
+ }
+ } else {
+ // We tried twice to check out the project and failed.
+ // Lets just go ahead and run but we'll log the fact that we couldn't get the lock
+ write(new CVSStatus(IStatus.ERROR, "Could not obtain the CVS server lock. The test will containue but any performance timings may be affected", e), 0);
+ return;
+ }
+ firstTry = false;
+ }
+ }
+ if (project != null) {
+ IFile lockFile = project.getFile(CVS_TEST_LOCK_FILE);
+ boolean obtained = false;
+ int attempts = 0;
+ while (!obtained) {
+ attempts++;
+ if (lockFile.exists()) {
+ // If the file exists, check if the lock has expired
+ if (hasExpired(lockFile)) {
+ try {
+ overwriteLock(lockFile);
+ return;
+ } catch (CoreException e) {
+ // Ignore the error and continue
+ }
+ }
+ } else {
+ try {
+ writeLock(lockFile);
+ return;
+ } catch (CoreException e) {
+ // Ignore the error, since it probably means someone beat us to it.
+ }
+ }
+ // Wait for a while before testing the lock again
+ try {
+ Thread.sleep(LOCK_WAIT_TIME);
+ } catch (InterruptedException e) {
+ // Ignore
+ }
+ try {
+ // Update the lockfile in case someone else got to it first
+ replace(new IResource[] { lockFile }, null, true);
+ } catch (CoreException e) {
+ // An error updated is not recoverable so just continue
+ write(new CVSStatus(IStatus.ERROR, "Could not obtain the CVS server lock. The test will continue but any performance timings may be affected", e), 0);
+ return;
+ }
+ if (attempts > MAX_LOCK_ATTEMPTS) {
+ write(new CVSStatus(IStatus.ERROR, "Could not obtain the CVS server lock. The test will continue but any performance timings may be affected", new Exception()), 0);
+ return;
+ }
+ }
+ }
+ }
+
+ private boolean hasExpired(IFile lockFile) {
+ long timestamp = lockFile.getLocalTimeStamp();
+ return System.currentTimeMillis() - timestamp > LOCK_EXPIRATION_THRESHOLD;
+ }
+
+ private void overwriteLock(IFile lockFile) throws CoreException {
+ lockFile.setContents(getLockContents(), true, true, null);
+ commitResources(new IResource[] { lockFile }, IResource.DEPTH_ZERO);
+ }
+
+ private void writeLock(IFile lockFile) throws CoreException {
+ lockFile.create(getLockContents(), false, null);
+ addResources(new IResource[] { lockFile });
+ commitResources(new IResource[] { lockFile }, IResource.DEPTH_ZERO);
+ }
+
+ private InputStream getLockContents() {
+ lockId = Long.toString(System.currentTimeMillis());
+ return new ByteArrayInputStream(lockId.getBytes());
+ }
+
+ private void createTestLockProject(IProgressMonitor monitor) throws TeamException {
+ CVSRepositoryLocation repository = getRepository();
+ RemoteFolderTree root = new RemoteFolderTree(null, repository, Path.EMPTY.toString(), null);
+ RemoteFolderTree child = new RemoteFolderTree(root, CVS_TEST_LOCK_PROJECT, repository, new Path(null, root.getRepositoryRelativePath()).append(CVS_TEST_LOCK_PROJECT).toString(), null);
+ root.setChildren(new ICVSRemoteResource[] { child });
+ Session s = new Session(repository, root);
+ s.open(monitor, true /* open for modification */);
+ try {
+ IStatus status = Command.ADD.execute(s,
+ Command.NO_GLOBAL_OPTIONS,
+ Command.NO_LOCAL_OPTIONS,
+ new String[] { CVS_TEST_LOCK_PROJECT },
+ null,
+ monitor);
+ // If we get a warning, the operation most likely failed so check that the status is OK
+ if (status.getCode() == CVSStatus.SERVER_ERROR || ! status.isOK()) {
+ throw new CVSServerException(status);
+ }
+ } finally {
+ s.close();
+ }
+ }
+
+ private void releaseCVSServerLock() {
+ if (lockId != null) {
+ try {
+ IProject project = getWorkspace().getRoot().getProject(CVS_TEST_LOCK_PROJECT);
+ // Update the project and verify we still have the lock
+ IFile file = project.getFile(CVS_TEST_LOCK_FILE);
+ String id = getFileContents(file);
+ if (id.equals(lockId)) {
+ // We have the lock so let's free it (but first check if someone preempted us)
+ ICVSFile cvsFile = CVSWorkspaceRoot.getCVSFileFor(file);
+ byte[] bytes = cvsFile.getSyncBytes();
+ if (bytes != null) {
+ String revision = ResourceSyncInfo.getRevision(bytes);
+ updateResources(new IResource[] { file }, true);
+ bytes = cvsFile.getSyncBytes();
+ if (bytes == null || !ResourceSyncInfo.getRevision(bytes).equals(revision)) {
+ write(new CVSStatus(IStatus.ERROR, "The CVS server lock expired while this test was running. Any performance timings may be affected", new Exception()), 0);
+ return;
+ }
+ }
+ // Delete the lock file and commit
+ deleteResources(project, new String[] { CVS_TEST_LOCK_FILE }, true);
+ }
+ } catch (CoreException e) {
+ write(e.getStatus(), 0);
+ } catch (IOException e) {
+ write(new CVSStatus(IStatus.ERROR, "An error occurred while reading the lock file", e), 0);
+ }
+ }
+ }
- protected void write(IStatus status, int indent) {
+ protected void write(IStatus status, int indent) {
PrintStream output = System.out;
indent(output, indent);
output.println("Severity: " + status.getSeverity());
diff --git a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/ui/benchmark/BenchmarkTestSetup.java b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/ui/benchmark/BenchmarkTestSetup.java
index 700ccc35a..5acad0b38 100644
--- a/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/ui/benchmark/BenchmarkTestSetup.java
+++ b/tests/org.eclipse.team.tests.cvs.core/src/org/eclipse/team/tests/ccvs/ui/benchmark/BenchmarkTestSetup.java
@@ -30,7 +30,7 @@ public class BenchmarkTestSetup extends CVSTestSetup {
// Static initializer for constants
static {
try {
- LOOP_COUNT = Integer.valueOf(System.getProperty("eclipse.cvs.loopCount", "3")).intValue();
+ LOOP_COUNT = Integer.valueOf(System.getProperty("eclipse.cvs.loopCount", "5")).intValue();
} catch (NumberFormatException e1) {
LOOP_COUNT = 1;
}

Back to the top