我是靠谱客的博主 包容康乃馨,这篇文章主要介绍Springboot引入本地Jar包文件(亲测可用),现在分享给大家,希望可以做个参考。

  1. 在resources文件下新建lib文件夹,将jar包放到该文件夹下。

 

2.在pom.xml文件中这样引入:

 <dependency>
            <groupId>com.sqljdbc</groupId>
            <artifactId>com.sqljdbc4</artifactId>
            <version>4.0</version>
            <scope>system</scope>
         <systemPath>${project.basedir}/src/main/resources/lib/sqljdbc4.jar</systemPath>
</dependency>
  <build>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <includeSystemScope>true</includeSystemScope>
                </configuration>
            </plugin>
  

        </plugins>
    </build>

完成!

最后

以上就是包容康乃馨最近收集整理的关于Springboot引入本地Jar包文件(亲测可用)的全部内容,更多相关Springboot引入本地Jar包文件(亲测可用)内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(127)

评论列表共有 0 条评论

立即
投稿
返回
顶部