kilork / actix-web-static-files

actix-web static files as resources support
The Unlicense
75 stars 18 forks source link

Create benchmarking suite #20

Open kilork opened 3 years ago

kilork commented 3 years ago

We are missing benchmarking suite in project. We need to have some numbers to provide this for comparision.

Related to #17 #10

kilork commented 3 years ago

https://github.com/boa-dev/criterion-compare-action https://blog.petitviolet.net/post/2020-10-08/github-action-for-rust-project https://github.com/koute/memory-profiler

kilork commented 3 years ago

We need also measure following characteristics for test dataset:

What else?

IronOxidizer commented 3 years ago

There should be 2 performance tests, large files (>1MB), and small files (<1KB). This should better gauge overhead and improvements from 0 copy body.

kilork commented 3 years ago

Created docker images for https://github.com/koute/memory-profiler.

Repositories:

kilork commented 3 years ago

Created repository with prepared static data for benchmark.

https://github.com/kilork/actix-web-static-files-bench

This has already some benefit - my tests on Apple M1 shows I cannot bundle more than 256 Mb.

Need to clarify, is there a possibility to pack more or it is not depending from us.

kilork commented 3 years ago

An additional find: change-detection is really helpful and allows to solve issue with deleted data from static resources. Without change detection by default cargo does not trigger build script, this leads to compile failure.

kilork commented 3 years ago

Last outcome - rust fails to build executable with current approach somewhere between 256Mb and 512 Mb.

kilork commented 3 years ago

To check: https://github.com/fcsonline/drill for load testing

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.