Today in the work flow, tomcat7.0.57 always error, parse the Web. XML Reference Joa.xml.
<?xml version= "1.0" encoding= "UTF-8"?>
<! DOCTYPE Web-app
[<! ENTITY Joa SYSTEM "Joa.xml" >]>
<web-app xmlns:xsi= "Http://www.w3.org/2001/XMLSchema-instance"
xmlns= "Http://java.sun.com/xml/ns/javaee" xmlns:web= "http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemalocation= "Http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version= "3.0" >
After finding the data found:
Tomcat 7.0.52 The beginning of the version before this problem,
is because of the security considerations Tomcat 7.0.52 The beginning of the version of the Xmlblockexterna property defaults to False, to solve this problem,
Two methods:
1. Replace the Tomcat version with the previous version of 7.0.52.
2, set the Xmlblockexterna to False.
The following is the original explanation:
as per discussion with Tomcat developers, xmlblockexternal= "false" attribute of Tomcat ' s context (context . xml) is set true by default starting from 7.0.52. With xmlblockexternal= "false" generated/djn-settings.conf can is included.
<context xmlblockexternal= "false" >
<!--Default set of monitored resources--
<WatchedResource>WEB-INF/web.xml</WatchedResource>
<!--uncomment this to disable session persistence across Tomcat restarts-
<!--
<manager pathname= ""/>
-
<!--uncomment this to enable Comet connection tacking (provides events
On session expiration as well as WebApp lifecycle)--
<!--
<valve classname= "Org.apache.catalina.valves.CometConnectionManagerValve"/>
-
</Context>
After solving this problem, a new problem arises:
TOMCAT7 start error: caused By:java.lang.noclassdeffounderror:lorg/apache/annotationprocessor, then find the data solution:
Create a Org.apache under the project:
Package Org.apache;
Import java.lang.reflect.InvocationTargetException;
Import javax.naming.NamingException;
/**
* @author Dong Zhibo
* @date 2015-8-17
* @description
* @Version 1.0
*/
Public interface Annotationprocessor {
public void postconstruct (Object instance) throws Illegalaccessexception,
invocationtargetexception;
public void Predestroy (Object instance) throws Illegalaccessexception,
invocationtargetexception;
public void processannotations (Object instance)
throws Illegalaccessexception, InvocationTargetException,
namingexception;
}
Due to time problems, the reason is not yet known. Cond.......
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Web. Xml introduced (Tomcat 7.0.52) above version of this report wrong!