2

In my Eclipse Oxygen, I get this error on every save.

From reading around, it seems to come from some version incompatibility in the Servlet standard used but I am not sure what is incompatible with what.

How do I fix this?

An internal error occurred during: "Loading descriptor for project1.". org.eclipse.emf.ecore.xmi.FeatureNotFoundException: Feature 'init-param' not found. (platform:/resource/project1/war/WEB-INF/web.xml, 72, 14)

Joshua Fox
  • 18,704
  • 23
  • 87
  • 147

1 Answers1

0

Here is a screenshot of a similar problem

The problem is that the DTD specified in web.xml, generally specified in the web-app element, does not match the actual structure of the web.xml. The error message points to the line (circled in the screenshot) in the web.xml document which is problematic.

<?xml version = '1.0' encoding = 'UTF-8'?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">

So either

  1. remove the DTD (it is not necessary, but it is helpful to show your incompatibilities)
  2. update the web.xml to fit the DTD
  3. update the DTD to fit the web.xml
gordon613
  • 2,770
  • 12
  • 52
  • 81