/concurrency-benchmarks

concurrency-benchmarks for languages

Primary LanguageRustMIT LicenseMIT

Concurrency in modern programming languages

This is the code samples used for my blog series https://deepu.tech/concurrency-in-modern-languages/

The benchmarks are run using wrk and drill.

Scripts and benchmark results can be found in the results/nosleep folder

Previously the benchmarks were run using ApacheBench

Java

# multi-thread version
cd javaws && java src/JavaHTTPServer.java

# Java Async version
cd javaws && java src/JavaAsyncHTTPServer.java

# Java Undertow version
cd java_undertow && mvn clean install && java -jar target/hello-java-1.0.0-SNAPSHOT.jar

Go

# HTTP server
cd gows && go run main.go

# TCP version
cd gows_tcp && go run main.go

Rust

# multi-thread version
cd rustws && cargo run --release

# async version
cd rustws_async && cargo run --release

# async thread version
cd rustws_async_thread && cargo run --release

# async tokio version
cd rustws_async_tokio && cargo run --release

# async actix-web version
cd rust_actixweb && cargo run --release

JS

# async version
cd jsws && node main.js

# multi-thread version
cd jsws_thread && node main.js

TS

# async version
cd tsws && deno run --allow-all main.ts

.NET

# async version
cd dotnetws && dotnet run