47 lines
2.7 KiB
Markdown
47 lines
2.7 KiB
Markdown
# Internal Component Overview
|
|
|
|
ConfigKit exposes one supported root `configkit` package. The root owns public
|
|
named types, declaration comments, constructors, and explicit conversion/wrapper
|
|
code. It delegates loading and frozen inspection to `internal/engine` through
|
|
private state; public signatures and fields do not expose engine types.
|
|
|
|
Implemented component owners:
|
|
|
|
- `internal/engine` owns host and native-filesystem source acquisition,
|
|
grouped strict composition, recursive precedence assembly, and destination-local
|
|
sibling inheritance before typed decoding. It also owns schema
|
|
inspection, lifecycle coordination, callback auditing,
|
|
provenance/history, passive source-context retention, secret resolution and
|
|
bootstrap, and safe inspection rendering. It never imports the root package.
|
|
- Root `Source`, `Filesystem`, `Input`, `Underlay`, `Path`, `Secret`, records,
|
|
lifecycle callbacks, results, and bootstrap reports are root-defined wrappers
|
|
or records. Callback wrappers pass only live engine context during a callback;
|
|
`Result.Config` is detached and its private inspection remains frozen
|
|
independently.
|
|
- Root conversion files explicitly cross the path, record, callback, secret, and
|
|
error boundaries. There are no public aliases, anonymous engine embeddings, or
|
|
public engine bridge methods.
|
|
- `internal/document` owns the parser-independent ordered tree and cloning.
|
|
`internal/yaml` is the sole upstream YAML adapter and parser/dumper boundary.
|
|
- Engine mechanism tests own source, composition, inheritance, decoding,
|
|
callback, provenance,
|
|
source-context, secret, history, rendering, and bootstrap behavior. Root tests
|
|
own public API compatibility, facade integration, documentation links, and
|
|
dependency/public boundary checks. Consumer examples remain under
|
|
`examples/consumers`.
|
|
|
|
Dependency direction is root to engine to document/YAML support. The root may
|
|
import only `internal/engine` among project internal production packages; engine
|
|
and its supporting packages do not import root. The root boundary test enforces
|
|
these constraints and rejects exported aliases, fields, or signatures involving
|
|
internal types.
|
|
|
|
The [configuration contract](../config.md) owns implemented YAML and lifecycle
|
|
semantics. The [consumer adoption guide](../consumers/README.md) owns application
|
|
guidance. The [architecture policy](../policy/architecture.md) owns contributor
|
|
boundaries, and [ADR 0006](../adr/0006-public-facade.md) records the facade
|
|
decision. See the [development guide](../development.md) for validation commands
|
|
and [release procedure](../release.md) for source-candidate gates. [ADR
|
|
0009](../adr/0009-sibling-inheritance.md) records why inheritance is a built-in
|
|
post-assembly structural operation.
|