Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

zhouj-github/spring-boot-jar-loader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

2 Commits

Repository files navigation

一种优雅的springboot插件jar加载方式

实现机制

1.实现springboot启动事件监听接口,springboot启动时会以SPI方式加载
2.在contextLoaded之后,获取当前类加载器,反射调用URLClassLoader的addUrl方法,把插件包的路径,添加到类加载器
3.springboot容器初始化刷新时,插件jar的bean也会被扫描注册(bean路径需在包扫描范围)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

AltStyle によって変換されたページ (->オリジナル) /