This is an unofficial Rust implementation of Apache RocketMQ, a distributed messaging and streaming platform.
- Language: Rust (nightly toolchain, MSRV 1.85.0)
- Architecture: Multi-crate Cargo workspace with standalone projects
- Key Components: Broker, NameServer, Client, Store, Remoting, Controller, Proxy
- License: Apache-2.0 OR MIT
Root Cargo workspace containing core crates:
rocketmq-broker- Message broker implementationrocketmq-client- Client SDKrocketmq-common- Shared utilities and typesrocketmq-store- Storage enginerocketmq-remoting- Network communication layerrocketmq-namesrv- Name server for routingrocketmq-controller- Cluster controllerrocketmq-proxy- Proxy layerrocketmq-auth- Authentication modulerocketmq-filter- Message filteringrocketmq-runtime- Async runtime abstractionsrocketmq-macros- Procedural macrosrocketmq-error- Error typesrocketmq-tools/*- Admin CLI, TUI, and store inspection toolsrocketmq-dashboard/rocketmq-dashboard-common- Dashboard shared code
These require separate validation in their own directories:
rocketmq-example- Example applicationsrocketmq-dashboard/rocketmq-dashboard-gpui- GPUI-based dashboardrocketmq-dashboard/rocketmq-dashboard-tauri/src-tauri- Tauri app backend
- Format:
cargo fmt --all(for workspace) orcargo fmt(for standalone) - Lint:
cargo clippy --workspace --no-deps --all-targets --all-features -- -D warnings - Never finish with unformatted code or clippy warnings
- Default: Targeted tests only (modified area)
- Scope examples:
cargo test -p rocketmq-common # Package-level cargo test -p rocketmq-client --lib # Library tests only cargo test -p rocketmq-remoting test_name # Specific test
- Broader tests only when changes affect:
- Shared infrastructure
- Multiple crates
- Build configuration
- Cross-crate APIs
Root workspace commands do NOT cover standalone projects. When modifying:
rocketmq-example→ validate inrocketmq-example/rocketmq-dashboard/rocketmq-dashboard-gpui→ validate in that directoryrocketmq-dashboard/rocketmq-dashboard-tauri/src-tauri→ validate in that directory
If shared crate changes affect standalone projects, validate those too.
- Minimal scope - Only validate what you changed
- Targeted tests - Don't run full workspace tests by default
- Clean diffs - Keep changes focused on the task
- Test coverage - Add/update tests when behavior changes
- Follow hierarchy - Subdirectory
CLAUDE.mdfiles override this one
See also:
.claude/CLAUDE.md- Extended project memory.claude/rules/- Specific rule filesAGENTS.md- Agent-specific instructions (similar content)
- Follow
rustfmt.tomlconfiguration (max_width=120, imports_granularity="Item") - Use nightly Rust features as configured in
rust-toolchain.toml - Respect existing patterns in the codebase