A case of invalid Servlet3.0 annotations

Source: Internet
Author: User

The deployment profile for Servlet 3.0 The top-level label for Web. XML has a Metadata-complete property that specifies whether the current deployment profile is complete. If set to true, the container will only rely on the deployment profile at deployment time, ignoring all annotations (also skipping web-fragment.xml scans, i.e. disabling pluggable support, see the following for pluggable support); If you do not configure this property, or set it to False to enable annotation support (and pluggable support) annotations valid Web. XML

<?xml version= "1.0" encoding= "iso-8859-1"?> <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/ Java EE
                      http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd "
  version=" 3.0 ">
invalid annotations for Web. XML
<?xml version= "1.0" encoding= "iso-8859-1"?> <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 "metadata-complete=" t Rue "> </web-app> 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.