Installation
Felix has no binary releases yet — you build from source. This takes a Rust toolchain and a few minutes.
System Requirements
Section titled “System Requirements”- Operating System: Linux, macOS, or Windows (WSL2 recommended)
- Rust: 1.97.1 or later
- Memory: 4 GB minimum, 8 GB recommended for development
- Disk: 2 GB for build artifacts
- Network: For QUIC, ensure UDP traffic is allowed on your firewall
Install Rust
Section titled “Install Rust”Felix requires Rust 1.97.1 or later. Install using rustup:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | shFollow the prompts to complete installation. Then verify:
rustc --versioncargo --versionExpected output:
rustc 1.97.1 (or later)cargo 1.97.1 (or later)Clone the Repository
Section titled “Clone the Repository”git clone https://github.com/gabloe/felix.gitcd felixBuild from Source
Section titled “Build from Source”Development Build
Section titled “Development Build”For development and debugging with full error information:
cargo build --workspaceBinaries will be in target/debug/.
Release Build
Section titled “Release Build”For performance testing and production use:
cargo build --workspace --releaseBinaries will be in target/release/.
Build Specific Crates
Section titled “Build Specific Crates”Build only the broker service:
cargo build -p broker --releaseBuild only the client library:
cargo build -p felix-client --releaseVerify Installation
Section titled “Verify Installation”Run Tests
Section titled “Run Tests”Verify everything is working:
cargo test --workspaceYou should see all tests passing:
running 150 tests...test result: ok. 150 passed; 0 failed; 0 ignored; 0 measured; 0 filtered outRun the Conformance Suite
Section titled “Run the Conformance Suite”Felix includes a wire protocol conformance runner to validate correct framing and message encoding:
cargo run -p felix-conformanceExpected output:
Running wire protocol conformance tests...✓ Frame envelope encoding✓ Publish message encoding✓ Subscribe message encoding✓ Event message encoding✓ Cache operations encodingAll conformance tests passed!Start a cluster
Section titled “Start a cluster”A broker authenticates every connection against a control plane, so it does not
run alone. felix-cluster starts a control plane, mints the credentials and
brings up the brokers:
cargo run --release -p felix-cluster -- up --nodes 3cluster up.
control plane http://127.0.0.1:52704
node client metricsbroker-0 127.0.0.1:53348 127.0.0.1:52706broker-1 127.0.0.1:65027 127.0.0.1:52707broker-2 127.0.0.1:50410 127.0.0.1:52708
holding the cluster. press Ctrl-C to tear it down.Every address is chosen free at startup, so nothing collides with what you are already running. The Quickstart goes on to publish and subscribe against it; running brokers yourself is covered there too.
Run a Demo
Section titled “Run a Demo”Verify end-to-end functionality with a self-contained demo (no separate broker required):
cargo run --release -p broker --bin pubsub-demo-simpleOther demos you can try (including a control-plane RBAC mutation demo):
cargo run --release -p broker --bin cache-democargo run --release -p broker --bin latency-democargo run --release -p broker --bin pubsub-demo-notificationscargo run --release -p broker --bin pubsub-demo-orderscargo run --manifest-path demos/rbac-live/Cargo.tomlcargo run --manifest-path demos/cross_tenant_isolation/Cargo.tomlNote: the cross-tenant isolation demo uses a Postgres-backed control plane.
See the Demos Overview for details and expected output.
Optional Tools
Section titled “Optional Tools”Task Runner
Section titled “Task Runner”Install Task for convenient commands:
macOS/Linux:
sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/binUsing Homebrew:
brew install go-task/tap/go-taskThen you can use:
task build # Build everythingtask test # Run teststask fmt # Format codetask lint # Run lintersCargo Tools
Section titled “Cargo Tools”Install additional cargo extensions for development:
# Code coveragecargo install cargo-llvm-cov
# Security auditingcargo install cargo-deny --version 0.19.0 --locked
# Benchmarkingcargo install cargo-criterionBuild Customization
Section titled “Build Customization”Feature Flags
Section titled “Feature Flags”Felix supports optional feature flags:
Telemetry
Section titled “Telemetry”Enable detailed per-stage timing instrumentation:
cargo build --release --features telemetryEnvironment-Specific Builds
Section titled “Environment-Specific Builds”Minimal Build
Section titled “Minimal Build”Build only what you need:
# Just the brokercargo build --release -p broker
# Just the client librarycargo build --release -p felix-clientAll Demos
Section titled “All Demos”Build all demonstration binaries:
cargo build --release --binsPlatform-Specific Notes
Section titled “Platform-Specific Notes”Felix works best on Linux with modern kernel support for QUIC/UDP optimization:
- Kernel 5.8+ recommended
- Increase UDP buffer sizes for high throughput:
sudo sysctl -w net.core.rmem_max=26214400sudo sysctl -w net.core.wmem_max=26214400Works well on macOS 11 (Big Sur) and later. No special configuration needed.
Windows (WSL2)
Section titled “Windows (WSL2)”Use WSL2 for best compatibility:
- Install WSL2: Microsoft Guide
- Install Ubuntu or Debian
- Follow Linux instructions inside WSL2
Native Windows support is not currently tested.
Docker (Alternative)
Section titled “Docker (Alternative)”Released images are on GHCR and pull without credentials:
docker run -p 5000:5000/udp -p 8080:8080 \ -e FELIX_CONTROLPLANE_URL=http://controlplane:8443 \ -e FELIX_NODE_TOKEN_FILE=/etc/felix/node.token \ -v /path/to/node.token:/etc/felix/node.token:ro \ ghcr.io/gabloe/felix-broker:0.5.0A broker authenticates every client against its tenant’s signing keys, which it
fetches from the control plane, and registers itself there so shards can be
placed on it — so it needs both a control plane to reach and a node credential
to present. Without them it logs broker started and exits on the next line.
Docker Compose wires the pair together; for
a local cluster with nothing to configure, felix-cluster up is quicker (see
the Quickstart).
Each release publishes the full version (0.5.0), the minor series (0.5) and
latest. Use a version tag in anything you keep; latest moves. Images are
signed by digest — see Kubernetes for the
cosign verify invocation.
To build one instead, for a change you have not released:
# Build the broker imagedocker build -t felix-broker -f docker/broker.Dockerfile .
# Run what you builtdocker run -p 5000:5000/udp -p 8080:8080 felix-brokerControl Plane Container
Section titled “Control Plane Container”The same, for the control plane:
# Or build it: docker build -t felix-controlplane -f docker/controlplane.Dockerfile .
# Run the control plane (example uses a local Postgres)docker run -p 8443:8443 \ -e FELIX_CONTROLPLANE_POSTGRES_URL=postgres://postgres:postgres@host.docker.internal:55432/postgres \ ghcr.io/gabloe/felix-controlplane:0.5.0See Docker Compose Guide for orchestrated deployments.
Troubleshooting
Section titled “Troubleshooting”OpenSSL Errors (Linux)
Section titled “OpenSSL Errors (Linux)”If you see OpenSSL-related build errors:
# Ubuntu/Debiansudo apt-get install pkg-config libssl-dev
# RHEL/CentOS/Fedorasudo yum install pkg-config openssl-develLinker Errors
Section titled “Linker Errors”Use lld for faster linking (optional):
# Install lldsudo apt-get install lld # Debian/Ubuntubrew install llvm # macOS
# Configure Rust to use itmkdir -p .cargocat > .cargo/config.toml << EOF[target.x86_64-unknown-linux-gnu]linker = "clang"rustflags = ["-C", "link-arg=-fuse-ld=lld"]EOFOut of Memory
Section titled “Out of Memory”If the build runs out of memory:
# Reduce parallel jobscargo build --release -j 2Slow Builds
Section titled “Slow Builds”Enable incremental compilation for development:
export CARGO_INCREMENTAL=1cargo buildNext Steps
Section titled “Next Steps”- Quickstart Guide - Run your first Felix deployment
- Building & Testing - Development workflow
- Configuration - Customize Felix behavior
