Skip to content

pretzelhammer/using-rust-in-non-rust-servers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Using Rust in Non-Rust Servers to Improve Performance

Companion code repository for the article Using Rust in Non-Rust Servers to Improve Performance.

Setup

Required tools:

  • nvm (Node version manager, how to install)
  • rustup (Rust toolchain manager, how to install)
  • just (Command runner, cargo install just)
  • wasm-pack (Builds Rust Wasm, cargo install wasm-pack)
  • wasm-opt (Optimizes Wasm, apt install binaryen or brew install binaryen)

Then from the root of this project run:

# install specific version of node
# and download project dependencies
cd ./node && nvm install && npm ci

# update to latest stable Rust toolchain
rustup update stable

Optional tools, for running benchmarks:

Also, the just commands monitor and attack-and-monitor will only work on Linux or WSL because they rely on reading the proc directory to measure a process's CPU and RAM usage. However, you can still run just attack on any OS.

Commands

Get a list of all commands:

just list

Commands to run servers:

just tier-0-server
just tier-1-server
just tier-2-server
just tier-3-server
just tier-4-server

Command to benchmark currently running server:

# on Linux or WSL
just attack-and-monitor

# on macOS or Windows
just attack

License

This code is dual-licensed under Apache License Version 2.0 or MIT License, at your option.

About

No description, website, or topics provided.

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
license-apache
MIT
license-mit

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published