日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

如何在weblogic启动时让其加载指定的jar库文件

發布時間:2025/3/15 编程问答 36 豆豆
生活随笔 收集整理的這篇文章主要介紹了 如何在weblogic启动时让其加载指定的jar库文件 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

項目使用了某第三方公司提供的一個jar包,且那個jar包必須在容器啟動的classpath內,不能在application的classpath內。

起初是修改weblogic中domain的啟動文件,想把jar的路徑set進去,但是修改了startWeblogic.sh和setDomainEnv.sh都不行,比較郁悶。

后來突然想起,tomcat有個common目錄,下面有個lib目錄,tomcat在啟動的時候會自動加載lib目錄下的jar,那weblogic也應該有個類似的東東才對。

翻了翻weblogic domain的目錄,發現domain下有個lib目錄,里面有個說明文件這么寫到:

this is the domain library directory and is usually located at $DOMAIN_DIR/lib.

The jars located in this directory will be picked up and added dynamically to the end of the server classpath at server startup. The jars will be ordered lexically in the classpath. The domain library directory is one mechanism that can be used for adding application libraries to the server classpath.

It is possible to override the $DOMAIN_DIR/lib directory using the -Dweblogic.ext.dirs system property during startup. This property specifies a list of directories to pick up jars from and dynamically append to the end of the server classpath using java.io.File.pathSeparator as the delimiter between path entries.

意思大致就是,凡是放在這個目錄里的jar文件,都會在weblogic啟動的時候自動追加到classpath里,可以被application引用。

問題圓滿解決,不過解決之前花了好久修改啟動文件 囧rz......

總結

以上是生活随笔為你收集整理的如何在weblogic启动时让其加载指定的jar库文件的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。