Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/CodeForcer/rust-pending-stream

Pending transaction stream in rust
https://github.com/CodeForcer/rust-pending-stream

Last synced: about 2 months ago
JSON representation

Pending transaction stream in rust

Awesome Lists containing this project

README

        

# ethers.js vs ethers-rs mempool stream performance

Based on these tests Rust appears to be approximately 62.67% faster for mempool streaming than Typescript on the same hardware and node connection

## Installation

```
cargo build
```

## Run

Start server
```
cargo run
```

## Benchmarking against Typescript code

Install Typescript
```
cd benchmarks
yarn install
```

Compare benchmarks for processing over 60 seconds
```
# Run Typescript for 60 seconds
ts-node pending-stream.ts & sleep 60 ; kill $!

# Run equivalent Rust code for 60 seconds
./target/release/pending-stream & sleep 60 ; kill $!
```