扩展的战争文件更快吗?
我正在使用嵌入式码头启动一个 Web 应用程序,目前我已将其打包为 war 文件。起初我试图阻止我的战争档案被扩大;然后我开始想:
问:jetty扩展war文件内容有什么好处吗?
即使速度较慢...
问:我怎样才能防止码头扩展它(或至少每次扩展它)。
我的设置如下所示: 在注意到我的 JSP 被扔进 Windows 临时目录后,我通过 JVM 设置 (-Djava.io.tmpdir=deploy/temp
) 设置了 I/O 临时目录。
<bean id="myAppContext" class="org.eclipse.jetty.webapp.WebAppContext">
<property name="contextPath" value="/myApp" />
<property name="war" value="${my.warfile.name}" />
<!--
<property name="extractWAR" value="false" />
<property name="copyWebDir" value="false" />
<property name="parentLoaderPriority" value="true" />
-->
<property name="extraClasspath" value="deploy/config" />
</bean>
我尝试在 jetty WebAppContext 上设置各种选项(顺便说一句,jetty 7 javadoc 中没有很好地记录它们)。他们似乎没有做任何有用的事情,所以我将它们注释掉了。
I'm using embedded jetty to launch a web application which I have currently packaged as a war file. At first I was trying to prevent my war file from being expanded; then I began to wonder:
Q: is there some advantage for jetty to expand the war file contents?
And even if its slower...
Q: how can I prevent jetty from expanding it (or at least expanding it every time).
My setup looks like this:
I have set the I/O temp dir, via the JVM setting (-Djava.io.tmpdir=deploy/temp
) after noticing that my JSPs were being thrown into the Windows temp directory.
<bean id="myAppContext" class="org.eclipse.jetty.webapp.WebAppContext">
<property name="contextPath" value="/myApp" />
<property name="war" value="${my.warfile.name}" />
<!--
<property name="extractWAR" value="false" />
<property name="copyWebDir" value="false" />
<property name="parentLoaderPriority" value="true" />
-->
<property name="extraClasspath" value="deploy/config" />
</bean>
I tried setting the various options on the jetty WebAppContext (they are not well documented in jettty 7 javadoc btw). They didn't seem to do anything helpful, so I commented them out.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论