How to embed Tomcat 6?
问题 I'm currently running my webapps on Tomcat 6 in production, and would like to evaluate running Tomcat in embedded mode. Is there a good tutorial or other resource besides what's in the api documentation? 回答1: Code speaks for itself. See the pom.xml snippet and the class to run tomcat. <dependency> <groupId>org.apache.tomcat</groupId> <artifactId>catalina</artifactId> <version>6.0.18</version> <scope>test</scope> </dependency> <dependency> <groupId>org.apache.tomcat</groupId> <artifactId