老师我每次保存web.xml文件特别慢,一直转圈,假死。啥原因啊?

老师我每次保存web.xml文件特别慢,一直转圈,假死。啥原因啊?

<?xml version="1.0" encoding="UTF-8"?>

<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://xmlns.jcp.org/xml/ns/javaee" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd" id="WebApp_ID" version="4.0">

  <display-name>First</display-name>

  <welcome-file-list>

    <welcome-file>index.html</welcome-file>

    <welcome-file>index.htm</welcome-file>

    <welcome-file>index.jsp</welcome-file>

    <welcome-file>default.html</welcome-file>

    <welcome-file>default.htm</welcome-file>

    <welcome-file>default.jsp</welcome-file>

</welcome-file-list>

</web-app>


我的使用的tmocat9 jdk15

正在回答

登陆购买课程后可参与讨论,去登陆

2回答

同学你好,从截图上看,显示应该是警告,而不是报错。如果是警告,不影响程序运行,是可以忽略的。另外建议同学可以使用注解代码web.xml的编写。

祝学习愉快~

  • 慕用4915122 提问者 #1

    http://img1.sycdn.imooc.com//climg/5ffae07209fab31b08050643.jpg

    老师,我看网上说吧这个去掉就不卡了。我试了一下确实行,是什么原理啊?

    2021-01-10 19:10:06
  • 慕用4915122 提问者 #2

    记上个问题,去掉那个对以后的程序有影响吗?

    2021-01-10 19:12:04
  • 好帮手慕阿满 回复 提问者 慕用4915122 #3

    同学你好,可能是Java EE Navigator Content WEB提供WEB内容加载校验等。去掉后应该对程序应该没有什么影响,如果影响程序运行,同学可以重新勾选上。

    祝学习愉快~

    2021-01-11 14:51:59
好帮手慕阿满 2021-01-10 15:29:26

同学你好,这个可能和tomcat以及jdk的版本有关。这里建议同学将如下空格改成分号(注意是英文状态下的分号)再试试。

http://img1.sycdn.imooc.com//climg/5ffaaca3091ff80b08440199.jpg

祝学习愉快~

  • 提问者 慕用4915122 #1

    http://img1.sycdn.imooc.com//climg/5ffad00909c29ee812070098.jpg

    http://img1.sycdn.imooc.com//climg/5ffad0150949579f09440084.jpg

    老师报错了

    2021-01-10 18:00:01
问题已解决,确定采纳
还有疑问,暂不采纳

恭喜解决一个难题,获得1积分~

来为老师/同学的回答评分吧

0 星
请稍等 ...
意见反馈 帮助中心 APP下载
官方微信

在线咨询

领取优惠

免费试听

领取大纲

扫描二维码,添加
你的专属老师