Skip to content

Commit 055f17f

Browse files
committed
More users
1 parent bb5eca3 commit 055f17f

File tree

2 files changed

+11
-22
lines changed

2 files changed

+11
-22
lines changed

LoadTestingScript.jmx

+8-19
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,40 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<jmeterTestPlan version="1.2" properties="5.0" jmeter="5.5">
2+
<jmeterTestPlan version="1.2" properties="5.0" jmeter="5.6">
33
<hashTree>
44
<TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="Test Plan" enabled="true">
55
<stringProp name="TestPlan.comments"></stringProp>
6-
<boolProp name="TestPlan.functional_mode">false</boolProp>
76
<boolProp name="TestPlan.tearDown_on_shutdown">true</boolProp>
8-
<boolProp name="TestPlan.serialize_threadgroups">false</boolProp>
97
<elementProp name="TestPlan.user_defined_variables" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
108
<collectionProp name="Arguments.arguments"/>
119
</elementProp>
1210
<stringProp name="TestPlan.user_define_classpath"></stringProp>
1311
</TestPlan>
1412
<hashTree>
15-
<ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="Thread Group" enabled="true">
16-
<stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
17-
<elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
18-
<boolProp name="LoopController.continue_forever">false</boolProp>
13+
<ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="Thread Group">
14+
<elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller">
1915
<stringProp name="LoopController.loops">1</stringProp>
2016
</elementProp>
21-
<stringProp name="ThreadGroup.num_threads">100</stringProp>
17+
<stringProp name="ThreadGroup.num_threads">10000</stringProp>
2218
<stringProp name="ThreadGroup.ramp_time">1</stringProp>
2319
<boolProp name="ThreadGroup.scheduler">false</boolProp>
2420
<stringProp name="ThreadGroup.duration"></stringProp>
2521
<stringProp name="ThreadGroup.delay"></stringProp>
2622
<boolProp name="ThreadGroup.same_user_on_next_iteration">false</boolProp>
2723
</ThreadGroup>
2824
<hashTree>
29-
<HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="WebApp" enabled="true">
30-
<elementProp name="HTTPsampler.Arguments" elementType="Arguments" guiclass="HTTPArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
25+
<HTTPSamplerProxy guiclass="HttpTestSampleGui" testclass="HTTPSamplerProxy" testname="WebApp">
26+
<elementProp name="HTTPsampler.Arguments" elementType="Arguments" guiclass="HTTPArgumentsPanel" testclass="Arguments" testname="User Defined Variables">
3127
<collectionProp name="Arguments.arguments"/>
3228
</elementProp>
3329
<stringProp name="HTTPSampler.domain">loadtestingweb.azurewebsites.net</stringProp>
3430
<stringProp name="HTTPSampler.port">443</stringProp>
3531
<stringProp name="HTTPSampler.protocol">https</stringProp>
36-
<stringProp name="HTTPSampler.contentEncoding"></stringProp>
37-
<stringProp name="HTTPSampler.path"></stringProp>
3832
<stringProp name="HTTPSampler.method">GET</stringProp>
3933
<boolProp name="HTTPSampler.follow_redirects">true</boolProp>
40-
<boolProp name="HTTPSampler.auto_redirects">false</boolProp>
4134
<boolProp name="HTTPSampler.use_keepalive">true</boolProp>
42-
<boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
43-
<stringProp name="HTTPSampler.embedded_url_re"></stringProp>
44-
<stringProp name="HTTPSampler.connect_timeout"></stringProp>
45-
<stringProp name="HTTPSampler.response_timeout"></stringProp>
4635
</HTTPSamplerProxy>
4736
<hashTree/>
48-
<ResultCollector guiclass="ViewResultsFullVisualizer" testclass="ResultCollector" testname="View Results Tree" enabled="true">
37+
<ResultCollector guiclass="ViewResultsFullVisualizer" testclass="ResultCollector" testname="View Results Tree">
4938
<boolProp name="ResultCollector.error_logging">false</boolProp>
5039
<objProp>
5140
<name>saveConfig</name>
@@ -85,4 +74,4 @@
8574
</hashTree>
8675
</hashTree>
8776
</hashTree>
88-
</jmeterTestPlan>
77+
</jmeterTestPlan>

LoadTestingWebApp/Services/CosmosService.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@ public CosmosService(IConfiguration config)
1616
);
1717
}
1818

19-
private Container container
19+
private Container Container
2020
{
2121
get => _client.GetDatabase("WebAppDB").GetContainer("Visits");
2222
}
2323

2424
public async Task<IEnumerable<Visit>> RetrieveAllVisitsAsync()
2525
{
26-
var queryable = container.GetItemLinqQueryable<Visit>();
26+
var queryable = Container.GetItemLinqQueryable<Visit>();
2727

2828
using FeedIterator<Visit> feed = queryable
2929
.OrderByDescending(v => v.dateTime)
@@ -45,6 +45,6 @@ public async Task<IEnumerable<Visit>> RetrieveAllVisitsAsync()
4545

4646
public async Task AddVisitAsync(Visit _visit)
4747
{
48-
await container.CreateItemAsync(_visit, new PartitionKey(_visit.id));
48+
await Container.CreateItemAsync(_visit, new PartitionKey(_visit.id));
4949
}
5050
}

0 commit comments

Comments
 (0)