Skip to content

Conversation

@angryPodo
Copy link
Owner

This PR enables multi-module support by implementing the ServiceLoader pattern.

Previously, the processor generated a duplicate WispRegistry class for every module, causing build errors. Now, it generates unique WispModuleRegistry_{Hash} classes and automatically registers them via META-INF/services.

Changes:

  • Processor: Generates unique registry names per module.
  • Runtime: Wisp.initialize() now uses ServiceLoader to collect routes from all modules.
  • SPI: Added WispModuleRegistry interface.

Tested with the sample app.

Closes: #22

@angryPodo angryPodo self-assigned this Dec 31, 2025
@angryPodo angryPodo added the FEAT✨ Add a new feature or change the behavior/policy of an existing feature. label Dec 31, 2025
@angryPodo angryPodo linked an issue Dec 31, 2025 that may be closed by this pull request
@angryPodo angryPodo merged commit e5647fe into main Dec 31, 2025
2 checks passed
@angryPodo angryPodo deleted the feat/#22-support-multi-module-architecture branch December 31, 2025 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

FEAT✨ Add a new feature or change the behavior/policy of an existing feature.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Support multi-module architecture

2 participants