9

您好,当我尝试在 glassfish 中部署 ear 应用程序时,我收到了很多这样的警告:

[#|2013-01-14T14:12:52.404+0100|WARNING|glassfish3.1.2|org.apache.jasper.runtime.TldScanner|_ThreadID=34;_ThreadName=Thread-2;|PWC6351: In TLD scanning, the supplied resource file:/usr/local/glassfish3/glassfish/domains/pi/applications/person-ear-1.0-SNAPSHOT-rnull/APP-INF/lib/jaxb-api-2.1.jar does not exist
java.io.FileNotFoundException: /usr/local/glassfish3/glassfish/domains/pi/applications/person-ear-1.0-SNAPSHOT-rnull/APP-INF/lib/jaxb-api-2.1.jar (Nie ma takiego pliku ani katalogu)
    at java.util.zip.ZipFile.open(Native Method)
    at java.util.zip.ZipFile.<init>(ZipFile.java:214)
    at java.util.zip.ZipFile.<init>(ZipFile.java:144)
    at java.util.jar.JarFile.<init>(JarFile.java:152)
    at java.util.jar.JarFile.<init>(JarFile.java:89)


[#|2013-01-14T14:12:52.407+0100|WARNING|glassfish3.1.2|org.apache.jasper.runtime.TldScanner|_ThreadID=34;_ThreadName=Thread-2;|PWC6351: In TLD scanning, the supplied resource file:/usr/local/glassfish3/glassfish/domains/pi/applications/person-ear-1.0-SNAPSHOT-rnull/APP-INF/lib/resolver-20050927.jar does not exist
java.io.FileNotFoundException: /usr/local/glassfish3/glassfish/domains/pi/applications/person-ear-1.0-SNAPSHOT-rnull/APP-INF/lib/resolver-20050927.jar (Nie ma takiego pliku ani katalogu)
    at java.util.zip.ZipFile.open(Native Method)
    at java.util.zip.ZipFile.<init>(ZipFile.java:214)
    at java.util.zip.ZipFile.<init>(ZipFile.java:144)
    at java.util.jar.JarFile.<init>(JarFile.java:152

和其他.... 对我来说,glassfish 似乎不使用他自己的类加载器,但我不确定....

4

1 回答 1

4

您的 pom.xml 中的错误配置可能会导致此问题。maven-war-plugin 可能包含为您的 MANIFEST.MF 自定义类路径的指令。就我而言,我有:

 <manifest>
     <addClasspath>true</addClasspath>
 </manifest>

您应该能够通过简单地注释掉/删除指令来解决它。

于 2014-01-20T00:11:54.460 回答