# ArchUnit and Rust architecture resources

Sources checked on November 24, 2026. Start with the reading attached to the current lesson; the remaining links are for later practice and lookup.

## Knowledge

### ArchUnit

- [Official user guide](https://www.archunit.org/userguide/html/000_Index.html). Primary tutorial for imports, package rules, JUnit integration, layers, and cycles. The lab pins 1.5.1; check the guide version when revisiting it.
- [Freezing Arch Rules](https://www.archunit.org/userguide/html/000_Index.html#_freezing_arch_rules). Primary reading for accepting existing violations and reducing the stored baseline.
- [FreezingArchRule 1.5.1 API](https://javadoc.io/static/com.tngtech.archunit/archunit/1.5.1/com/tngtech/archunit/library/freeze/FreezingArchRule.html). Lookup for description matching, stores, and extension points. Published source is available through Maven's sources artifact when behavior needs closer inspection.
- [ArchUnit releases](https://github.com/TNG/ArchUnit/releases). Version compatibility and changes; avoid treating a changing latest-version page as a pinned dependency.
- [Spring Boot testing](https://docs.spring.io/spring-boot/reference/testing/spring-boot-applications.html). Explains context-based Boot tests. Use when distinguishing ArchUnit's bytecode checks from application startup and request behavior.

### Rust constraints

- [Rust packages and crates](https://doc.rust-lang.org/book/ch07-01-packages-and-crates.html) and [visibility](https://doc.rust-lang.org/reference/visibility-and-privacy.html). Establish what Cargo builds and what the compiler can make inaccessible.
- [cargo-deny bans configuration](https://embarkstudios.github.io/cargo-deny/checks/bans/cfg.html) and [diagnostics](https://embarkstudios.github.io/cargo-deny/checks/bans/diags.html). Primary reading for lesson 3 and the later permitted-wrapper exercise; a wrapper is an explicit dependency exception.
- [cargo-modules](https://github.com/regexident/cargo-modules). Module inspection, dependency graphs, and `--acyclic` checks. Use with explicit target and feature choices in the module lesson.
- [cargo-semver-checks](https://github.com/obi1kenobi/cargo-semver-checks). Public Rust API compatibility, including private crates and local baseline options. Use in the API-change lesson, not as an HTTP contract checker.
- [Cargo metadata](https://doc.rust-lang.org/cargo/commands/cargo-metadata.html). Machine-readable package dependencies for requirements an existing policy tool cannot express. [ArchUnitRust crate documentation](https://docs.rs/archunit/latest/archunit/) covers an independent experimental architecture-testing library and its extraction limits; use for a bounded evaluation, not an assumed Java-compatible freeze mechanism.

### Contracts between Java and Rust

- [Pact JVM](https://docs.pact.io/implementation_guides/jvm/readme), [Pact Rust](https://docs.pact.io/implementation_guides/rust), and [Pact specification compatibility](https://docs.pact.io/getting_started/specification). Use for the planned consumer/provider exercise across the migration.
- [Buf breaking-change detection](https://buf.build/docs/breaking/). Use if the actual interface uses Protobuf; distinguish schema compatibility from business behavior.

## Wisdom (Communities)

- [ArchUnit project discussions](https://github.com/TNG/ArchUnit/discussions). Use for concrete rule-modeling questions with a small reproducer; consult the guide first. No participation is required for the course.
- The learner's team provides the adoption context: ask reviewers to explain the intended constraint and inspect a deliberately forbidden example before making a rule a build requirement.

## Gaps

The workplace's Spring Boot/JUnit versions, Rust service protocol, feature combinations, repository layout, and native-interface plans are not yet known. Those details matter for later adoption exercises, not the initial lab. No directly equivalent automatic shrinking freeze store was verified among the researched Rust tools.
