When I run the main example on Windows, it's either crash (2%) or just hang after several concurrent requests (98%).
Expected Behavior
Pony should never crash or hang once compiled! At least based on jennet implementation, it doesn't really do that much.
Current Behavior
Everything compiled nicely, but once I run the wrk tool via Ubuntu WSL wrk -c100 -d30s --latency http://127.0.0.1:8080/. It will crash or just hang forever instantly within 2 seconds. No errors, nothing. Just a feeling of emptiness.
Current Workaround
I managed to get this working by always adding a Content-Length header to the BuildableResponse, I pretty much use my own BuildableResponse, instead of using the one provided here:
Original:
|
primitive StatusResponse |
|
fun apply( |
|
status: Status, |
|
headers: Array[(String, String)] box = [], |
|
close: Bool = true) |
|
: BuildableResponse iso^ |
|
=> |
|
let res = recover BuildableResponse(status) end |
|
for (k, v) in headers.values() do |
|
res.add_header(k, v) |
|
end |
|
if close and (res.header("Connection") is None) then |
|
res.add_header("Connection", "close") |
|
end |
|
res |
Mine:

Steps to Reproduce
- Windows Machine?
- Ubuntu WSL installed
- wrk installed following
- Pretty much everything else was just copy pasted from get started with pony mixed with trying to get jennet to run. But i'm going to write the steps anyway starting from step 3 😄
- Install Pony https://github.com/ponylang/ponyc/blob/main/INSTALL.md#windows
- Install corral https://github.com/ponylang/corral/blob/main/BUILD.md#from-source-windows
- Create a new folder?
jennet-test
corral init
- Install corral dependencies
- jennet doesn't use
main as the main branch so corral will fail. Thus we have to manually clone the jennet git into _corral folder in the jennet_test/_corral/github_com_theodus_jennet
- follow https://github.com/Theodus/jennet#named-parameters example (I do need to change the listening host to 0.0.0.0)
- run with command in cmd
corral run -- ponyc --define openssl_0.9.0
- run wrk with WSL
wrk -c100 -d30s --latency http://127.0.0.1:8080/
Context (Environment)
- Windows 10
- Ubuntu WSL
- ponyc
0.41.1 [release]
Compiled with: LLVM 9.0.1 -- MSVC-19.28.29335.0-x64 1928
- OpenSSL 0.9.0
Notes:
It works fine when building & running in a linux environment, just 100x much more slower somehow (might be due to WSL?):
- Ubuntu 18.04.2 LTS (WSL)
- ponyc
0.41.1-4553e6cf [release]
Compiled with: LLVM 9.0.1 -- Clang-6.0.0-x86_64
Defaults: pic=true
- OpenSSL 1.1.x
When I run the main example on Windows, it's either crash (2%) or just hang after several concurrent requests (98%).
Expected Behavior
Pony should never crash or hang once compiled! At least based on jennet implementation, it doesn't really do that much.
Current Behavior
Everything compiled nicely, but once I run the wrk tool via Ubuntu WSL
wrk -c100 -d30s --latency http://127.0.0.1:8080/. It will crash or just hang forever instantly within 2 seconds. No errors, nothing. Just a feeling of emptiness.Current Workaround
I managed to get this working by always adding a
Content-Lengthheader to the BuildableResponse, I pretty much use my own BuildableResponse, instead of using the one provided here:Original:
jennet/jennet/jennet.pony
Lines 172 to 186 in 6ed62c9
Mine:

Steps to Reproduce
jennet-testcorral initcorral add github.com/ponylang/http_server.gitmainas the main branch so corral will fail. Thus we have to manually clone the jennet git into _corral folder in thejennet_test/_corral/github_com_theodus_jennetcorral run -- ponyc --define openssl_0.9.0wrk -c100 -d30s --latency http://127.0.0.1:8080/Context (Environment)
0.41.1 [release]
Compiled with: LLVM 9.0.1 -- MSVC-19.28.29335.0-x64 1928
Notes:
It works fine when building & running in a linux environment, just 100x much more slower somehow (might be due to WSL?):
0.41.1-4553e6cf [release]
Compiled with: LLVM 9.0.1 -- Clang-6.0.0-x86_64
Defaults: pic=true