當前位置:
                    首頁 >
                            前端技术
>                            javascript
>内容正文                
                        
                    javascript
Spring Boot——Maven使用SystemPath引用本地jar:ClassNotFoundException
                                                            生活随笔
收集整理的這篇文章主要介紹了
                                Spring Boot——Maven使用SystemPath引用本地jar:ClassNotFoundException
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.                        
                                問題描述
<dependency><groupId>com.dingtalk</groupId><artifactId>dingtalk-api-sdk</artifactId><version>1.0.0-SNAPSHOT</version><scope>system</scope><systemPath>${pom.basedir}/../lib/taobao-sdk-java-auto_1479188381469-20210831.jar</systemPath></dependency>解決方案
<plugins><plugin><groupId>org.springframework.boot</groupId><artifactId>spring-boot-maven-plugin</artifactId><configuration><includeSystemScope>true</includeSystemScope></configuration></plugin> </plugins>以下配置jar包是可以打進去,但是其他jar包就沒了
<build><resources><resource><directory>${project.basedir}/lib</directory><targetPath>BOOT-INF/lib/</targetPath><includes><include>**/*.jar</include></includes></resource><resource><directory>src/main/resources</directory><targetPath>BOOT-INF/classes/</targetPath></resource></resources> </build>參考文章
- springboot借助maven插件system path,加載本地jar
- Spring Boot Maven項目使用SystemPath引用第三方平臺:ClassNotFind錯誤
總結
以上是生活随笔為你收集整理的Spring Boot——Maven使用SystemPath引用本地jar:ClassNotFoundException的全部內容,希望文章能夠幫你解決所遇到的問題。
 
                            
                        - 上一篇: 网易2022秋季校园招聘-通用技术A卷-
- 下一篇: 大学阶段总结——大三
