【问题标题】:The absolute uri: http://www.opensymphony.com/sitemesh/decorator cannot be resolved in either web.xml or the jar files deployed with this application绝对 uri:http://www.opensymphony.com/sitemesh/decorator 无法在 web.xml 或随此应用程序部署的 jar 文件中解析
【发布时间】:2017-05-14 07:17:17
【问题描述】:

使用 jetty-maven-plugin。从 jetty 8 升级到 jetty 9 时出现此错误。

<groupId>org.eclipse.jetty</groupId>
                <artifactId>jetty-maven-plugin</artifactId>
                <version>9.4.0.v20161208</version>

【问题讨论】:

    标签: maven-jetty-plugin jetty-9


    【解决方案1】:

    Jetty 9 无法找到 sitemesh*.jar,即使它在那里。 因此,您必须将以下代码添加到您的 jetty-context.xml 以使其工作:

    <Configure class="org.eclipse.jetty.maven.plugin.JettyWebAppContext">
        <Call name="setAttribute">
            <Arg>org.eclipse.jetty.server.webapp.WebInfIncludeJarPattern</Arg>
            <Arg>^$|.*/sitemesh-[^/]*\.jar$</Arg>
        </Call>
    </Configure>
    

    在此处添加您希望码头扫描的所有其他 jar 名称。

    【讨论】:

      猜你喜欢
      • 2012-01-31
      • 1970-01-01
      • 2013-10-21
      • 2012-04-16
      • 2014-02-15
      • 1970-01-01
      相关资源
      最近更新 更多