Add FeatureRegistry.registerSettings and the @Ref annotation for value references

Modules register settings types that no stage names in when(...) explicitly; the
id must be the module's id or below it, and repeating it or also naming the type
in when(...) changes nothing. A type its owner registered may be named by any
module. OptionsMetadata.Option now carries its field and @Ref reference.
This commit is contained in:
piexel committed 2026-10-06 12:06:46 +02:00
1 parent 8b7accd19d
commit 93c755ffe4
9 files changed
+164 -23

No files matched your search

@@ -35,7 +35,7 @@ public record LoadedModules(FeatureCatalog catalog, ResolvedGraph placement, Res
for (var discovered : modules) {
installModule(discovered, stages, registry);
}
stages.settingsTypes().forEach(registry::registerSettings);
stages.settingsTypes(registry::registeredByOwner).forEach(registry::registerStageSettings);
return new LoadedModules(registry.freeze(), stages.resolve(Pipeline.PLACEMENT), stages.resolve(Pipeline.CHUNK));
}