mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-12-03 03:31:32 +00:00
Stop reserving namespaces, let a jar list several modules and add ModuleJarCheck for builds that write module jars
ReservedNamespaces and ModuleHost.reservingNamespaces are gone: a pack module may use any namespace, iris included. A module id is still loaded once, and the duplicate error now names the origin and class of both modules, so two modules of one jar can be told apart. A jar lists one module class per line in META-INF/services/com.volmit.IrisModule and loads all of them in that order; each class must still be defined in the jar. A jar with several modules is excused by the optional packages of all of them. ModuleJarCheck runs the load's class checks on one jar without loading it.
This commit is contained in:
1 parent
ef4b640867
commit
42d31a9ce4
21 files changed
+330
-208
No files matched your search
+2
-2
@@ -10,7 +10,7 @@ types that carry them and lists what the Iris adapter still owes.
|
||||
| Module identity and composition | `IrisModule`, `ModuleInfo` (with optional packages), `StageGraph` |
|
||||
| Loading and unloading a pack | host `LoadedPack`, `ModuleHost` |
|
||||
| Module jars in a pack | `META-INF/services/com.volmit.IrisModule`, host `PackModules` (jar copies), `DiscoveredModule`, `MissingClasses` |
|
||||
| Namespace ownership | module-prefixed stage, feature and mantle ids, `ModuleInfo.ownsStage`/`ownsId`, `ModuleHost.reservingNamespaces` |
|
||||
| Namespace ownership | module-prefixed stage, feature and mantle ids, `ModuleInfo.ownsStage`/`ownsId`; no reserved namespaces |
|
||||
| Randomness independent of other modules | `StageContext.random()`, host `StageStreams`, invocation seed passed to the runners |
|
||||
| Random values identical on every JDK | `WorldRandom`, pinned by `WorldRandomTest` |
|
||||
| Module-owned work and ordering | `Stage`, `StageRef`, stage definitions, `requires`/`softAfter`/`softBefore` |
|
||||
@@ -112,7 +112,7 @@ running Iris is the pack publisher's responsibility.
|
||||
storage. Abort chunk publication when any stage fails.
|
||||
- Preserve unknown persisted mantle layers or fail explicitly.
|
||||
- Build one `ModuleHost` at startup with the built-in modules, exposed packages, reserved JSON
|
||||
fields and `reservingNamespaces("iris")`. Its methods accumulate, so the configuration can be
|
||||
fields. Its methods accumulate, so the configuration can be
|
||||
built in steps. Load each pack with `LoadedPack.load(packRoot, host)`
|
||||
and close it only after nothing built from it is in use.
|
||||
- Pass a `System.Logger` that writes to the server log to `ModuleHost.loggingTo(...)`, so the
|
||||
|
||||
Reference in new issue
Block a user