Chapter 28: third-party, what came from elsewhere
The last chapter is about everything this repository did not write: every crate from crates.io, and the Jev client it shares with the owner's other Jev projects.
crates.io, without vendoring. Cargo.toml here is not a
real package. It lists every crates.io dependency of the whole repository so
that Cargo can resolve and lock their versions (Cargo.lock),
and then reindeer, a tool from the buck world, turns that resolution into
BUCK: one http_archive per crate (its URL and sha256) and one
build rule per crate. No crate's source is committed. buck fetches each
archive when it builds, and the nix package fetches the same archives by
the same hashes, read out of the same file (chapter 16).
flowchart LR C["Cargo.toml: what the repo depends on"] -->|"cargo resolves"| L["Cargo.lock"] L -->|"reindeer buckify"| B["BUCK: an http_archive and a rule per crate"] R["reindeer.toml, fixups/, pg_major.bzl"] --> B B --> U["//third-party:pgrx, //third-party:hyper, …"] J["jevcrates/ (git submodule)"] -->|"path dependencies"| C
jevcrates, as a submodule. jev-protocol (the questions, the exact
request bytes, the verified answers), jev-client (retries, timeouts,
redials, behind two ports) and jev-mock (the fake Jev every test talks to)
lived in this repository until 2026-10-01. They moved to jevcrates, where
four projects share one copy, and come back in as the git submodule
jevcrates/, pinned by its commit and buckified like any crate.
.gitmodules names it by the relative URL ../jevcrates.git, so a clone
from the lmjtfy site finds it right beside this one. jevcrates has a guide of
its own, starting at its README.
Aside: pgrx and the moving major. reindeer writes pgrx with the one
pgNNfeatureCargo.tomlselects (18). That would build the whole graph for 18 only. pg_major.bzl wraps reindeer's rules so that anypgNNfeature becomes a select over thepg_majorconstraint (chapter 27), and gives pgrx-pg-sys's bindgen run that major'spg_config.reindeer.tomlloads it in place of the prelude's rules, so it survives every re-buckify.
Try it.
git submodule statusshows the jevcrates commit this checkout pins, andgit clone https://lmjtfy.fun/jevcrates.gitis that repository on its own.
Not chapters, on purpose:
jevcrates/is another repository, with its own guide.fixups/holds onefixups.tomlper crate whose build needs help under buck (mostly: run its build script, and pass on the native libraries it asks to link): 34 folders of one file each, a mechanical shard of reindeer's input with nothing to say beyond its own contents.top/holdslib.rs, a one-line placeholder: reindeer needs this manifest to have a library target, and it points here.
For the people who maintain it
| Path | What |
|---|---|
| Cargo.toml | Every crates.io dependency, with the features it is built with, and the jev crates as path dependencies into the submodule. |
| Cargo.lock | The resolved versions buck builds. |
| BUCK | Generated by reindeer: the archives and rules. Do not edit. |
| reindeer.toml | reindeer's settings: fetch, do not vendor (vendor = false); the full Cargo environment for build scripts; buckfile_imports, which loads pg_major.bzl and exports Cargo.toml for tools/cargo-gen. |
| pg_major.bzl | reindeer's rules with pgrx's major made a configuration. |
| fixups/ | Per-crate build fixes for reindeer. |
| top/ | The placeholder crate root. |
| jevcrates/ | The jevcrates submodule. |
The guide ends here. If you came for the extension, the root CLAUDE.md is the whole design contract, every rule with its evidence; if you came for the client, jevcrates' guide picks up where this one leaves off.
← Previous: Chapter 27, platforms/ · Up: postjevsql