Comments (8)
I was able to get much better perf from static files. Thanks a ton @gtach2o. I also added a libev
test suite and a vegeta
load test suite (these will only run on master PRs). 0.1.1
should be much more performant than 0.1.0
!
from naboris.
fixed in 0.1.1
from naboris.
I have tried with let _ = Unix.close(fd);
and it did help.
vegeta -cpus 16 attack -http2=false -duration=60s -targets veg.txt | tee results.bin | vegeta report
Requests [total, rate, throughput] 3000, 50.01, 50.01
Duration [total, attack, wait] 59.984438332s, 59.98206917s, 2.369162ms
Latencies [mean, 50, 95, 99, max] 4.344825ms, 2.572458ms, 9.694918ms, 29.371967ms, 121.457504ms
Bytes In [total, mean] 404104200, 134701.40
Bytes Out [total, mean] 0, 0.00
Success [ratio] 100.00%
Status Codes [code:count] 200:3000
from naboris.
vegeta -cpus 4 attack -http2=false -duration=60s -targets veg.txt | tee results.bin | vegeta report
Some interesting numbers of Latencies
with Unix.close(fd);
mean | 50 | 95 | 99 | max |
---|---|---|---|---|
4.239174ms | 2.278331ms | 9.283131ms | 26.988654ms | 130.551781ms |
with let _ = Unix.close(fd);
mean | 50 | 95 | 99 | max |
---|---|---|---|---|
3.23765ms | 2.039496ms | 6.237305ms | 8.247941ms | 122.032702ms |
from naboris.
@gtach2o great! Is this with conf-libev as well? I found performance to be much better with libel. You can make a PR if you’d like. I’m working on getting writing an automated test for this.
I will probably add a recommendation to install libev in the readme as well.
from naboris.
I can see you already have it in clean-up-fds
branch.
Yes, I tested it with libev. The problem is the conf-libev depends on libev C library.
I think you need to add
sudo apt-get update
sudo apt-get install libev-dev
to before_install
in travis config.
from naboris.
I think i might run 2 test suites, one with libev and without, since it is optional. Thanks for all of the help with this!
from naboris.
Actually i'll leave it open until this goes into master
:-)
from naboris.
Related Issues (20)
- Any performance numbers to share? HOT 1
- Hotfix - use content length headers
- Unify Res API
- Add delete session API
- OCaml example from readme HOT 4
- Static files OCaml example in readme HOT 1
- Unix.EINVAL when serving static under load test HOT 4
- Fix issues in code examples on README
- Add easy to use static config
- Add support for caching HOT 1
- Add support for partial requests HOT 1
- Better documentation HOT 1
- Refactor to use lwt ppx
- Add WebSocket feature HOT 1
- Better error handling HOT 2
- Encrypt session IDs
- typo in docs
- Support newer versions of OCaml HOT 1
- Add support for CSRF tokens
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from naboris.