title: What does a Servlet 3.0 compatible web-app declaration in web.xml do?
body: <p>I am deploying a web application that is declared in web.xml and deployed as a .war file. </p>
  
  <p>I am deploying on Jetty 9.1.x (but I think this question is not container specific). </p>
  
  <p>My web.xml file is quite old and declares itself as a Servlet 2.4 application: </p>
  
  <pre><code>&lt;web-app version="2.4" id="my_app"
       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/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"&gt;
  </code></pre>
  
  <p>My configuration actually declares some Servlet 3.0 only features, like a default error page. These features do not validate according to the schema, but the features <em>seem</em> to work correctly. </p>
  
  <p>Since I am using 3.0 features, I would like to change the declaration to be correct: </p>
  
  <pre><code>&lt;web-app 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_3_0.xsd"
       version="3.0"&gt;
  </code></pre>
  
  <p>But I am scared to do this because I don't understand what the difference will be to Jetty. </p>
  
  <p>Will changing the declaration have any effect on the runtime behavior of Jetty? Does Jetty treat a 2.4 app somehow differently than a 3.0 app? </p>