如何在SpringBoot中配置其他类路径? [英] How to configure additional classpath in SpringBoot?
问题描述
我想制作一个独立的Web应用程序.我在SpringBoot上遇到一些问题.
I want to make a standalone web application. I have some problems with SpringBoot.
我的应用程序是SpringBoot中的一个jar文件.
My application is one jar file from SpringBoot.
但是我的应用程序通常是需要jdbc驱动程序jar的.我想为我的应用程序排除jdbc驱动程序jar,然后从lib文件夹中读取库jar.
But my application was usually needed jdbc driver jar. I want to exclude the jdbc driver jar for my application and read the library jar from the lib folder.
但是SpringBoot的lib文件夹是BOOT-INF/lib
是final static
.因此,我想为jdbc驱动程序jar添加外部类路径(lib).
But SpringBoot lib folder is BOOT-INF/lib
is final static
. So, I want to add external classpath (lib) for the jdbc driver jar.
如何在SpringBoot中配置其他类路径.有空吗?
How to configure additional classpath in SpringBoot. Is it available?
推荐答案
您可以在Spring Boot中引用以下链接:
You may refer this below link from spring boot: