This commit is contained in:
thosakwe 2017-08-03 13:52:10 -04:00
parent 3599e83ecf
commit 917713bbc3
6 changed files with 326 additions and 89 deletions

View file

@ -0,0 +1,8 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="performance::hello::raw" type="DartCommandLineRunConfigurationType" factoryName="Dart Command Line Application" singleton="true">
<option name="checkedMode" value="false" />
<option name="filePath" value="$PROJECT_DIR$/performance/hello/raw.dart" />
<option name="workingDirectory" value="$PROJECT_DIR$" />
<method />
</configuration>
</component>

View file

@ -2,28 +2,12 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="7b89ff1e-1260-4dcf-9c3d-345de0471ea1" name="Default" comment="">
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/.idea/runConfigurations/performance__hello.xml" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/analysis_options.yaml" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/lib/src/fast_name_from_symbol.dart" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/lib/src/safe_stream_controller.dart" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/performance/hello/main.dart" />
<change type="DELETED" beforePath="$PROJECT_DIR$/lib/src/extensible.dart" afterPath="" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/libraries/Dart_Packages.xml" afterPath="$PROJECT_DIR$/.idea/libraries/Dart_Packages.xml" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/.idea/runConfigurations/performance__hello__raw.xml" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/performance/hello/angel.md" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/performance/hello/raw.dart" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/performance/hello/raw.md" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/CHANGELOG.md" afterPath="$PROJECT_DIR$/CHANGELOG.md" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/hooks.dart" afterPath="$PROJECT_DIR$/lib/hooks.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/angel_base.dart" afterPath="$PROJECT_DIR$/lib/src/http/angel_base.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/controller.dart" afterPath="$PROJECT_DIR$/lib/src/http/controller.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/hooked_service.dart" afterPath="$PROJECT_DIR$/lib/src/http/hooked_service.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/request_context.dart" afterPath="$PROJECT_DIR$/lib/src/http/request_context.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/response_context.dart" afterPath="$PROJECT_DIR$/lib/src/http/response_context.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/routable.dart" afterPath="$PROJECT_DIR$/lib/src/http/routable.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/server.dart" afterPath="$PROJECT_DIR$/lib/src/http/server.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/lib/src/http/service.dart" afterPath="$PROJECT_DIR$/lib/src/http/service.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/pubspec.yaml" afterPath="$PROJECT_DIR$/pubspec.yaml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/test/exception_test.dart" afterPath="$PROJECT_DIR$/test/exception_test.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/test/routing_test.dart" afterPath="$PROJECT_DIR$/test/routing_test.dart" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/test/services_test.dart" afterPath="$PROJECT_DIR$/test/services_test.dart" />
</list>
<ignored path="$PROJECT_DIR$/.tmp/" />
<ignored path="$PROJECT_DIR$/temp/" />
@ -47,11 +31,21 @@
</component>
<component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="375">
<file leaf-file-name="pubspec.yaml" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/pubspec.yaml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="21">
<caret line="1" column="14" lean-forward="false" selection-start-line="1" selection-start-column="14" selection-end-line="1" selection-end-column="14" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="main.dart" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/performance/hello/main.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="147">
<caret line="7" column="8" lean-forward="true" selection-start-line="7" selection-start-column="8" selection-end-line="7" selection-end-column="8" />
<caret line="7" column="8" lean-forward="true" selection-start-line="0" selection-start-column="0" selection-end-line="27" selection-end-column="0" />
<folding>
<element signature="e#75#92#0" expanded="true" />
</folding>
@ -71,12 +65,65 @@
</provider>
</entry>
</file>
<file leaf-file-name="response_context.dart" pinned="false" current-in-tab="true">
<file leaf-file-name="response_context.dart" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/lib/src/http/response_context.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-5379">
<caret line="8" column="32" lean-forward="false" selection-start-line="8" selection-start-column="32" selection-end-line="8" selection-end-column="32" />
<state relative-caret-position="116">
<caret line="145" column="3" lean-forward="false" selection-start-line="145" selection-start-column="3" selection-end-line="145" selection-end-column="3" />
<folding>
<element signature="e#48#68#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="CHANGELOG.md" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/CHANGELOG.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="357">
<caret line="17" column="42" lean-forward="false" selection-start-line="17" selection-start-column="42" selection-end-line="17" selection-end-column="42" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="angel.md" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/performance/hello/angel.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="84">
<caret line="4" column="9" lean-forward="false" selection-start-line="4" selection-start-column="9" selection-end-line="4" selection-end-column="9" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="raw.dart" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/performance/hello/raw.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="235">
<caret line="19" column="6" lean-forward="false" selection-start-line="19" selection-start-column="6" selection-end-line="19" selection-end-column="6" />
<folding>
<element signature="e#75#92#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="raw.md" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/performance/hello/raw.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="231">
<caret line="11" column="7" lean-forward="false" selection-start-line="11" selection-start-column="7" selection-end-line="11" selection-end-column="7" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
@ -176,12 +223,9 @@
<option value="$PROJECT_DIR$/lib/src/http/service.dart" />
<option value="$PROJECT_DIR$/lib/src/safe_stream_controller.dart" />
<option value="$PROJECT_DIR$/test/services_test.dart" />
<option value="$PROJECT_DIR$/pubspec.yaml" />
<option value="$PROJECT_DIR$/lib/hooks.dart" />
<option value="$PROJECT_DIR$/lib/src/http/response_context.dart" />
<option value="$PROJECT_DIR$/lib/src/http/hooked_service.dart" />
<option value="$PROJECT_DIR$/lib/src/http/routable.dart" />
<option value="$PROJECT_DIR$/CHANGELOG.md" />
<option value="$PROJECT_DIR$/lib/src/extensible.dart" />
<option value="$PROJECT_DIR$/lib/src/http/request_context.dart" />
<option value="$PROJECT_DIR$/lib/src/http/server.dart" />
@ -189,6 +233,12 @@
<option value="$PROJECT_DIR$/lib/src/http/angel_base.dart" />
<option value="$PROJECT_DIR$/lib/src/fast_name_from_symbol.dart" />
<option value="$PROJECT_DIR$/performance/hello/main.dart" />
<option value="$PROJECT_DIR$/lib/src/http/response_context.dart" />
<option value="$PROJECT_DIR$/CHANGELOG.md" />
<option value="$PROJECT_DIR$/performance/hello/raw.dart" />
<option value="$PROJECT_DIR$/performance/hello/angel.md" />
<option value="$PROJECT_DIR$/performance/hello/raw.md" />
<option value="$PROJECT_DIR$/pubspec.yaml" />
</list>
</option>
</component>
@ -352,7 +402,7 @@
</list>
</option>
</component>
<component name="RunManager" selected="Dart Command Line App.performance::hello">
<component name="RunManager" selected="Dart Command Line App.performance::hello::raw">
<configuration default="true" type="BashConfigurationType" factoryName="Bash">
<option name="INTERPRETER_OPTIONS" value="" />
<option name="INTERPRETER_PATH" value="C:\Windows\system32\bash.exe" />
@ -500,7 +550,7 @@
<option name="testName" value="precontained_test.dart" />
<method />
</configuration>
<list size="21">
<list size="22">
<item index="0" class="java.lang.String" itemvalue="Dart Test.can create data in services_test.dart" />
<item index="1" class="java.lang.String" itemvalue="Dart Test.can delete data in services_test.dart" />
<item index="2" class="java.lang.String" itemvalue="Dart Test.can use app.properties like members in util_test.dart" />
@ -522,6 +572,7 @@
<item index="18" class="java.lang.String" itemvalue="Dart Test.tests in server_test.dart (PRODUCTION)" />
<item index="19" class="java.lang.String" itemvalue="Dart Test.All Tests" />
<item index="20" class="java.lang.String" itemvalue="Dart Test.All Tests (PRODUCTION)" />
<item index="21" class="java.lang.String" itemvalue="Dart Command Line App.performance::hello::raw" />
</list>
</component>
<component name="ShelveChangesManager" show_recycled="false">
@ -564,7 +615,7 @@
<workItem from="1499805699713" duration="409000" />
<workItem from="1499967777286" duration="36000" />
<workItem from="1500824399224" duration="86000" />
<workItem from="1501768538452" duration="9813000" />
<workItem from="1501768538452" duration="11180000" />
</task>
<task id="LOCAL-00001" summary="Re-designed exception">
<created>1481237183504</created>
@ -748,7 +799,21 @@
<option name="project" value="LOCAL" />
<updated>1500824472581</updated>
</task>
<option name="localTasksCounter" value="27" />
<task id="LOCAL-00027" summary="Working on 1.0.8, including performance tuning">
<created>1501778421241</created>
<option name="number" value="00027" />
<option name="presentableId" value="LOCAL-00027" />
<option name="project" value="LOCAL" />
<updated>1501778421241</updated>
</task>
<task id="LOCAL-00028" summary="Remove reopen">
<created>1501778536483</created>
<option name="number" value="00028" />
<option name="presentableId" value="LOCAL-00028" />
<option name="project" value="LOCAL" />
<updated>1501778536483</updated>
</task>
<option name="localTasksCounter" value="29" />
<servers />
</component>
<component name="TestHistory">
@ -784,7 +849,7 @@
</history-entry>
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="35982000" />
<option name="totallyTimeSpent" value="37349000" />
</component>
<component name="TodoView">
<todo-panel id="selected-file">
@ -805,7 +870,7 @@
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
<window_info id="Dart Analysis" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.3272933" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.34314835" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.34314835" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.3250283" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.18455844" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.3295583" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
@ -831,7 +896,6 @@
<option name="myLimit" value="2678400000" />
</component>
<component name="VcsManagerConfiguration">
<MESSAGE value="Re-designed exception" />
<MESSAGE value="Core done?" />
<MESSAGE value="Fixed todo" />
<MESSAGE value="Done???" />
@ -855,34 +919,15 @@
<MESSAGE value="Added RequestContext.accepts" />
<MESSAGE value="Swapped to angel_model" />
<MESSAGE value="1.0.7+2" />
<option name="LAST_COMMIT_MESSAGE" value="1.0.7+2" />
<MESSAGE value="Working on 1.0.8, including performance tuning" />
<MESSAGE value="Remove reopen" />
<option name="LAST_COMMIT_MESSAGE" value="Remove reopen" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager />
<watches-manager />
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/lib/angel_framework.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="63">
<caret line="3" column="7" lean-forward="false" selection-start-line="3" selection-start-column="7" selection-end-line="3" selection-end-column="7" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/lib/src/http/memory_service.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="563">
<caret line="74" column="0" lean-forward="false" selection-start-line="74" selection-start-column="0" selection-end-line="74" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/test/view_generator_test.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="126">
<caret line="6" column="38" lean-forward="true" selection-start-line="6" selection-start-column="38" selection-end-line="6" selection-end-column="38" />
</state>
</provider>
</entry>
<entry file="file://C:/Program Files/Dart/dart-sdk/lib/io/http.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="284">
@ -1130,14 +1175,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/pubspec.yaml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="189">
<caret line="9" column="31" lean-forward="false" selection-start-line="9" selection-start-column="31" selection-end-line="9" selection-end-column="31" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/lib/hooks.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="167">
@ -1206,17 +1243,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CHANGELOG.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="315">
<caret line="15" column="38" lean-forward="false" selection-start-line="15" selection-start-column="38" selection-end-line="15" selection-end-column="38" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/test/precontained_test.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="105">
@ -1251,16 +1277,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/performance/hello/main.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="147">
<caret line="7" column="8" lean-forward="true" selection-start-line="7" selection-start-column="8" selection-end-line="7" selection-end-column="8" />
<folding>
<element signature="e#75#92#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/lib/src/http/request_context.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-5090">
@ -1273,8 +1289,71 @@
</entry>
<entry file="file://$PROJECT_DIR$/lib/src/http/response_context.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-5379">
<caret line="8" column="32" lean-forward="false" selection-start-line="8" selection-start-column="32" selection-end-line="8" selection-end-column="32" />
<state relative-caret-position="116">
<caret line="145" column="3" lean-forward="false" selection-start-line="145" selection-start-column="3" selection-end-line="145" selection-end-column="3" />
<folding>
<element signature="e#48#68#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CHANGELOG.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="357">
<caret line="17" column="42" lean-forward="false" selection-start-line="17" selection-start-column="42" selection-end-line="17" selection-end-column="42" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/performance/hello/main.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="147">
<caret line="7" column="8" lean-forward="true" selection-start-line="0" selection-start-column="0" selection-end-line="27" selection-end-column="0" />
<folding>
<element signature="e#75#92#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/performance/hello/raw.dart">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="235">
<caret line="19" column="6" lean-forward="false" selection-start-line="19" selection-start-column="6" selection-end-line="19" selection-end-column="6" />
<folding>
<element signature="e#75#92#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/performance/hello/angel.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="84">
<caret line="4" column="9" lean-forward="false" selection-start-line="4" selection-start-column="9" selection-end-line="4" selection-end-column="9" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/performance/hello/raw.md">
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
<state split_layout="SPLIT">
<first_editor relative-caret-position="231">
<caret line="11" column="7" lean-forward="false" selection-start-line="11" selection-start-column="7" selection-end-line="11" selection-end-column="7" />
<folding />
</first_editor>
<second_editor />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/pubspec.yaml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="21">
<caret line="1" column="14" lean-forward="false" selection-start-line="1" selection-start-column="14" selection-end-line="1" selection-end-column="14" />
<folding />
</state>
</provider>

View file

@ -0,0 +1,62 @@
# Angel Results
5 consecutive trials run on a Windows 10 box with 4GB RAM, and several programs open in the background.
Setup:
* Angel framework `1.0.8`
* Running `wrk` 4.0.2.2
* 2 threads
* 256 connections
* 30 seconds
Average:
* `11070.18` req/sec
* `11.86` ms latency
```
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 12.23ms 7.56ms 206.05ms 93.09%
Req/Sec 5.48k 761.94 7.18k 87.50%
324822 requests in 30.06s, 62.88MB read
Requests/sec: 10806.24
Transfer/sec: 2.09MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 11.06ms 4.88ms 134.86ms 78.68%
Req/Sec 5.98k 539.40 7.50k 91.40%
356355 requests in 30.11s, 68.99MB read
Requests/sec: 11836.11
Transfer/sec: 2.29MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 12.03ms 6.18ms 159.93ms 87.89%
Req/Sec 5.52k 0.88k 7.32k 90.31%
327749 requests in 30.06s, 63.45MB read
Requests/sec: 10901.35
Transfer/sec: 2.11MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 12.92ms 7.06ms 189.00ms 82.48%
Req/Sec 5.12k 1.00k 6.42k 75.59%
302273 requests in 30.05s, 58.52MB read
Requests/sec: 10059.96
Transfer/sec: 1.95MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 11.05ms 4.92ms 104.90ms 69.57%
Req/Sec 5.95k 0.87k 7.65k 76.80%
352798 requests in 30.03s, 68.30MB read
Requests/sec: 11747.23
Transfer/sec: 2.27MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$
```

View file

@ -0,0 +1,28 @@
/// A basic server that prints "Hello, world!"
library performance.hello;
import 'dart:io';
import 'dart:isolate';
main() {
for (int i = 0; i < Platform.numberOfProcessors - 1; i++)
Isolate.spawn(start, i + 1);
start(0);
}
void start(int id) {
HttpServer
.bind(InternetAddress.LOOPBACK_IP_V4, 3000, shared: true)
.then((server) {
print(
'Instance #$id listening at http://${server.address.address}:${server.port}');
server.listen((request) {
if (request.uri.path == '/') {
request.response.write('Hello, world!');
}
request.response.close();
});
});
}

60
performance/hello/raw.md Normal file
View file

@ -0,0 +1,60 @@
# `dart:io` Results
5 consecutive trials run on a Windows 10 box with 4GB RAM, and several programs open in the background.
Setup:
* Running `wrk` 4.0.2.2
* 2 threads
* 256 connections
* 30 seconds
Average:
* `14598.16` req/sec
* `8.88` ms latency
```
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 9.67ms 8.19ms 202.28ms 96.17%
Req/Sec 7.15k 1.47k 9.97k 73.76%
417716 requests in 30.07s, 82.06MB read
Requests/sec: 13892.50
Transfer/sec: 2.73MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 8.47ms 3.14ms 100.77ms 65.40%
Req/Sec 7.61k 670.47 8.85k 73.88%
453301 requests in 30.07s, 89.05MB read
Requests/sec: 15077.15
Transfer/sec: 2.96MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 8.62ms 3.51ms 73.34ms 63.74%
Req/Sec 7.52k 650.22 8.91k 79.17%
448445 requests in 30.07s, 88.10MB read
Requests/sec: 14911.53
Transfer/sec: 2.93MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 8.75ms 3.51ms 70.50ms 64.53%
Req/Sec 7.41k 825.50 10.23k 72.24%
441338 requests in 30.09s, 86.70MB read
Requests/sec: 14665.62
Transfer/sec: 2.88MB
tobe@LAPTOP-VBHCSVRH:/mnt/c/Users/thosa$ wrk -c 256 -d 30 -t 2 http://localhost:3000
Running 30s test @ http://localhost:3000
2 threads and 256 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 8.90ms 3.62ms 78.36ms 66.71%
Req/Sec 7.31k 742.11 10.79k 77.84%
434674 requests in 30.09s, 85.39MB read
Requests/sec: 14443.98
Transfer/sec: 2.84MB
```

View file

@ -1,5 +1,5 @@
name: angel_framework
version: 1.0.7+2
version: 1.0.8
description: A high-powered HTTP server with DI, routing and more.
author: Tobe O <thosakwe@gmail.com>
homepage: https://github.com/angel-dart/angel_framework