v5.1.0 (2026-09-08)
<dependency>
<groupId>net.hasor</groupId>
<artifactId>hasor-core</artifactId>
<version>5.1.0</version>
</dependency>
This version improves diagnostics during Bean creation, Web root-path mapping and static resource access, and module ownership of startup extensions.
Scope
- Core Bean creation and primary source registration, Web routes, static resources, and Servlet lifecycle
Changes
- Added
- Add
CircularDependencyExceptionto report the dependency chain when Bean creation encounters a cycle, covering creation by type, constructor, and custom object provider. - Support URL prefixes and welcome files in
ResourceFilterto map designated access paths to resource directories. - Allow
RuntimeListenerto createAppContextthrough a factory function stored in ServletContext, enabling integration with external startup workflows.
- Add
- Improved
- Recognize the installed-module marker when registering primary sources, avoiding repeated creation and binding of already registered modules.
- Move embedded HTTP container APIs out of the Web kernel to separate request processing from container startup.
- Fixed
- Fix route format validation rejecting the root path
/. - Use application-relative request paths for static resource lookup, avoiding treating the context path as a resource path when deployed under a non-root contextPath.
- Check initialization state during Servlet context destruction to avoid further null-pointer exceptions after incomplete initialization.
- Fix route format validation rejecting the root path
Upgrade notes
- Move
WebServer,WebServers,WebServerConfig, and container SPI fromnet.hasor.web.httpinto thenet.hasor.boot.webpackage ofhasor-boot-web. Update dependencies and imports when using these types directly. - Core no longer assembles the original
StartupModuleand annotation AOP extension module by default. Applications depending onhasor.startupor the originalnet.hasor.core.exts.aopmust adjust startup configuration or add the corresponding extension. Programmatic interceptor binding in Core remains available. - Circular dependencies now produce an explicit error and dependency chain. Correct the dependency relationships rather than relying on recursive object creation.
ResourceFilter(loader, urlPrefix)usesindex.htmlas its default welcome file. Use the three-argument constructor for a different file; the original single-argument constructor remains available.