ADR-023: Code Structure and Enforcement for the Artifact Registry

Hayley Swimelar
2026-04-03T22:53:02Z

## Summary

Propose and publish ADR-023, which selects the standard Go project layout with package-per-feature organization and compiler-enforced boundaries (`internal/` + depguard) for the Artifact Registry.

## Background

The Artifact Registry will support 15+ package formats developed by 20+ engineers, with AI agents writing many format implementations. Three candidate architectures were evaluated through demo projects (five formats each):

- Standard Go layout (selected)
- Clean Architecture
- DDD + Hexagonal Architecture

The ADR documents measured metrics from the demos, production extrapolation using the container registry as a reference, AI agent context window cost, and cross-cutting change amplification analysis.

## MR

gitlab-com/content-sites/handbook!19213