1.我根据新建一个struts工程之后,启动报错,如下:
1 六月 29, 2015 3:08:18 下午 org.apache.catalina.core.AprLifecycleListener init 2 信息: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\software\myeclipse\install\binary\com.sun.java.jdk7.win32.x86_1.7.0.u45\bin;D:\software\myeclipse\install\plugins\com.genuitec.eclipse.easie.tomcat.myeclipse_11.0.0.me201211151802\tomcat\bin 3 六月 29, 2015 3:08:18 下午 org.apache.coyote.http11.Http11Protocol init 4 信息: Initializing Coyote HTTP/1.1 on http-8080 5 六月 29, 2015 3:08:18 下午 org.apache.catalina.startup.Catalina load 6 信息: Initialization processed in 579 ms 7 六月 29, 2015 3:08:18 下午 org.apache.catalina.core.StandardService start 8 信息: Starting service Catalina 9 六月 29, 2015 3:08:18 下午 org.apache.catalina.core.StandardEngine start 10 信息: Starting Servlet Engine: Apache Tomcat/6.0.13 11 六月 29, 2015 3:08:20 下午 org.apache.struts2.dispatcher.Dispatcher error 12 严重: Dispatcher initialization failed 13 java.lang.RuntimeException: java.lang.reflect.InvocationTargetException 14 at com.opensymphony.xwork2.inject.ContainerImpl$MethodInjector.inject(ContainerImpl.java:301) 15 at com.opensymphony.xwork2.inject.ContainerImpl$ConstructorInjector.construct(ContainerImpl.java:438) 16 at com.opensymphony.xwork2.inject.ContainerBuilder$5.create(ContainerBuilder.java:207) 17 at com.opensymphony.xwork2.inject.Scope$2$1.create(Scope.java:51) 18 at com.opensymphony.xwork2.inject.ContainerBuilder$3.create(ContainerBuilder.java:93) 19 at com.opensymphony.xwork2.inject.ContainerBuilder$7.call(ContainerBuilder.java:487) 20 at com.opensymphony.xwork2.inject.ContainerBuilder$7.call(ContainerBuilder.java:484) 21 at com.opensymphony.xwork2.inject.ContainerImpl.callInContext(ContainerImpl.java:584) 22 at com.opensymphony.xwork2.inject.ContainerBuilder.create(ContainerBuilder.java:484) 23 at com.opensymphony.xwork2.config.impl.DefaultConfiguration.createBootstrapContainer(DefaultConfiguration.java:351) 24 at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:235) 25 at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67) 26 at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967) 27 at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435) 28 at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479) 29 at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74) 30 at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57) 31 at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275) 32 at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397) 33 at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:108) 34 at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3693) 35 at org.apache.catalina.core.StandardContext.start(StandardContext.java:4340) 36 at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791) 37 at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771) 38 at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525) 39 at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920) 40 at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883) 41 at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492) 42 at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138) 43 at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311) 44 at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) 45 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053) 46 at org.apache.catalina.core.StandardHost.start(StandardHost.java:719) 47 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045) 48 at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) 49 at org.apache.catalina.core.StandardService.start(StandardService.java:516) 50 at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) 51 at org.apache.catalina.startup.Catalina.start(Catalina.java:566) 52 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 53 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 54 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 55 at java.lang.reflect.Method.invoke(Method.java:606) 56 at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288) 57 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) 58 Caused by: java.lang.reflect.InvocationTargetException 59 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 60 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 61 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 62 at java.lang.reflect.Method.invoke(Method.java:606) 63 at com.opensymphony.xwork2.inject.ContainerImpl$MethodInjector.inject(ContainerImpl.java:299) 64 ... 43 more 65 Caused by: java.lang.ExceptionInInitializerError 66 at com.opensymphony.xwork2.ognl.OgnlValueStackFactory.setContainer(OgnlValueStackFactory.java:84) 67 ... 48 more 68 Caused by: java.lang.IllegalArgumentException: Javassist library is missing in classpath! Please add missed dependency! 69 at ognl.OgnlRuntime.<clinit>(OgnlRuntime.java:168) 70 ... 49 more 71 Caused by: java.lang.ClassNotFoundException: javassist.ClassPool 72 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1358) 73 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204) 74 at java.lang.Class.forName0(Native Method) 75 at java.lang.Class.forName(Class.java:190) 76 at ognl.OgnlRuntime.<clinit>(OgnlRuntime.java:165) 77 ... 49 more 78 79 六月 29, 2015 3:08:20 下午 org.apache.catalina.core.StandardContext filterStart 80 严重: Exception starting filter struts2 81 java.lang.reflect.InvocationTargetException - Class: com.opensymphony.xwork2.inject.ContainerImpl$MethodInjector 82 File: ContainerImpl.java 83 Method: inject 84 Line: 301 - com/opensymphony/xwork2/inject/ContainerImpl.java:301:-1 85 at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:493) 86 at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74) 87 at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57) 88 at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275) 89 at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397) 90 at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:108) 91 at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3693) 92 at org.apache.catalina.core.StandardContext.start(StandardContext.java:4340) 93 at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791) 94 at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771) 95 at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525) 96 at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920) 97 at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883) 98 at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492) 99 at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138) 100 at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311) 101 at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) 102 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053) 103 at org.apache.catalina.core.StandardHost.start(StandardHost.java:719) 104 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045) 105 at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) 106 at org.apache.catalina.core.StandardService.start(StandardService.java:516) 107 at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) 108 at org.apache.catalina.startup.Catalina.start(Catalina.java:566) 109 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 110 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 111 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 112 at java.lang.reflect.Method.invoke(Method.java:606) 113 at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288) 114 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) 115 Caused by: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException 116 at com.opensymphony.xwork2.inject.ContainerImpl$MethodInjector.inject(ContainerImpl.java:301) 117 at com.opensymphony.xwork2.inject.ContainerImpl$ConstructorInjector.construct(ContainerImpl.java:438) 118 at com.opensymphony.xwork2.inject.ContainerBuilder$5.create(ContainerBuilder.java:207) 119 at com.opensymphony.xwork2.inject.Scope$2$1.create(Scope.java:51) 120 at com.opensymphony.xwork2.inject.ContainerBuilder$3.create(ContainerBuilder.java:93) 121 at com.opensymphony.xwork2.inject.ContainerBuilder$7.call(ContainerBuilder.java:487) 122 at com.opensymphony.xwork2.inject.ContainerBuilder$7.call(ContainerBuilder.java:484) 123 at com.opensymphony.xwork2.inject.ContainerImpl.callInContext(ContainerImpl.java:584) 124 at com.opensymphony.xwork2.inject.ContainerBuilder.create(ContainerBuilder.java:484) 125 at com.opensymphony.xwork2.config.impl.DefaultConfiguration.createBootstrapContainer(DefaultConfiguration.java:351) 126 at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:235) 127 at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67) 128 at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967) 129 at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435) 130 at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479) 131 ... 29 more 132 Caused by: java.lang.reflect.InvocationTargetException 133 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 134 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 135 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 136 at java.lang.reflect.Method.invoke(Method.java:606) 137 at com.opensymphony.xwork2.inject.ContainerImpl$MethodInjector.inject(ContainerImpl.java:299) 138 ... 43 more 139 Caused by: java.lang.ExceptionInInitializerError 140 at com.opensymphony.xwork2.ognl.OgnlValueStackFactory.setContainer(OgnlValueStackFactory.java:84) 141 ... 48 more 142 Caused by: java.lang.IllegalArgumentException: Javassist library is missing in classpath! Please add missed dependency! 143 at ognl.OgnlRuntime.<clinit>(OgnlRuntime.java:168) 144 ... 49 more 145 Caused by: java.lang.ClassNotFoundException: javassist.ClassPool 146 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1358) 147 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204) 148 at java.lang.Class.forName0(Native Method) 149 at java.lang.Class.forName(Class.java:190) 150 at ognl.OgnlRuntime.<clinit>(OgnlRuntime.java:165) 151 ... 49 more 152 153 六月 29, 2015 3:08:20 下午 org.apache.catalina.core.StandardContext start 154 严重: Error filterStart 155 六月 29, 2015 3:08:20 下午 org.apache.catalina.core.StandardContext start 156 严重: Context [/struts2] startup failed due to previous errors 157 六月 29, 2015 3:08:21 下午 org.apache.coyote.http11.Http11Protocol start 158 信息: Starting Coyote HTTP/1.1 on http-8080 159 六月 29, 2015 3:08:21 下午 org.apache.jk.common.ChannelSocket init 160 信息: JK: ajp13 listening on /0.0.0.0:8009 161 六月 29, 2015 3:08:21 下午 org.apache.jk.server.JkMain start 162 信息: Jk running ID=0 time=0/36 config=null 163 六月 29, 2015 3:08:21 下午 org.apache.catalina.startup.Catalina start 164 信息: Server startup in 2853 ms
后来我在网上查找,发现是struts2.3.24运行起来,不仅需要几个基本的jar包,还需要javassist-3.11.0.GA.jar,我添加这个jar包到工程中,如下图:
然后再次运行这个struts2工程,然后发现报错发生了变化,如下图:
1 六月 29, 2015 3:09:26 下午 org.apache.catalina.core.AprLifecycleListener init 2 信息: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\software\myeclipse\install\binary\com.sun.java.jdk7.win32.x86_1.7.0.u45\bin;D:\software\myeclipse\install\plugins\com.genuitec.eclipse.easie.tomcat.myeclipse_11.0.0.me201211151802\tomcat\bin 3 六月 29, 2015 3:09:27 下午 org.apache.coyote.http11.Http11Protocol init 4 信息: Initializing Coyote HTTP/1.1 on http-8080 5 六月 29, 2015 3:09:27 下午 org.apache.catalina.startup.Catalina load 6 信息: Initialization processed in 583 ms 7 六月 29, 2015 3:09:27 下午 org.apache.catalina.core.StandardService start 8 信息: Starting service Catalina 9 六月 29, 2015 3:09:27 下午 org.apache.catalina.core.StandardEngine start 10 信息: Starting Servlet Engine: Apache Tomcat/6.0.13 11 六月 29, 2015 3:09:30 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 12 信息: Parsing configuration file [struts-default.xml] 13 六月 29, 2015 3:09:30 下午 org.apache.catalina.core.StandardContext filterStart 14 严重: Exception starting filter struts2 15 java.lang.NoClassDefFoundError: org/apache/commons/lang3/StringUtils 16 at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:213) 17 at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(StrutsXmlConfigurationProvider.java:102) 18 at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:240) 19 at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67) 20 at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967) 21 at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435) 22 at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479) 23 at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74) 24 at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57) 25 at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275) 26 at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397) 27 at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:108) 28 at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3693) 29 at org.apache.catalina.core.StandardContext.start(StandardContext.java:4340) 30 at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791) 31 at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771) 32 at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525) 33 at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920) 34 at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883) 35 at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492) 36 at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138) 37 at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311) 38 at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) 39 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053) 40 at org.apache.catalina.core.StandardHost.start(StandardHost.java:719) 41 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045) 42 at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) 43 at org.apache.catalina.core.StandardService.start(StandardService.java:516) 44 at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) 45 at org.apache.catalina.startup.Catalina.start(Catalina.java:566) 46 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 47 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 48 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 49 at java.lang.reflect.Method.invoke(Method.java:606) 50 at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288) 51 at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) 52 Caused by: java.lang.ClassNotFoundException: org.apache.commons.lang3.StringUtils 53 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1358) 54 at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204) 55 ... 36 more 56 57 六月 29, 2015 3:09:30 下午 org.apache.catalina.core.StandardContext start 58 严重: Error filterStart 59 六月 29, 2015 3:09:30 下午 org.apache.catalina.core.StandardContext start 60 严重: Context [/struts2] startup failed due to previous errors 61 六月 29, 2015 3:09:30 下午 org.apache.coyote.http11.Http11Protocol start 62 信息: Starting Coyote HTTP/1.1 on http-8080 63 六月 29, 2015 3:09:30 下午 org.apache.jk.common.ChannelSocket init 64 信息: JK: ajp13 listening on /0.0.0.0:8009 65 六月 29, 2015 3:09:30 下午 org.apache.jk.server.JkMain start 66 信息: Jk running ID=0 time=0/26 config=null 67 六月 29, 2015 3:09:30 下午 org.apache.catalina.startup.Catalina start 68 信息: Server startup in 3935 ms
对比上下两次报错,发现这个添加javassist-3.11.0.GA.jar,解决了:严重: Dispatcher initialization failed
但是还有一个错误没有解决,这个错误是:严重: Exception starting filter struts2
这里说明一下:Javassist是一个开源的分析、编辑和创建Java字节码的类库。是由东京工业大学的数学和计算机科学系的 Shigeru Chiba (千叶 滋)所创建的。它已加入了开放源代码JBoss 应用服务器项目,通过使用Javassist对字节码操作为JBoss实现动态AOP框架。
2.
Caused by: java.lang.ClassNotFoundException: org.apache.commons.lang3.StringUtils,网友根据这个报错的解读是,缺少添加的commons-lang3-3.1.jar,这个jar包是:
跟java.lang这个包的作用类似,Commons Lang这一组API也是提供一些基础的、通用的操作和处理,如自动生成toString()的结果、自动实现hashCode()和equals()方法、数组操作、枚举、日期和时间的处理等等。
这一组API的所有包名都以org.apache.commons.lang开头,共有如下8个包:
org.apache.commons.lang
org.apache.commons.lang.builder
org.apache.commons.lang.enum
org.apache.commons.lang.enums
org.apache.commons.lang.exception
org.apache.commons.lang.math
org.apache.commons.lang.mutable
org.apache.commons.lang.time
然后我添加这个jar包之后,再次运行这个struts工程,发现:
1 六月 29, 2015 3:44:24 下午 org.apache.catalina.core.AprLifecycleListener init 2 信息: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\software\myeclipse\install\binary\com.sun.java.jdk7.win32.x86_1.7.0.u45\bin;D:\software\myeclipse\install\plugins\com.genuitec.eclipse.easie.tomcat.myeclipse_11.0.0.me201211151802\tomcat\bin 3 六月 29, 2015 3:44:24 下午 org.apache.coyote.http11.Http11Protocol init 4 信息: Initializing Coyote HTTP/1.1 on http-8080 5 六月 29, 2015 3:44:24 下午 org.apache.catalina.startup.Catalina load 6 信息: Initialization processed in 600 ms 7 六月 29, 2015 3:44:24 下午 org.apache.catalina.core.StandardService start 8 信息: Starting service Catalina 9 六月 29, 2015 3:44:24 下午 org.apache.catalina.core.StandardEngine start 10 信息: Starting Servlet Engine: Apache Tomcat/6.0.13 11 六月 29, 2015 3:44:28 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 12 信息: Parsing configuration file [struts-default.xml] 13 六月 29, 2015 3:44:29 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 14 信息: Unable to locate configuration files of the name struts-plugin.xml, skipping 15 六月 29, 2015 3:44:29 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 16 信息: Parsing configuration file [struts-plugin.xml] 17 六月 29, 2015 3:44:29 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 18 信息: Parsing configuration file [struts.xml] 19 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 20 信息: Choosing bean (struts) for (com.opensymphony.xwork2.ObjectFactory) 21 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 22 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ActionFactory) 23 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 24 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ResultFactory) 25 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 26 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ConverterFactory) 27 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 28 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.InterceptorFactory) 29 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 30 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ValidatorFactory) 31 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 32 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.UnknownHandlerFactory) 33 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 34 信息: Choosing bean (struts) for (com.opensymphony.xwork2.FileManagerFactory) 35 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 36 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.XWorkConverter) 37 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 38 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.CollectionConverter) 39 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 40 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.ArrayConverter) 41 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 42 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.DateConverter) 43 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 44 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.NumberConverter) 45 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 46 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.StringConverter) 47 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 48 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionPropertiesProcessor) 49 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 50 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionFileProcessor) 51 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 52 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionAnnotationProcessor) 53 六月 29, 2015 3:44:29 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 54 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.TypeConverterCreator) 55 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 56 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.TypeConverterHolder) 57 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 58 信息: Choosing bean (struts) for (com.opensymphony.xwork2.TextProvider) 59 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 60 信息: Choosing bean (struts) for (com.opensymphony.xwork2.LocaleProvider) 61 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 62 信息: Choosing bean (struts) for (com.opensymphony.xwork2.ActionProxyFactory) 63 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 64 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ObjectTypeDeterminer) 65 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 66 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.mapper.ActionMapper) 67 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 68 信息: Choosing bean (jakarta) for (org.apache.struts2.dispatcher.multipart.MultiPartRequest) 69 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 70 信息: Choosing bean (struts) for (org.apache.struts2.views.freemarker.FreemarkerManager) 71 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 72 信息: Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer) 73 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 74 信息: Choosing bean (struts) for (com.opensymphony.xwork2.validator.ActionValidatorManager) 75 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 76 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory) 77 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 78 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.reflection.ReflectionProvider) 79 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 80 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.reflection.ReflectionContextFactory) 81 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 82 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher) 83 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 84 信息: Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher) 85 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 86 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.StaticContentLoader) 87 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 88 信息: Choosing bean (struts) for (com.opensymphony.xwork2.UnknownHandlerManager) 89 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 90 信息: Choosing bean (struts) for (org.apache.struts2.views.util.UrlHelper) 91 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 92 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.TextParser) 93 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 94 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.DispatcherErrorHandler) 95 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 96 信息: Choosing bean (struts) for (com.opensymphony.xwork2.security.ExcludedPatternsChecker) 97 六月 29, 2015 3:44:30 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 98 信息: Choosing bean (struts) for (com.opensymphony.xwork2.security.AcceptedPatternsChecker) 99 六月 29, 2015 3:44:35 下午 org.apache.coyote.http11.Http11Protocol start 100 信息: Starting Coyote HTTP/1.1 on http-8080 101 六月 29, 2015 3:44:35 下午 org.apache.jk.common.ChannelSocket init 102 信息: JK: ajp13 listening on /0.0.0.0:8009 103 六月 29, 2015 3:44:35 下午 org.apache.jk.server.JkMain start 104 信息: Jk running ID=0 time=0/40 config=null 105 六月 29, 2015 3:44:35 下午 org.apache.catalina.startup.Catalina start 106 信息: Server startup in 10530 ms 107 六月 29, 2015 3:44:37 下午 org.apache.struts2.dispatcher.Dispatcher warn 108 警告: Could not find action or result: /struts2/ 109 There is no Action mapped for namespace [/] and action name [] associated with context path [/struts2]. - [unknown location] 110 at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:185) 111 at org.apache.struts2.impl.StrutsActionProxy.prepare(StrutsActionProxy.java:63) 112 at org.apache.struts2.impl.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:37) 113 at com.opensymphony.xwork2.DefaultActionProxyFactory.createActionProxy(DefaultActionProxyFactory.java:58) 114 at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:554) 115 at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81) 116 at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99) 117 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) 118 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) 119 at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) 120 at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) 121 at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) 122 at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) 123 at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) 124 at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261) 125 at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) 126 at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581) 127 at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) 128 at java.lang.Thread.run(Thread.java:744)
到这里我们发现,没有发现报错了,说明问题成功解决了,这里同时也出现一个警告:
警告: Could not find action or result: /struts2/
我找了很久才发现这个是web.xml文件中:
1 <?xml version="1.0" encoding="UTF-8"?> 2 <web-app id="WebApp_9" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> 5 6 <filter> 7 <filter-name>struts2</filter-name> 8 <filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class> 9 </filter> 10 11 <filter-mapping> 12 <filter-name>struts2</filter-name> 13 <url-pattern>/*</url-pattern> 14 </filter-mapping> 15 16 <welcome-file-list> 17 <welcome-file>index.html</welcome-file> 18 </welcome-file-list> 19 20 21 </web-app>
这里index.html是错误的,因为工程下没有这个文件,如下图:
所以我改一下,改为:
1 <?xml version="1.0" encoding="UTF-8"?> 2 <web-app id="WebApp_9" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> 5 6 <filter> 7 <filter-name>struts2</filter-name> 8 <filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class> 9 </filter> 10 11 <filter-mapping> 12 <filter-name>struts2</filter-name> 13 <url-pattern>/*</url-pattern> 14 </filter-mapping> 15 16 <welcome-file-list> 17 <welcome-file>index.jsp</welcome-file> 18 </welcome-file-list> 19 20 21 </web-app>
虽然我这里struts2工程中struts.xml没有任何配置,但是还是可以运行的,这里我运行这个struts2工程,如下图:
Console:
1 六月 29, 2015 4:04:07 下午 org.apache.catalina.core.AprLifecycleListener init 2 信息: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\software\myeclipse\install\binary\com.sun.java.jdk7.win32.x86_1.7.0.u45\bin;D:\software\myeclipse\install\plugins\com.genuitec.eclipse.easie.tomcat.myeclipse_11.0.0.me201211151802\tomcat\bin 3 六月 29, 2015 4:04:07 下午 org.apache.coyote.http11.Http11Protocol init 4 信息: Initializing Coyote HTTP/1.1 on http-8080 5 六月 29, 2015 4:04:07 下午 org.apache.catalina.startup.Catalina load 6 信息: Initialization processed in 570 ms 7 六月 29, 2015 4:04:07 下午 org.apache.catalina.core.StandardService start 8 信息: Starting service Catalina 9 六月 29, 2015 4:04:07 下午 org.apache.catalina.core.StandardEngine start 10 信息: Starting Servlet Engine: Apache Tomcat/6.0.13 11 六月 29, 2015 4:04:11 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 12 信息: Parsing configuration file [struts-default.xml] 13 六月 29, 2015 4:04:11 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 14 信息: Unable to locate configuration files of the name struts-plugin.xml, skipping 15 六月 29, 2015 4:04:11 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 16 信息: Parsing configuration file [struts-plugin.xml] 17 六月 29, 2015 4:04:11 下午 com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info 18 信息: Parsing configuration file [struts.xml] 19 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 20 信息: Choosing bean (struts) for (com.opensymphony.xwork2.ObjectFactory) 21 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 22 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ActionFactory) 23 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 24 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ResultFactory) 25 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 26 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ConverterFactory) 27 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 28 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.InterceptorFactory) 29 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 30 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.ValidatorFactory) 31 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 32 信息: Choosing bean (struts) for (com.opensymphony.xwork2.factory.UnknownHandlerFactory) 33 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 34 信息: Choosing bean (struts) for (com.opensymphony.xwork2.FileManagerFactory) 35 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 36 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.XWorkConverter) 37 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 38 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.CollectionConverter) 39 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 40 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.ArrayConverter) 41 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 42 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.DateConverter) 43 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 44 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.NumberConverter) 45 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 46 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.impl.StringConverter) 47 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 48 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionPropertiesProcessor) 49 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 50 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionFileProcessor) 51 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 52 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ConversionAnnotationProcessor) 53 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 54 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.TypeConverterCreator) 55 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 56 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.TypeConverterHolder) 57 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 58 信息: Choosing bean (struts) for (com.opensymphony.xwork2.TextProvider) 59 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 60 信息: Choosing bean (struts) for (com.opensymphony.xwork2.LocaleProvider) 61 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 62 信息: Choosing bean (struts) for (com.opensymphony.xwork2.ActionProxyFactory) 63 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 64 信息: Choosing bean (struts) for (com.opensymphony.xwork2.conversion.ObjectTypeDeterminer) 65 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 66 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.mapper.ActionMapper) 67 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 68 信息: Choosing bean (jakarta) for (org.apache.struts2.dispatcher.multipart.MultiPartRequest) 69 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 70 信息: Choosing bean (struts) for (org.apache.struts2.views.freemarker.FreemarkerManager) 71 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 72 信息: Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer) 73 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 74 信息: Choosing bean (struts) for (com.opensymphony.xwork2.validator.ActionValidatorManager) 75 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 76 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory) 77 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 78 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.reflection.ReflectionProvider) 79 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 80 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.reflection.ReflectionContextFactory) 81 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 82 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher) 83 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 84 信息: Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher) 85 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 86 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.StaticContentLoader) 87 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 88 信息: Choosing bean (struts) for (com.opensymphony.xwork2.UnknownHandlerManager) 89 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 90 信息: Choosing bean (struts) for (org.apache.struts2.views.util.UrlHelper) 91 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 92 信息: Choosing bean (struts) for (com.opensymphony.xwork2.util.TextParser) 93 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 94 信息: Choosing bean (struts) for (org.apache.struts2.dispatcher.DispatcherErrorHandler) 95 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 96 信息: Choosing bean (struts) for (com.opensymphony.xwork2.security.ExcludedPatternsChecker) 97 六月 29, 2015 4:04:12 下午 org.apache.struts2.config.AbstractBeanSelectionProvider info 98 信息: Choosing bean (struts) for (com.opensymphony.xwork2.security.AcceptedPatternsChecker) 99 六月 29, 2015 4:04:16 下午 org.apache.coyote.http11.Http11Protocol start 100 信息: Starting Coyote HTTP/1.1 on http-8080 101 六月 29, 2015 4:04:16 下午 org.apache.jk.common.ChannelSocket init 102 信息: JK: ajp13 listening on /0.0.0.0:8009 103 六月 29, 2015 4:04:16 下午 org.apache.jk.server.JkMain start 104 信息: Jk running ID=0 time=0/65 config=null 105 六月 29, 2015 4:04:16 下午 org.apache.catalina.startup.Catalina start 106 信息: Server startup in 8766 ms
这里我们发现Console是很干净的,没有警告和错误。
下面这个是index.jsp展现图: