Crate Dependency Map

Workspace Layout

parallax/
├── Cargo.toml                     # Workspace root
├── crates/
│   ├── parallax-core/             # Shared types, zero external deps
│   ├── parallax-store/            # Storage engine (WAL + MemTable + Segments)
│   ├── parallax-graph/            # Graph traversal and reasoning
│   ├── parallax-query/            # PQL parse + plan + execute
│   ├── parallax-policy/           # Policy rule evaluation
│   ├── parallax-ingest/           # Sync protocol (diff + commit)
│   ├── parallax-connect/          # Integration SDK
│   ├── parallax-server/           # REST HTTP server
│   └── parallax-cli/              # CLI binary
└── specs/                         # Architectural specifications

Dependency Graph

parallax-core          (no workspace deps; blake3, serde, compact_str, thiserror)
       │
       ├──► parallax-store     (core; arc-swap, crc32c, lz4_flex, postcard, tracing)
       │           │
       │           ├──► parallax-graph     (core, store)
       │           │           │
       │           │           ├──► parallax-query      (core, graph)
       │           │           └──► parallax-policy     (core, graph)
       │           │
       │           └──► parallax-ingest    (core, store)
       │                       │
       │                       └──► parallax-connect    (core, ingest)
       │
parallax-server  (core, store, graph, query, policy, ingest, connect;
       │          axum, tower, tower-http, tokio, serde_json, uuid, compact_str)
       │
parallax-cli     (server; clap, anyhow, tokio)

External Dependencies by Crate

parallax-core

CrateVersionPurpose
serde1Serialization derive macros
compact_str0.8Small-string optimization (entity types/classes are short)
blake31Deterministic ID hashing (SIMD-accelerated)
thiserror1Error derive macros

parallax-store

CrateVersionPurpose
arc-swap1Lock-free atomic Arc swap for snapshot publishing
crc32c0.6WAL entry checksums
lz4_flex0.11Block compression for segment files
postcard1Compact binary serialization for WAL + Segments
tracing0.1Structured logging
tempfile3(dev) Temporary directories for tests

parallax-graph

CratePurpose
tracingStructured logging

parallax-query

CratePurpose
tracingStructured logging

parallax-policy

CratePurpose
serdePolicy rule serialization
tracingStructured logging

parallax-ingest

CratePurpose
tracingStructured logging
tempfile(dev) Temporary directories for tests

parallax-connect

CratePurpose
async-traitAsync trait support for the Connector trait
serdeBuilder serialization
tokioAsync runtime
tracingStructured logging
compact_strSmall-string optimization
thiserrorError types

parallax-server

CratePurpose
axumHTTP/REST server framework
towerMiddleware stack
tower-httpHTTP middleware (trace, request-id, sensitive-headers)
tokioAsync runtime
serde_jsonJSON serialization for REST responses
uuidUUID v4 for request IDs
compact_strSmall-string optimization
tracingStructured logging
thiserrorError types

parallax-cli

CratePurpose
clapCommand-line argument parsing
anyhowError handling in binary context
tokioAsync runtime
serde_jsonJSON output formatting

What We Explicitly Do Not Use

CrateWhy Not
rocksdbWe own storage. No C++ FFI dependency.
diesel / sqlxNo SQL database.
neo4j-*The whole point is to not depend on Neo4j.
sledCorrectness concerns in early versions.
tonic / prostgRPC deferred to v0.2; REST-only for v0.1.

Adding a New External Dependency

Before adding a new crate:

  1. Is there a std equivalent? Prefer std.
  2. Does an existing approved crate already cover this? Reuse it.
  3. Is the crate well-maintained, zero-unsound-unsafe, and Apache/MIT licensed?
  4. Does adding it violate the acyclic dep constraint?

Add a justification comment in Cargo.toml for non-obvious dependencies.