Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Eclipse Web Tools Platform Project (WTP) » Java EE: web.xml Validation Error(How do I get rid of this error? Problems with web.xml validation in Eclipse for Java EE.)
Java EE: web.xml Validation Error [message #1840501] Fri, 16 April 2021 15:51 Go to next message
John Smith is currently offline John SmithFriend
Messages: 3
Registered: April 2021
Junior Member
Hello,

How do I get rid of this error?

I'm having an issue where Eclipse fails to validate the standard web.xml document for Java EE. It's weird, because just modifying the file and saving fixes the error. However restarting Eclipse brings back the issue.

EDIT: The web.xml document is as follows:

<?xml version="1.0" encoding="UTF-8"?>
<web-app version="4.0"
	xmlns="http://xmlns.jcp.org/xml/ns/javaee"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd">
<!-- ... -->
</web-app>


On the <web-app ...> tag, I get the error : "There is '1' error in 'javaee_7.xsd'" There's also a warning on the URLs listed on xsi:schemaLocation:

"schema_reference.4: Failed to read schema document 'platform:/plugin/org.eclipse.xsd/cache/www.w3.org/
 2001/xml.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element 
 of the document is not <xsd:schema>."


Eclipse IDE for Enterprise Java and Web Developers (includes Incubating components)
Version: 2021-03 (4.19.0)
Build id: 20210312-0638
OS: Windows 10, v.10.0, x86_64 / win32
Java version: 15.0.2

Configuration Log attached. How do I get rid of this error? Any help is appreciated!

[Updated on: Sat, 17 April 2021 14:00]

Report message to a moderator

Re: Java EE: web.xml Validation Error [message #1840515 is a reply to message #1840501] Sat, 17 April 2021 04:57 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4435
Registered: July 2009
Senior Member

Which error are you referring to?

_
Nitin Dahyabhai
Eclipse Web Tools Platform
Re: Java EE: web.xml Validation Error [message #1840520 is a reply to message #1840515] Sat, 17 April 2021 13:58 Go to previous messageGo to next message
John Smith is currently offline John SmithFriend
Messages: 3
Registered: April 2021
Junior Member
Sorry, I had to make the first post without any links, as the forum software doesn't allow new users to post links in their first post. I'm editing the OP with the details now.

EDIT: The web.xml document is as follows:

<?xml version="1.0" encoding="UTF-8"?>
<web-app version="4.0"
	xmlns="http://xmlns.jcp.org/xml/ns/javaee"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd">
<!-- ... -->
</web-app>


On the <web-app ...> tag, I get the error : "There is '1' error in 'javaee_7.xsd'" There's also a warning on the URLs listed on xsi:schemaLocation:

"schema_reference.4: Failed to read schema document 'platform:/plugin/org.eclipse.xsd/cache/www.w3.org/
 2001/xml.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element 
 of the document is not <xsd:schema>."

[Updated on: Sat, 17 April 2021 14:00]

Report message to a moderator

Re: Java EE: web.xml Validation Error [message #1840523 is a reply to message #1840520] Sat, 17 April 2021 16:10 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4435
Registered: July 2009
Senior Member

When you restart Eclipse and see the error anew, is it shown in the editor and the Problems View, and does
it disappear from the Problems view if you close the editor without saving?


_
Nitin Dahyabhai
Eclipse Web Tools Platform
Re: Java EE: web.xml Validation Error [message #1840530 is a reply to message #1840523] Sat, 17 April 2021 22:22 Go to previous messageGo to next message
John Smith is currently offline John SmithFriend
Messages: 3
Registered: April 2021
Junior Member
Nitin Dahyabhai wrote on Sat, 17 April 2021 16:10
When you restart Eclipse and see the error anew, is it shown in the editor and the Problems View, and does
it disappear from the Problems view if you close the editor without saving?

The error is shown in both the editor and the Problems view.
Yes, it does disappear from the Problems view if I close the editor without saving.
Re: Java EE: web.xml Validation Error [message #1840531 is a reply to message #1840530] Sat, 17 April 2021 23:18 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4435
Registered: July 2009
Senior Member

That's indicative of it being related to the Wild Web Developer and Lemminx projects. You probably need to file
an issue at https://github.com/eclipse/lemminx and see what they say.


_
Nitin Dahyabhai
Eclipse Web Tools Platform
Re: Java EE: web.xml Validation Error [message #1847310 is a reply to message #1840531] Fri, 22 October 2021 10:43 Go to previous message
Rogério Marchiori is currently offline Rogério MarchioriFriend
Messages: 1
Registered: October 2021
Junior Member
I tried uninstall Wild Web Developer, the error keep ocurring. If you edit the faces-config.xml the error fades away. When restart the IDE, the error return.

To reproduce:
- install eclipse 2021-09 for javaee. Create web application, include jsf faces.

Previous Topic:Do I need Eclipse Web Developer Tools
Next Topic:War not correctly assembled from Maven project structure?
Goto Forum:
  


Current Time: Tue Apr 23 05:30:10 GMT 2024

Powered by FUDForum. Page generated in 0.03602 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top