Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

ResQ Examples

Hands-on, runnable examples for every crate in the ResQ workspace.

Data Structures & Algorithms (resq-dsa)

Runnable Rust examples — no external services needed. Execute with:

cargo run -p resq-dsa --example <name>
Example Structures Used Scenario
bloom_dedup BloomFilter Web crawler URL deduplication
count_min_traffic CountMinSketch API traffic frequency analysis
graph_routing Graph (BFS, Dijkstra, A*) City transit network pathfinding
heap_knn BoundedHeap K-nearest neighbor search
trie_autocomplete Trie, rabin_karp CLI command palette autocomplete
combined_pipeline All 5 structures Disaster response alert processing pipeline

Quick Start

# Run all examples back-to-back
for ex in bloom_dedup count_min_traffic graph_routing heap_knn trie_autocomplete combined_pipeline; do
  echo "=== $ex ==="
  cargo run -p resq-dsa --example "$ex"
  echo
done

CLI & TUI Tools

Each tool example includes runnable demo infrastructure — mock servers, sample data, scripts — so you can see the tools in action without production services.

Prerequisites

  • Rust toolchain (latest stable): rustup update stable
  • Build all tools: cargo build --release
  • Python 3 (for mock servers)
  • Docker (for resq-deploy example)
  • GCC (for resq-bin example)

Tool Examples

Tool Demo Type What You Run
resq-cli Sample project with missing headers + planted fake secrets resq copyright, resq secrets
resq-bin C program to compile and analyze ./run_demo.sh
resq-clean Script that creates a messy workspace ./create_mess.sh then resq-clean
resq-deploy Docker Compose with 4 mock services docker compose up, then resq-deploy
resq-flame CPU-intensive Python workload python3 cpu_burner.py then profile
resq-health 5 mock HTTP services (Python) python3 mock_services.py then resq-health
resq-logs Pre-generated log files in 3 formats resq-logs --source file --path sample-logs/
resq-perf Mock /status endpoint with changing metrics python3 mock_status_server.py then resq-perf