Minimal examples of using casbin-rs
and actix-web-grants
and performance comparisons
The wrk
tool was used for benchmarks (all commands used can be found in bench.sh
)
- To run you need
cargo
andwrk
installed - Clone the
actix-web-authz-benchmark
repository - Run the shell script
bench.sh
in the root of project directory
sh bench.sh
Benchmark | actix-web-grants | casbin-rs | ||
Latency | Req/Sec | Latency | Req/Sec | |
Allowed Endpoint | 4.41 ms | 22.69k | 6.18 ms | 16.27k |
Denied Endpoint | 4.94 ms | 20.23k | 6.70 ms | 14.98k |
rustc: v1.52.0 (stable); CPU: 2,6 GHz 6-Core Intel Core i7; RAM: 16 GB