zoukankan      html  css  js  c++  java
  • glassfish PWC6351: In TLD scanning 系统找不到指定的文件问题解决

    [2017-04-25T21:26:09.391+0800] [glassfish 4.1] [WARNING] [] [org.apache.jasper.runtime.TldScanner] [tid: _ThreadID=52 _ThreadName=admin-listener(4)] [timeMillis: 1493126769391] [levelValue: 900] [[
    PWC6351: In TLD scanning, the supplied resource file:/F:/server/glassfish-4.1.2/glassfish/domains/domain1/applications/javaee-api-6.0.jar does not exist
    java.io.FileNotFoundException: F:serverglassfish-4.1.2glassfishdomainsdomain1applicationsjavaee-api-6.0.jar (系统找不到指定的文件。)

    google以上问题,大多说是以上问题是警告,可以忽略。原因:It would be helpful if the warnings tell you which jars that has bad manifest class-path

    日志的路径确实不对,然后又知道了原因出自has bad manifest class-path,于是打开war包下的META-INF/MANIFEST.MF,发现Class-Path的所有jar包都没有带路径,

    于是手动加上试试,果真没有以上错误了。

    然而不能每次去改这个路径,于是找到解决办法:

           <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-war-plugin</artifactId>
                    <configuration>
                        <archive>
                            <manifest>
                                <addClasspath>true</addClasspath>
                                <classpathPrefix>/${build.finalName}/WEB-INF/lib/</classpathPrefix>
                            </manifest>
                        </archive>
                    </configuration>
                </plugin>

    加上

    <classpathPrefix>/${build.finalName}/WEB-INF/lib/</classpathPrefix>

    MANIFEST.MF就都加上了这个前缀,问题就解决了。
  • 相关阅读:
    多线程 -- H2O 生成、交替打印字符串
    打印零与奇偶数
    h2数据库的使用
    rtx应用和开发
    MongoDB--副本集
    Python 推导式
    Bootstrap组件
    Python logging日志的自动分割
    python watchdog监控文件修改
    Linux流量监控iftop
  • 原文地址:https://www.cnblogs.com/jay763190097/p/6764733.html
Copyright © 2011-2022 走看看