在eclipse里用Tomcat发布maven项目webapps下面没有东西 10C

在eclipse里用Tomcat发布maven项目但为什么webapps下面没有jsp和html页面求解决方法
![图片说明](https://img-ask.csdn.net/upload/201801/18/1516248202_45088.png)图片说明

14个回答

用maven把项目打成war包, 命名成ROOT.war 放到tomcat下的webapps目录, 启动tomcat 就好了

18-Jan-2018 13:03:12.308 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server version: Apache Tomcat/8.0.0
18-Jan-2018 13:03:12.313 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server built: Nov 27 2017 13:05:30 UTC
18-Jan-2018 13:03:12.313 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server number: 8.0.0
18-Jan-2018 13:03:12.313 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name: Windows 10
18-Jan-2018 13:03:12.313 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version: 10.0
18-Jan-2018 13:03:12.313 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture: amd64
18-Jan-2018 13:03:12.314 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home: D:\JDK_8\Java\jdk1.8.0_161\jre
18-Jan-2018 13:03:12.314 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version: 1.8.0_161-b12
18-Jan-2018 13:03:12.314 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor: Oracle Corporation
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE: D:\tomcat_8.0\apache-tomcat-8.5.24
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME: D:\tomcat_8.0\apache-tomcat-8.5.24
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=D:\tomcat_8.0\apache-tomcat-8.5.24\conf\logging.properties
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048
18-Jan-2018 13:03:12.315 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources
18-Jan-2018 13:03:12.316 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs=
18-Jan-2018 13:03:12.316 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=D:\tomcat_8.0\apache-tomcat-8.5.24
18-Jan-2018 13:03:12.318 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=D:\tomcat_8.0\apache-tomcat-8.5.24
18-Jan-2018 13:03:12.319 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=D:\tomcat_8.0\apache-tomcat-8.5.24\temp
18-Jan-2018 13:03:12.320 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR based Apache Tomcat Native library [1.2.16] using APR version [1.6.3].
18-Jan-2018 13:03:12.321 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
18-Jan-2018 13:03:12.322 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
18-Jan-2018 13:03:12.804 信息 [main] org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL successfully initialized [OpenSSL 1.0.2m 2 Nov 2017]
18-Jan-2018 13:03:12.906 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
18-Jan-2018 13:03:13.047 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
18-Jan-2018 13:03:13.052 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"]
18-Jan-2018 13:03:13.055 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
18-Jan-2018 13:03:13.055 信息 [main] org.apache.catalina.startup.Catalina.load Initialization processed in 1058 ms
18-Jan-2018 13:03:13.075 信息 [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
18-Jan-2018 13:03:13.076 信息 [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.0.0
18-Jan-2018 13:03:13.084 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deploying configuration descriptor [D:\tomcat_8.0\apache-tomcat-8.5.24\conf\Catalina\localhost\maven-web-demo.xml]
18-Jan-2018 13:03:13.107 警告 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor A docBase [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\maven-web-demo] inside the host appBase has been specified, and will be ignored
18-Jan-2018 13:03:13.118 警告 [localhost-startStop-1] org.apache.catalina.startup.SetContextPropertiesRule.begin [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:maven-web-demo' did not find a matching property.
18-Jan-2018 13:03:13.409 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of configuration descriptor [D:\tomcat_8.0\apache-tomcat-8.5.24\conf\Catalina\localhost\maven-web-demo.xml] has finished in [324] ms
18-Jan-2018 13:03:13.410 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\docs]
18-Jan-2018 13:03:13.432 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\docs] has finished in [22] ms
18-Jan-2018 13:03:13.433 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\examples]
18-Jan-2018 13:03:13.761 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\examples] has finished in [329] ms
18-Jan-2018 13:03:13.761 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\host-manager]
18-Jan-2018 13:03:13.790 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\host-manager] has finished in [29] ms
18-Jan-2018 13:03:13.791 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\manager]
18-Jan-2018 13:03:13.819 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\manager] has finished in [28] ms
18-Jan-2018 13:03:13.820 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\ROOT]
18-Jan-2018 13:03:13.839 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [D:\tomcat_8.0\apache-tomcat-8.5.24\webapps\ROOT] has finished in [19] ms
18-Jan-2018 13:03:13.842 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
18-Jan-2018 13:03:13.853 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"]
18-Jan-2018 13:03:13.857 信息 [main] org.apache.catalina.startup.Catalina.start Server startup in 800 ms

启动Tomcat时报错了

18-Jan-2018 13:03:13.118 警告 [localhost-startStop-1] org.apache.catalina.startup.SetContextPropertiesRule.begin [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:maven-web-demo' did not find a matching property.
Tomcat提示着个地方的property属性没找到,看看是不是配置文件出现问题,如果这个问题可以排除,那么直接在eclipse上面的project中clean依稀,重新编译一下看看;

MissLone
虚泪无痕 检查你的配置文件是否有错误;实在不行重装tomcat
大约 2 年之前 回复
qq_22590821
引火上身 如果还是不行你可以将target文件夹删除,然后重新编译也可以,我之前好像遇到过这样的问题,就是编译问题
大约 2 年之前 回复

先clean在build试试

图片说明

1、启动tomcat访问tomcat是否正常
2、clean一下项目
3、eclipse查看tomcat编译路径
4、把项目在tomcat删除再重新添加

图片说明

这里改为你的本地 tomcat的地址 因为 eclipse 默认放在它的目录下

你看一下 server.xml里面的默认地址是哪

在eclipse的workspace目录下的。如果在eclipse的tomcat是默认配置的话,图片说明,对于文件目录是图片说明

2018-01-19 10:08:03.741922+0800 SuningEIM[23643:4070147] Z_Ptf:didConnectToHost
2018-01-19 10:08:17.440319+0800 SuningEIM[23643:4070996] Received XPC error Connection interrupted for message type 3 kCFNetworkAgentXPCMessageTypePACQuery
2018-01-19 10:08:17.441586+0800 SuningEIM[23643:4070996] Received XPC error Connection invalid for message type 3 kCFNetworkAgentXPCMessageTypePACQuery

共14条数据 1 尾页
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
多环境下eclipse如何配置tomcat加载指定properties文件
项目背景:maven项目,有多个环境:dev、sit、uat、pat。之前用的Idea和jetty,现在因项目需要切换成了eclipse和tomcat。 问题描述:maven打的是sit的包,war包放到tomcat下单独运行没有问题,但是用eclipse内置的tomcat启动就会报错,我看了项目根目录下.metadata\.plugins\org.eclipse.wst.server.core\里的webapps项目文件,发现每次启动服务加载的都是dev.properties文件,但是之前maven打的war包里面是sit.properties文件呀,tomcat怎么又重置成dev了呢?eclipse里该怎么配置tomcat让它跟随环境加载.properties文件呢?有木有大神和我遇到的是同一个问题?
maven打成war包后放在tomcat的webapps目录下不会自动解压是为什么?
具体情况如下: 工程在eclipse上正常运行。 maven打成war包后放在tomcat的webapps目录下不会自动解压。 出现的异常如下图 ![图片说明](https://img-ask.csdn.net/upload/201511/11/1447209630_363712.png) 平时打的其他war都会自动解压。 收到解压war放在webapps目录下可以正常运行。 是什么原因导致war不会自动解压?
eclipse中用tomcat部署maven项目,运行报错,求解决思路?
tomcat中部署了maven项目,根据报错提示可能是因为maven所依赖的jar包没有加载进去导致tomcat启动报错。按照下图所示步骤添加不进去?请问该怎么办 ![图片说明](https://img-ask.csdn.net/upload/201902/24/1550983566_557306.png) --------以下是报错信息相关截图 ![图片说明](https://img-ask.csdn.net/upload/201902/24/1551015843_741802.png) 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server version: Apache Tomcat/8.5.38 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server built: Feb 5 2019 11:42:42 UTC 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server number: 8.5.38.0 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Name: Windows 10 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Version: 10.0 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Architecture: amd64 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Java Home: D:\Java\jdk1.8.0_171\jre 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Version: 1.8.0_171-b11 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Vendor: Oracle Corporation 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_BASE: H:\company\hqjc_web\.metadata\.plugins\org.eclipse.wst.server.core\tmp0 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_HOME: H:\webservice\tomcat8\apache-tomcat-8.5.38-x64 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.base=H:\company\hqjc_web\.metadata\.plugins\org.eclipse.wst.server.core\tmp0 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.home=H:\webservice\tomcat8\apache-tomcat-8.5.38-x64 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dwtp.deploy=H:\company\hqjc_web\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\webapps 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Djava.endorsed.dirs=H:\webservice\tomcat8\apache-tomcat-8.5.38-x64\endorsed 二月 24, 2019 9:42:44 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dfile.encoding=GBK 二月 24, 2019 9:42:44 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent 信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [D:\Java\jdk1.8.0_171\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;D:/Program Files (x86)/Java/jdk1.8.0_73/bin/../jre/bin/client;D:/Program Files (x86)/Java/jdk1.8.0_73/bin/../jre/bin;D:/Program Files (x86)/Java/jdk1.8.0_73/bin/../jre/lib/i386;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;D:\Java\jdk1.8.0_171\bin;C:\ProgramData\Oracle\Java\javapath;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;D:\Program Files (x86)\MySQL\MySQL Server 5.6\bin;D:\PROGRA~1\F-Secure\SSHTRI~1;H:\mongodb\bin;C:\Program Files (x86)\Common Files\Adobe\AGL;D:\ProgramFiles\VisualSVNServer\bin;D:\ProgramFiles\TortoiseSVN\bin;D:\ProgramFiles\Git\cmd;D:\ProgramFiles\nodejs\;C:\WINDOWS\System32\OpenSSH\;C:\Users\zch\AppData\Local\Microsoft\WindowsApps;C:\Users\zch\AppData\Local\GitHubDesktop\bin;D:\ProgramFiles\nodejs\node_global;C:\Users\zch\AppData\Local\Microsoft\WindowsApps;;D:\workide\eclipse;;.] 二月 24, 2019 9:42:44 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["http-nio-8080"] 二月 24, 2019 9:42:46 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 二月 24, 2019 9:42:46 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["ajp-nio-8009"] 二月 24, 2019 9:42:46 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 二月 24, 2019 9:42:46 下午 org.apache.catalina.startup.Catalina load 信息: Initialization processed in 2913 ms 二月 24, 2019 9:42:46 下午 org.apache.catalina.core.StandardService startInternal 信息: Starting service [Catalina] 二月 24, 2019 9:42:46 下午 org.apache.catalina.core.StandardEngine startInternal 信息: Starting Servlet Engine: Apache Tomcat/8.5.38 二月 24, 2019 9:42:47 下午 org.apache.catalina.core.ContainerBase startInternal 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:942) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1423) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1413) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ... 6 more Caused by: java.lang.NoClassDefFoundError: Lorg/slf4j/Logger; at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Class.java:2583) at java.lang.Class.getDeclaredFields(Class.java:1916) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:110) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:269) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationFilterAnnotations(WebAnnotationSet.java:109) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:68) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:328) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:772) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5181) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1364) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1185) ... 19 more 二月 24, 2019 9:42:47 下午 org.apache.catalina.core.ContainerBase startInternal 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:942) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.startup.Catalina.start(Catalina.java:688) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1423) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1413) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:953) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:942) ... 8 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ... 6 more Caused by: java.lang.NoClassDefFoundError: Lorg/slf4j/Logger; at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Class.java:2583) at java.lang.Class.getDeclaredFields(Class.java:1916) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:110) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:269) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationFilterAnnotations(WebAnnotationSet.java:109) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:68) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:328) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:772) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5181) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1364) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1185) ... 19 more 二月 24, 2019 9:42:47 下午 org.apache.catalina.startup.Catalina start 严重: The required Server component failed to start so Tomcat is unable to start. org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.startup.Catalina.start(Catalina.java:688) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 7 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 9 more Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:953) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 11 more Caused by: java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:942) ... 13 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1423) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1413) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:953) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:942) ... 8 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ... 6 more Caused by: java.lang.NoClassDefFoundError: Lorg/slf4j/Logger; at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Class.java:2583) at java.lang.Class.getDeclaredFields(Class.java:1916) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:110) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:269) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationFilterAnnotations(WebAnnotationSet.java:109) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:68) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:328) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:772) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5181) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1364) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1185) ... 19 more 二月 24, 2019 9:42:47 下午 org.apache.coyote.AbstractProtocol pause 信息: Pausing ProtocolHandler ["http-nio-8080"] 二月 24, 2019 9:42:47 下午 org.apache.coyote.AbstractProtocol pause 信息: Pausing ProtocolHandler ["ajp-nio-8009"] 二月 24, 2019 9:42:47 下午 org.apache.catalina.core.StandardService stopInternal 信息: Stopping service [Catalina] 二月 24, 2019 9:42:47 下午 org.apache.coyote.AbstractProtocol destroy 信息: Destroying ProtocolHandler ["http-nio-8080"] 二月 24, 2019 9:42:47 下午 org.apache.coyote.AbstractProtocol destroy 信息: Destroying ProtocolHandler ["ajp-nio-8009"]
关于tomcat无法正确发布项目到webapps的问题
我在本地的一个eclipse上用tomcat发布一个maven工程的时候,**启动不报错**,输入http://localhost:8080/drug-web/html/pcUser/userLogin.jsp,**可以看到我的登录页面** ,但是无法往后台发送请求。 =========已下是我的工程环境======== tomcat版本:7.0.70 win32.x86 jdk版本:1.6.0_24 win32.x86 eclipse版本:eclipse.INDIGO,win32.x86 WINDOW 版本:WIN7. 问:项目可以启动并访问工程的静态页面,但是无法请求后台的真正原因是什么?咩~
eclipse下的tomcat部署
为什么eclipse用tomcat一直部署不了项目 而tomcat目录下的webapps却有这项目 三月 23, 2015 9:16:21 上午 org.apache.tomcat.util.digester.SetPropertiesRule begin 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:homework' did not find a matching property. 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server version: Apache Tomcat/8.0.20 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server built: Feb 15 2015 18:10:42 UTC 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server number: 8.0.20.0 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Name: Windows 8.1 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Version: 6.3 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Architecture: amd64 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Java Home: C:\Program Files\java\jre1.8.0_31 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Version: 1.8.0_31-b13 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Vendor: Oracle Corporation 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_BASE: E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_HOME: E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.base=E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.home=E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dwtp.deploy=E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Djava.endorsed.dirs=E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\endorsed 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dfile.encoding=GBK 三月 23, 2015 9:16:21 上午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent 信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\java\jre1.8.0_31\bin;C:\windows\Sun\Java\bin;C:\windows\system32;C:\windows;C:/Program Files/Java/jre1.8.0_31/bin/server;C:/Program Files/Java/jre1.8.0_31/bin;C:/Program Files/Java/jre1.8.0_31/lib/amd64;C:\ProgramData\Oracle\Java\javapath;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Java\jdk1.8.0_40\bin;D:\maven\maven\apache-maven-3.1.0\bin;.;;E:\eclipse luna\eclipse-jee-luna-SR2-win32-x86_64\eclipse;;.;;. 三月 23, 2015 9:16:21 上午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["http-nio-8080"] 三月 23, 2015 9:16:21 上午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 三月 23, 2015 9:16:21 上午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["ajp-nio-8009"] 三月 23, 2015 9:16:21 上午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 三月 23, 2015 9:16:21 上午 org.apache.catalina.startup.Catalina load 信息: Initialization processed in 1080 ms 三月 23, 2015 9:16:21 上午 org.apache.catalina.core.StandardService startInternal 信息: Starting service Catalina 三月 23, 2015 9:16:21 上午 org.apache.catalina.core.StandardEngine startInternal 信息: Starting Servlet Engine: Apache Tomcat/8.0.20 三月 23, 2015 9:16:22 上午 org.apache.catalina.util.SessionIdGeneratorBase createSecureRandom 信息: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [172] milliseconds. 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\docs 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\docs has finished in 47 ms 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\examples 三月 23, 2015 9:16:22 上午 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: contextInitialized() 三月 23, 2015 9:16:22 上午 org.apache.catalina.core.ApplicationContext log 信息: SessionListener: contextInitialized() 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\examples has finished in 520 ms 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\host-manager 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\host-manager has finished in 62 ms 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\manager 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\manager has finished in 125 ms 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\ROOT 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory E:\tomcat8 eclipse\apache-tomcat-8.0.20-windows-x64\apache-tomcat-8.0.20\webapps\ROOT has finished in 32 ms 三月 23, 2015 9:16:22 上午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["http-nio-8080"] 三月 23, 2015 9:16:22 上午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["ajp-nio-8009"] 三月 23, 2015 9:16:22 上午 org.apache.catalina.startup.Catalina start 信息: Server startup in 1367 ms 不会加载项目homework。 ![图片说明](https://img-ask.csdn.net/upload/201503/23/1427073742_47902.png) 但是在tomcat目录下的webapps却有这个项目
eclipse中使用main方法启动正常,使用maven打成war包放到tomcat启动错误
27-Apr-2017 16:52:30.065 信息 [main] org.apache.catalina.startup.Catalina.load Initialization processed in 867 ms 27-Apr-2017 16:52:30.083 信息 [main] org.apache.catalina.core.StandardService.startInternal Starting service Catalina 27-Apr-2017 16:52:30.083 信息 [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.12 27-Apr-2017 16:52:30.101 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive D:\Program Files\apache-tomcat-8.5.12\webapps\iwt.war 27-Apr-2017 16:52:30.154 严重 [localhost-startStop-1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/iwt]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:752) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:728) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.webresources.StandardRoot@69381ceb] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:4869) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5001) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 10 more Caused by: org.apache.catalina.LifecycleException: Failed to initialize component [org.apache.catalina.webresources.JarResourceSet@389d8109] at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:112) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140) at org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.java:709) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 13 more Caused by: java.lang.IllegalArgumentException: java.util.zip.ZipException: invalid END header (bad central directory offset) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:113) at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107) ... 16 more Caused by: java.util.zip.ZipException: invalid END header (bad central directory offset) at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.<init>(ZipFile.java:219) at java.util.zip.ZipFile.<init>(ZipFile.java:149) at java.util.jar.JarFile.<init>(JarFile.java:166) at java.util.jar.JarFile.<init>(JarFile.java:103) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:110) ... 17 more 27-Apr-2017 16:52:30.157 严重 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive D:\Program Files\apache-tomcat-8.5.12\webapps\iwt.war java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/iwt]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:756) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:728) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
springboot 多模块打包war,tomcat启动提示找不到配置文件
新项目使用springboot maven module方式新建了多个子模块,(多个)web,service,dao,entity,util、storage。其中web依赖entity、service、util、storage。 uitl模块中有个ConfigUtil.java @Component @ConfigurationProperties @PropertySource(value = "classpath:config.properties",encoding = "utf-8") public class ConfigUtil { ...... } 其中config.properties文件放在util模块的resources文件夹下。 在将其中一个web项目打包成war时,在tomcat中启动时提示找不到config.properties ![图片说明](https://img-ask.csdn.net/upload/202001/20/1579522003_255875.png) 下面是uitl模块的pom文件 ``` <?xml version="1.0"?> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>com.zjyc.dsy</groupId> <artifactId>dsy-al</artifactId> <version>0.0.1-SNAPSHOT</version> </parent> <groupId>com.zjyc.dsy.util</groupId> <artifactId>dsy-util</artifactId> <name>dsy-util</name> <packaging>jar</packaging> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties> <dependencies> <dependency> <groupId>artemis</groupId> <artifactId>artemis-lib</artifactId> <version>1.0</version> <scope>system</scope> <systemPath>${project.basedir}/src/main/resources/jar/artemis-http-client-1.0-SNAPSHOT.jar</systemPath> </dependency> </dependencies> <build> <resources> <resource> <directory>src/main/java</directory> <includes> <include>**/*.properties</include> </includes> <!-- resource的filtering属性用来表示资源文件中的占位符是否需要被替换,true为需要替换。 --> <filtering>false</filtering> </resource> <resource> <directory>src/main/resources</directory> <includes> <include>**/*</include> </includes> <filtering>false</filtering> </resource> </resources> </build> </project> ``` 下面是web模块的pom ``` <?xml version="1.0"?> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <modelVersion>4.0.0</modelVersion> <packaging>war</packaging> <parent> <groupId>com.zjyc.dsy</groupId> <artifactId>dsy-al</artifactId> <version>0.0.1-SNAPSHOT</version> <relativePath>../pom.xml</relativePath> </parent> <groupId>com.zjyc.dsy.web</groupId> <artifactId>dsy-web</artifactId> <name>dsy-web</name> <url>http://maven.apache.org</url> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties> <dependencies> <dependency> <groupId>com.zjyc.dsy.entity</groupId> <artifactId>dsy-entity</artifactId> <version>0.0.1-SNAPSHOT</version> </dependency> <dependency> <groupId>com.zjyc.dsy.service</groupId> <artifactId>dsy-service</artifactId> <version>0.0.1-SNAPSHOT</version> </dependency> <dependency> <groupId>com.zjyc.dsy.util</groupId> <artifactId>dsy-util</artifactId> <version>0.0.1-SNAPSHOT</version> </dependency> <dependency> <groupId>com.zjyc.dsy.storage</groupId> <artifactId>dsy-storage</artifactId> <version>0.0.1-SNAPSHOT</version> </dependency> <!-- https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api --> <dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <version>4.0.1</version> <scope>provided</scope> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-tomcat</artifactId> <scope>provided</scope> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> </plugin> <!-- 引入java编译器插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <configuration> <source>1.8</source> <target>1.8</target> <compilerVersion>1.8</compilerVersion> <encoding>UTF-8</encoding> </configuration> </plugin> <!-- 资源文件拷贝插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-resources-plugin</artifactId> <configuration> <encoding>UTF-8</encoding> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> <executions> <execution> <id>unpack</id> <phase>generate-resources</phase> <goals> <goal>unpack</goal> </goals> <configuration> <artifactItems> <artifactItem> <groupId>com.zjyc.dsy.util</groupId> <artifactId>dsy-util</artifactId> <version>0.0.1-SNAPSHOT</version> <type>jar</type> <overWrite>true</overWrite> <outputDirectory>${project.build.directory}/classes</outputDirectory> </artifactItem> </artifactItems> </configuration> </execution> </executions> </plugin> </plugins> <pluginManagement> <plugins> <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.--> <plugin> <groupId>org.eclipse.m2e</groupId> <artifactId>lifecycle-mapping</artifactId> <version>1.0.0</version> <configuration> <lifecycleMappingMetadata> <pluginExecutions> <pluginExecution> <pluginExecutionFilter> <groupId> org.apache.maven.plugins </groupId> <artifactId> maven-dependency-plugin </artifactId> <versionRange> [2.1,) </versionRange> <goals> <goal>unpack</goal> </goals> </pluginExecutionFilter> <action> <ignore></ignore> </action> </pluginExecution> </pluginExecutions> </lifecycleMappingMetadata> </configuration> </plugin> </plugins> </pluginManagement> <resources> <resource> <directory>${project.basedir}/src/main/resources</directory> <excludes> <exclude>**/*.properties</exclude> </excludes> </resource> </resources> </build> </project> ``` 下面是war解压之后classes的目录结构 ![图片说明](https://img-ask.csdn.net/upload/202001/20/1579522257_42080.png) tomcat启动报错代码 ``` 20-Jan-2020 19:55:46.409 警告 [main] org.apache.catalina.startup.SetAllPropertiesRule.begin [SetAllPropertiesRule]{Server/Service/Connector} Setting property 'maxSpareThreads' to '500' did not find a matching property. 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server version: Apache Tomcat/9.0.6 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server built: Mar 5 2018 09:34:35 UTC 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server number: 9.0.6.0 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name: Windows Server 2008 R2 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version: 6.1 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture: amd64 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home: C:\Program Files\Java\jdk1.8.0_161\jre 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version: 1.8.0_161-b12 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor: Oracle Corporation 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE: E:\apache-tomcat-9 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME: E:\apache-tomcat-9 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=E:\apache-tomcat-9\conf\logging.properties 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs= 20-Jan-2020 19:55:46.534 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=E:\apache-tomcat-9 20-Jan-2020 19:55:46.550 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=E:\apache-tomcat-9 20-Jan-2020 19:55:46.550 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=E:\apache-tomcat-9\temp 20-Jan-2020 19:55:46.550 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR based Apache Tomcat Native library [1.2.16] using APR version [1.6.3]. 20-Jan-2020 19:55:46.550 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true]. 20-Jan-2020 19:55:46.550 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true] 20-Jan-2020 19:55:47.440 信息 [main] org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL successfully initialized [OpenSSL 1.0.2m 2 Nov 2017] 20-Jan-2020 19:55:47.565 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-80"] 20-Jan-2020 19:55:47.612 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read 20-Jan-2020 19:55:47.628 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-7778"] 20-Jan-2020 19:55:47.628 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read 20-Jan-2020 19:55:47.628 信息 [main] org.apache.catalina.startup.Catalina.load Initialization processed in 1553 ms 20-Jan-2020 19:55:47.659 信息 [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina] 20-Jan-2020 19:55:47.659 信息 [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/9.0.6 20-Jan-2020 19:55:47.675 信息 [main] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [E:\apache-tomcat-9\webapps\dsy-web-0.0.1-SNAPSHOT.war] 20-Jan-2020 19:55:50.815 信息 [main] org.apache.jasper.servlet.TldScanner.scanJars At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 20-Jan-2020 19:55:52.456 严重 [main] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/dsy-web-0.0.1-SNAPSHOT]] at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:441) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:742) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:718) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:703) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:987) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1858) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112) at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:772) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:426) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1586) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:308) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424) at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:966) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:839) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1427) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1417) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:943) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:258) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:770) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.startup.Catalina.start(Catalina.java:682) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [com.zjyc.dsy.web.App]; nested exception is java.io.FileNotFoundException: Could not open ServletContext resource [/config.properties] at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:184) at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:325) at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:242) at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275) at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95) at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:706) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:532) at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141) at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747) at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397) at org.springframework.boot.SpringApplication.run(SpringApplication.java:315) at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:152) at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:132) at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:92) at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:172) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5030) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) ... 38 more Caused by: java.io.FileNotFoundException: Could not open ServletContext resource [/config.properties] at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:159) at org.springframework.core.io.support.EncodedResource.getReader(EncodedResource.java:143) at org.springframework.core.io.support.PropertiesLoaderUtils.fillProperties(PropertiesLoaderUtils.java:95) at org.springframework.core.io.support.PropertiesLoaderUtils.fillProperties(PropertiesLoaderUtils.java:73) at org.springframework.core.io.support.PropertiesLoaderUtils.loadProperties(PropertiesLoaderUtils.java:59) at org.springframework.core.io.support.ResourcePropertySource.<init>(ResourcePropertySource.java:67) at org.springframework.core.io.support.DefaultPropertySourceFactory.createPropertySource(DefaultPropertySourceFactory.java:37) at org.springframework.context.annotation.ConfigurationClassParser.processPropertySource(ConfigurationClassParser.java:455) at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:274) at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:245) at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:194) at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:298) at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:245) at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:202) at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:170) ... 54 more 20-Jan-2020 19:55:52.471 严重 [main] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [E:\apache-tomcat-9\webapps\dsy-web-0.0.1-SNAPSHOT.war] java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/dsy-web-0.0.1-SNAPSHOT]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:746) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:718) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:703) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:987) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1858) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112) at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:772) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:426) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1586) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:308) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424) at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:966) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:839) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1427) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1417) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:943) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:258) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:770) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.startup.Catalina.start(Catalina.java:682) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) 20-Jan-2020 19:55:52.487 信息 [main] org.apache.catalina.startup.HostConfig.deployWAR Deployment of web application archive [E:\apache-tomcat-9\webapps\dsy-web-0.0.1-SNAPSHOT.war] has finished in [4,812] ms 20-Jan-2020 19:55:52.487 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-80"] 20-Jan-2020 19:55:52.503 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-7778"] 20-Jan-2020 19:55:52.518 信息 [main] org.apache.catalina.startup.Catalina.start Server startup in 4881 ms ```
从同事能运行的eclipse导入到IDEA的项目配置过tomcat后报严重 [RMI TCP Connection(3)-127.0.0.1] 错误
"C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\catalina.bat" run [2020-01-04 01:22:07,300] Artifact susong:war exploded: Waiting for server connection to start artifact deployment... Using CATALINA_BASE: "C:\Users\cd\.IntelliJIdea2018.1\system\tomcat\Unnamed_wuranyuan" Using CATALINA_HOME: "C:\Program Files\Apache Software Foundation\Tomcat 8.0" Using CATALINA_TMPDIR: "C:\Program Files\Apache Software Foundation\Tomcat 8.0\temp" Using JRE_HOME: "C:\Program Files\Java\jdk1.7.0_80" Using CLASSPATH: "C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\bootstrap.jar;C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\tomcat-juli.jar" 04-Jan-2020 13:22:13.122 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server version: Apache Tomcat/8.0.47 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server built: Sep 29 2017 13:46:41 UTC 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server number: 8.0.47.0 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name: Windows 7 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version: 6.1 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture: amd64 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home: C:\Program Files\Java\jdk1.7.0_80\jre 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version: 1.7.0_80-b15 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor: Oracle Corporation 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE: C:\Users\cd\.IntelliJIdea2018.1\system\tomcat\Unnamed_wuranyuan 04-Jan-2020 13:22:13.125 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME: C:\Program Files\Apache Software Foundation\Tomcat 8.0 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=C:\Users\cd\.IntelliJIdea2018.1\system\tomcat\Unnamed_wuranyuan\conf\logging.properties 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote= 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.port=1099 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.ssl=false 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.authenticate=false 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.rmi.server.hostname=127.0.0.1 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.endorsed.dirs=C:\Program Files\Apache Software Foundation\Tomcat 8.0\endorsed 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=C:\Users\cd\.IntelliJIdea2018.1\system\tomcat\Unnamed_wuranyuan 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=C:\Program Files\Apache Software Foundation\Tomcat 8.0 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=C:\Program Files\Apache Software Foundation\Tomcat 8.0\temp 04-Jan-2020 13:22:13.126 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.7.0_80\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\iCLS\;C:\Program Files\Intel\Intel(R) Management Engine Components\iCLS\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;D:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;D:\Program Files\Microsoft SQL Server\100\Tools\Binn\;D:\Program Files\Microsoft SQL Server\100\DTS\Binn\;D:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;D:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\SMART Technologies\Education Software\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\TortoiseSVN\bin;C:\Program Files (x86)\CADSeePlus;F:\software\ANDROID\android-sdk-windows\platform-tools;E:\opencv\opencv\build\x64\vc12\bin;E:\opencv\opencv\build\x86\vc12\bin;C:\Program Files (x86)\税务证书应用客户端;.\Library;.\Security\BiSafe;.\Security\Koal;C:\Users\cd\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Java\jdk1.8.0_131\bin;D:\Program Files\Apache\maven\bin;. 04-Jan-2020 13:22:13.227 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"] 04-Jan-2020 13:22:13.256 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read 04-Jan-2020 13:22:13.259 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"] 04-Jan-2020 13:22:13.270 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read 04-Jan-2020 13:22:13.270 信息 [main] org.apache.catalina.startup.Catalina.load Initialization processed in 439 ms 04-Jan-2020 13:22:13.296 信息 [main] org.apache.catalina.core.StandardService.startInternal Starting service Catalina 04-Jan-2020 13:22:13.296 信息 [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.0.47 04-Jan-2020 13:22:13.306 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"] 04-Jan-2020 13:22:13.327 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"] 04-Jan-2020 13:22:13.343 信息 [main] org.apache.catalina.startup.Catalina.start Server startup in 72 ms Connected to server [2020-01-04 01:22:13,389] Artifact susong:war exploded: Artifact is being deployed, please wait... 04-Jan-2020 13:22:17.320 严重 [RMI TCP Connection(3)-127.0.0.1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:753) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717) at org.apache.catalina.startup.HostConfig.manageApp(HostConfig.java:1733) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:484) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:433) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1487) at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:97) at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1328) at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1420) at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:848) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:322) at sun.rmi.transport.Transport$2.run(Transport.java:202) at sun.rmi.transport.Transport$2.run(Transport.java:199) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:198) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:567) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:828) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.access$400(TCPTransport.java:619) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:684) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:681) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:681) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.NoClassDefFoundError: org/apache/commons/configuration/ConfigurationException at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Class.java:2509) at java.lang.Class.getDeclaredFields(Class.java:1819) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:106) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:256) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationListenerAnnotations(WebAnnotationSet.java:86) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:63) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:336) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:786) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:307) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:95) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5213) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 44 more Caused by: java.lang.ClassNotFoundException: org.apache.commons.configuration.ConfigurationException at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1339) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1167) ... 58 more 04-Jan-2020 13:22:17.327 严重 [RMI TCP Connection(3)-127.0.0.1] org.apache.tomcat.util.modeler.BaseModelMBean.invoke Exception invoking method manageApp java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:757) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717) at org.apache.catalina.startup.HostConfig.manageApp(HostConfig.java:1733) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) [2020-01-04 01:22:17,378] Artifact susong:war exploded: Error during artifact deployment. See server log for details. at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:484) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:433) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1487) at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:97) at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1328) at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1420) at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:848) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:322) at sun.rmi.transport.Transport$2.run(Transport.java:202) at sun.rmi.transport.Transport$2.run(Transport.java:199) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:198) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:567) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:828) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.access$400(TCPTransport.java:619) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:684) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:681) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:681) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) 04-Jan-2020 13:22:17.328 严重 [RMI TCP Connection(3)-127.0.0.1] org.apache.tomcat.util.modeler.BaseModelMBean.invoke Exception invoking method createStandardContext javax.management.RuntimeOperationsException: Exception invoking method manageApp at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:308) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:484) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:433) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1487) at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:97) at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1328) at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1420) at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:848) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:322) at sun.rmi.transport.Transport$2.run(Transport.java:202) at sun.rmi.transport.Transport$2.run(Transport.java:199) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:198) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:567) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:828) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.access$400(TCPTransport.java:619) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:684) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$1.run(TCPTransport.java:681) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:681) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:757) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717) at org.apache.catalina.startup.HostConfig.manageApp(HostConfig.java:1733) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) ... 35 more 04-Jan-2020 13:22:23.307 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\manager 04-Jan-2020 13:22:23.405 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\manager has finished in 98 ms "C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\catalina.bat" stop Using CATALINA_BASE: "C:\Users\cd\.IntelliJIdea2018.1\system\tomcat\Unnamed_wuranyuan" Using CATALINA_HOME: "C:\Program Files\Apache Software Foundation\Tomcat 8.0" Using CATALINA_TMPDIR: "C:\Program Files\Apache Software Foundation\Tomcat 8.0\temp" Using JRE_HOME: "C:\Program Files\Java\jdk1.7.0_80" Using CLASSPATH: "C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\bootstrap.jar;C:\Program Files\Apache Software Foundation\Tomcat 8.0\bin\tomcat-juli.jar" 04-Jan-2020 13:26:09.457 信息 [main] org.apache.catalina.core.StandardServer.await A valid shutdown command was received via the shutdown port. Stopping the Server instance. 04-Jan-2020 13:26:09.458 信息 [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-8080"] 04-Jan-2020 13:26:09.515 信息 [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["ajp-nio-8009"] 04-Jan-2020 13:26:09.567 信息 [main] org.apache.catalina.core.StandardService.stopInternal Stopping service Catalina 04-Jan-2020 13:26:09.578 信息 [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-8080"] 04-Jan-2020 13:26:09.580 信息 [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["ajp-nio-8009"] 04-Jan-2020 13:26:09.581 信息 [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-8080"] 04-Jan-2020 13:26:09.581 信息 [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["ajp-nio-8009"] Disconnected from server
maven管理的聚合(pom)工程上云打包部署问题
&nbsp; &nbsp; &nbsp; &nbsp;我是用eclipse加maven参考宜立方商城开发了一套项目,搞拉半天把服务器搭建上云了,天真的我以为把代码打成war包,复制到tomcat的webapps文件下就大功告成了,可事实上却是一大波关于打包部署的问题。 &nbsp; &nbsp; &nbsp; &nbsp;项目用dubbo实现了分布式,provider是聚合工程,e3-manager-pojo(jar),e3-manager-dao(jar,mybatis逆向工程生成的代码),e3-manger-interface(jar,要暴露的接口),e3-manager-service(war,interface实现类),这些moudle是由e3-manager(pom)聚合起来的,这些module层层依赖关系,在eclipse用着是真舒服,可是部署上线完全没有打包的思路。 &nbsp; &nbsp; &nbsp; &nbsp;问题:如何把这些打成一个完整war用于部署阿里云?求懂的老师细解!感谢带我入门编程的老师和宜立方商城的主讲老师。
tomcat部署项目报错 工程0 errors了。依赖包也安要求加进去了的
# 问题描述: 首先:自己的新建的简单 maven工程能在tomcat成功部署且可以访问主页。 然后:拷贝的被人的工程放到tomcat上部署后启动报错。困扰几天了,求大神帮帮我~ 有一点说明:tomcat的webapps下有项目文件夹 # _启动日志报错段_: ``` 严重: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/tyLCC]] at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:441) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:742) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:718) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:703) at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1142) at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1876) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112) at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:1054) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:428) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1586) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:308) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424) at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:966) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:839) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1427) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1417) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:943) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:258) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:770) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.startup.Catalina.start(Catalina.java:682) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: java.lang.NoClassDefFoundError: org/springframework/context/ApplicationContext at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Class.java:2583) at java.lang.Class.getDeclaredFields(Class.java:1916) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:110) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:267) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationListenerAnnotations(WebAnnotationSet.java:87) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:65) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:328) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:768) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4939) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) ... 38 more Caused by: java.lang.ClassNotFoundException: org.springframework.context.ApplicationContext at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1275) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1104) ... 51 more 十一月 20, 2019 5:50:24 下午 org.apache.catalina.startup.HostConfig deployDirectory 严重: Error deploying web application directory [F:\Tomcat\apache-tomcat-9.0.6\webapps\tyLCC] java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/tyLCC]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:746) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:718) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:703) at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1142) at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1876) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112) at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:1054) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:428) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1586) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:308) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424) at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:966) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:839) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1427) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1417) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:943) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:258) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:770) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.startup.Catalina.start(Catalina.java:682) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) ```
exlipse上的项目在启动Tomcat时报错,有没有遇到过这种问题的,求帮助。
严重: Error deploying deployment descriptor [F:\apache-tomcat-9.0.14-windows-x64\apache-tomcat-9.0.14\conf\Catalina\localhost\ssm.xml] java.lang.IllegalStateException: Error starting child at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:716) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:690) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:695) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:631) at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1832) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(Unknown Source) at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:526) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:425) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1577) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:309) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424) at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:934) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:831) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1382) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1372) at java.util.concurrent.FutureTask.run(Unknown Source) at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75) at java.util.concurrent.AbstractExecutorService.submit(Unknown Source) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:907) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:423) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:933) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.startup.Catalina.start(Catalina.java:637) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:350) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:492) Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.webresources.StandardRoot@60285225] at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:441) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:4778) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4913) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:713) ... 37 more Caused by: java.lang.IllegalArgumentException: 指定的主资源集 [F:\apache-tomcat-9.0.14-windows-x64\apache-tomcat-9.0.14\webapps\ssm] 无效 at org.apache.catalina.webresources.StandardRoot.createMainResourceSet(StandardRoot.java:749) at org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.java:706) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) ... 41 more
maven项目,用到cxf框架,服务器启动后,其中一个server项目访问404错误
环境:eclipse+tomcat7,0+jdk1.6 项目之间有包依赖关系。![图片说明](https://img-ask.csdn.net/upload/201508/21/1440148806_544337.png)上图中圈出来的两个是web项目。 将web项目部署到tomcat服务器之后,在eclipse中启动服务器,此时,后台是没有报错的。只有几个警告: 警告: A docBase E:\Program Files\apache-tomcat-7.0.57\webapps\hb12345_server inside the host appBase has been specified, and will be ignored 2015-8-21 17:31:16 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:hb12345_server' did not find a matching property. 2015-8-21 17:31:18 org.apache.tomcat.websocket.server.WsSci onStartup 警告: A docBase E:\Program Files\apache-tomcat-7.0.57\webapps\hb12345_web inside the host appBase has been specified, and will be ignored 2015-8-21 17:31:18 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:hb12345_web' did not find a matching property. 2015-8-21 17:31:18 org.apache.catalina.loader.WebappClassLoader validateJarFile 启动之后,tomcat猫页面可以访问,也可以访问其中的一个项目(hb12345_web)登录页面,但是一登录后台就报错了。 org.apache.shiro.authc.AuthenticationException: Authentication failed for token submission [org.apache.shiro.authc.UsernamePasswordToken - admin, rememberMe=false]. Possible unexpected error? (Typical or expected login exceptions should extend from AuthenticationException). at org.apache.shiro.authc.AbstractAuthenticator.authenticate(AbstractAuthenticator.java:214) at org.apache.shiro.mgt.AuthenticatingSecurityManager.authenticate(AuthenticatingSecurityManager.java:106) at org.apache.shiro.mgt.DefaultSecurityManager.login(DefaultSecurityManager.java:270) at org.apache.shiro.subject.support.DelegatingSubject.login(DelegatingSubject.java:257) at com.eshore.framework.controller.LoginController.login(LoginController.java:61) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:213) at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:126) at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:96) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:617) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:578) at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:923) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:852) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882) at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:789) at javax.servlet.http.HttpServlet.service(HttpServlet.java:646) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449) at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365) at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:380) at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125) at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346) at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:259) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:503) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:662) Caused by: javax.xml.ws.WebServiceException: Could not send Message. at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:145) at $Proxy81.getUserByAccount(Unknown Source) at com.eshore.framework.authentication.ShiroDbRealm.doGetAuthenticationInfo(ShiroDbRealm.java:98) at org.apache.shiro.realm.AuthenticatingRealm.getAuthenticationInfo(AuthenticatingRealm.java:568) at org.apache.shiro.authc.pam.ModularRealmAuthenticator.doSingleRealmAuthentication(ModularRealmAuthenticator.java:180) at org.apache.shiro.authc.pam.ModularRealmAuthenticator.doAuthenticate(ModularRealmAuthenticator.java:267) at org.apache.shiro.authc.AbstractAuthenticator.authenticate(AbstractAuthenticator.java:198) ... 61 more Caused by: org.apache.cxf.transport.http.HTTPException: HTTP response '404: Not Found' when communicating with http://localhost:8080/hb12345_server/ws/sysUserWebservice?wsdl at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1584) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1521) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1429) at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56) at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:659) at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:262) at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:532) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:464) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:367) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:320) at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:89) at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:134) ... 67 more 我看了路径是没有问题的,找不到是哪里的问题了。 直接访问hb12345_server项目页面报错404,后台不报错。 求大神们拯救。
springboot打包成功了 部署tomcat 启动就报错 哪位大佬帮忙看看这是什么问题导致的?
06-Dec-2019 23:49:29.923 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [E:\apache-tomcat-8.5.34\webapps\demo-0.0.1-SNAPSHOT.war] 06-Dec-2019 23:49:31.682 严重 [localhost-startStop-1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demo-0.0.1-SNAPSHOT]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.UnsupportedClassVersionError: org/springframework/web/SpringServletContainerInitializer : Unsupported major.minor version 52.0 (unable to load class [org.springframework.web.SpringServletContainerInitializer]) at org.apache.catalina.loader.WebappClassLoaderBase.findClassInternal(WebappClassLoaderBase.java:2340) at org.apache.catalina.loader.WebappClassLoaderBase.findClass(WebappClassLoaderBase.java:829) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1278) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1137) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:278) at org.apache.catalina.startup.WebappServiceLoader.loadServices(WebappServiceLoader.java:188) at org.apache.catalina.startup.WebappServiceLoader.load(WebappServiceLoader.java:159) at org.apache.catalina.startup.ContextConfig.processServletContainerInitializers(ContextConfig.java:1612) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1125) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:765) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 10 more 06-Dec-2019 23:49:31.688 严重 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [E:\apache-tomcat-8.5.34\webapps\demo-0.0.1-SNAPSHOT.war] java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demo-0.0.1-SNAPSHOT]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:758) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745)
springboot打包成功了 部署tomcat 启动就报错 试过很多 还是不行 哪位大佬帮忙解决一下?
06-Dec-2019 23:49:29.923 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [E:\apache-tomcat-8.5.34\webapps\demo-0.0.1-SNAPSHOT.war] 06-Dec-2019 23:49:31.682 严重 [localhost-startStop-1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demo-0.0.1-SNAPSHOT]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.UnsupportedClassVersionError: org/springframework/web/SpringServletContainerInitializer : Unsupported major.minor version 52.0 (unable to load class [org.springframework.web.SpringServletContainerInitializer]) at org.apache.catalina.loader.WebappClassLoaderBase.findClassInternal(WebappClassLoaderBase.java:2340) at org.apache.catalina.loader.WebappClassLoaderBase.findClass(WebappClassLoaderBase.java:829) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1278) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1137) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:278) at org.apache.catalina.startup.WebappServiceLoader.loadServices(WebappServiceLoader.java:188) at org.apache.catalina.startup.WebappServiceLoader.load(WebappServiceLoader.java:159) at org.apache.catalina.startup.ContextConfig.processServletContainerInitializers(ContextConfig.java:1612) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1125) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:765) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:299) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 10 more 06-Dec-2019 23:49:31.688 严重 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Error deploying web application archive [E:\apache-tomcat-8.5.34\webapps\demo-0.0.1-SNAPSHOT.war] java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/demo-0.0.1-SNAPSHOT]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:758) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745)
ssm项目的问题 Servlet.init() for servlet [spring-dispatcher] threw exception
跟着网上的ssm项目做,可以说代码基本都是照着敲的。但是还是会有各种各样的bug。这个问题困扰我两天了,网上常见的我都试过,包括spring和jdk版本的适配,jar包的调整等等。请各位大佬帮忙看一下,感激不尽!下面是我警告和错误的代码: ``` WARN org.springframework.web.context.support.XmlWebApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in file [D:\Program Files\Apache Software Foundation\Tomcat 9.0\webapps\o2o\WEB-INF\classes\spring\spring-dao.xml]: Invocation of init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\Program Files\Apache Software Foundation\Tomcat 9.0\webapps\o2o\WEB-INF\classes\mapper\AreaDao.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\Program Files\Apache Software Foundation\Tomcat 9.0\webapps\o2o\WEB-INF\classes\mapper\AreaDao.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias 'com.immoc.o2o.entity.Area'. Cause: java.lang.ClassNotFoundException: Cannot find class: com.immoc.o2o.entity.Area 19:32:17.316 [http-nio-8080-exec-3] ERRORorg.springframework.web.servlet.DispatcherServlet - Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in file [D:\Program Files\Apache Software Foundation\Tomcat 9.0\webapps\o2o\WEB-INF\classes\spring\spring-dao.xml]: Invocation of init method failed; ``` 下面是错误中提到的AreaDao.xml: ``` <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <mapper namespace="com.immoc.o2o.dao.AreaDao"> <select id="queryArea" resultType="com.immoc.o2o.entity.Area"> SELECT area_id,area_name,priority,create_time,last_edit_time FROM tb_area ORDER BY priority DESC </select> </mapper> ``` Controller: ``` package com.immoc.o2o.web.superadmin; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.ResponseBody; import com.immoc.o2o.entity.Area; import com.immoc.o2o.service.AreaService; @Controller @RequestMapping("/superadmin") public class AreaController { @Autowired private AreaService areaService ; @RequestMapping(value="/listarea",method=RequestMethod.GET)//涉及前端的全小写 //pose的传值是相对安全的,而get的传值会反馈到URL上面 @ResponseBody private Map <String,Object> listArea(){ Map <String,Object> modelMap= new HashMap<String,Object>();//map's key不能重复 List<Area> list=new ArrayList<Area>(); try { list=areaService.getAreaList(); modelMap.put("rows", list); modelMap.put("total", list.size()); }catch(Exception e) { e.printStackTrace(); modelMap.put("success", false); modelMap.put("errMsg", e.toString()); } return modelMap; } } ``` pom的配置,都是一些基本的配置,spring版本我用的都是最新的5.1.8 ``` <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.immoc</groupId> <artifactId>o2o</artifactId> <packaging>war</packaging> <version>1.0-SNAPSHOT</version> <name>o2o Maven Webapp</name> <url>http://maven.apache.org</url> <dependencies> <!-- maven-dependency-plugin是来自csdn的博客 --> <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-dependency-plugin --> <dependency> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> <version>3.1.1</version> </dependency> <!-- 原作是junit,这里已经升级 --> <!-- https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api --> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter-api</artifactId> <version>5.5.1</version> <scope>test</scope> </dependency> <!-- https://mvnrepository.com/artifact/ch.qos.logback/logback-classic --> <dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-classic</artifactId> <version>1.2.3</version> </dependency> <!-- 这里用的都是5.1.8,而在原作里是设置了spring version的 --> <!-- https://mvnrepository.com/artifact/org.springframework/spring-core --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-core</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-beans这个其实就是备注 --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-beans</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-context --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-jdbc --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jdbc</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-tx --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-tx</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-web --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-webmvc 核心--> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-webmvc</artifactId> <version>5.1.8.RELEASE</version> </dependency> <!-- https://mvnrepository.com/artifact/org.springframework/spring-test --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-test</artifactId> <version>5.1.8.RELEASE</version> <scope>test</scope> </dependency> <!-- 除了spring之外还用到其他的架包,比如servlet --> <!-- https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api --> <dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <version>4.0.1</version> <scope>provided</scope> </dependency> <!-- 根据csdn加的jackson-core --> <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core --> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-core</artifactId> <version>2.9.9</version> </dependency> <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind --> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId> <version>2.9.9</version> </dependency> <!-- https://mvnrepository.com/artifact/org.apache.commons/commons-collections4 --> <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-collections4</artifactId> <!-- commons collection has been moved to commons collections4 --> <version>4.1</version> </dependency> <!-- https://mvnrepository.com/artifact/org.mybatis/mybatis --> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis</artifactId> <version>3.5.2</version> </dependency> <!-- https://mvnrepository.com/artifact/org.mybatis/mybatis-spring --> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis-spring</artifactId> <version>2.0.2</version> </dependency> <!-- 下面适合数据库配合的架包 --> <!-- https://mvnrepository.com/artifact/mysql/mysql-connector-java --> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>8.0.17</version> </dependency> <!-- 连接池 --> <!-- https://mvnrepository.com/artifact/com.mchange/c3p0 --> <dependency> <groupId>com.mchange</groupId> <artifactId>c3p0</artifactId> <version>0.9.5.4</version> </dependency> </dependencies> <build> <finalName>o2o</finalName> <plugins> <plugin> <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-compiler-plugin --> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.1</version> <configuration> <source>1.8</source> <target>1.8</target> <encoding>UTF8</encoding> </configuration> </plugin> </plugins> </build> </project> ``` 下面加个springDao吧: ``` <?xml version="1.0" encoding="UTF-8"?> <!-- 引入schema约束 --> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context" xmlns:mvc="http://www.springframework.org/schema/mvc" xsi:schemaLocation= "http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd "> <!-- mvc是新加入的 --> <!-- 加载jdbc.properties配置文件--> <context:property-placeholder location="classpath:jdbc.properties"/> <bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource"> <property name="driverClass" value="${jdbc.driver}"></property> <property name="jdbcUrl" value="${jdbc.url}"></property> <property name="user" value="${jdbc.username}"></property> <property name="password" value="${jdbc.password}"></property> <!-- c3p0的私有属性 --> <property name="maxPoolSize" value="30"/> <property name="minPoolSize" value="10"/> <!-- 关闭连接后不自动commit --> <property name="autoCommitOnClose" value="false"/> <!-- 获取超时链接的时间--> <property name="checkoutTimeout" value="10000"/> <!-- 连接失败的重试次数 --> <property name="acquireRetryAttempts" value="2"/> </bean> <bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean"> <property name="dataSource" ref="dataSource" /> <property name="configLocation" value="classpath:mybatis-config.xml" /> <property name="typeAliasesPackage" value="com.immoc.entity" /> <!-- 上面一行中原代码没有o2o --> <property name="mapperLocations" value="classpath:mapper/*.xml" /> </bean> <!-- 配置dao接口包,动态实现dao接口 --> <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer"> <property name="sqlSessionFactoryBeanName" value="sqlSessionFactory" /> <property name="basePackage" value="com.immoc.o2o.dao" /> <!-- 上面一行中原代码没有o2o,后来又加上了 --> </bean> </beans> ``` 顺便说一下,debug真的好难呀,随便一下一天就过去了
自学MVC做的JAVAEE网站,遇到404求救
![图片说明](https://img-ask.csdn.net/upload/201911/22/1574424804_499937.png) ![图片说明](https://img-ask.csdn.net/upload/201911/22/1574424813_768240.png) 不知道如何解决 很绝望 ![图片说明](https://img-ask.csdn.net/upload/201911/22/1574424869_990973.png) 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server version: Apache Tomcat/8.5.41 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server built: May 4 2019 09:17:16 UTC 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server number: 8.5.41.0 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Name: Windows 8.1 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Version: 6.3 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Architecture: amd64 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Java Home: C:\Program Files\Java\jdk1.8.0\jre 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Version: 1.8.0-b132 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Vendor: Oracle Corporation 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_BASE: D:\JAVA others\apache-tomcat-8.5.41 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_HOME: D:\JAVA others\apache-tomcat-8.5.41 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.base=D:\JAVA others\apache-tomcat-8.5.41 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.home=D:\JAVA others\apache-tomcat-8.5.41 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dwtp.deploy=D:\JAVA others\apache-tomcat-8.5.41\webapps 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Djava.endorsed.dirs=D:\JAVA others\apache-tomcat-8.5.41\endorsed 十一月 22, 2019 8:08:04 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dfile.encoding=GBK 十一月 22, 2019 8:08:04 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent 信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [C:\Program Files\Java\jdk1.8.0\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Program Files/Java/jdk1.8.0/bin/../jre/bin/server;C:/Program Files/Java/jdk1.8.0/bin/../jre/bin;C:/Program Files/Java/jdk1.8.0/bin/../jre/lib/amd64;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Java\jdk1.8.0\bin;C:\Program Files (x86)\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\nodejs\;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies\;D:\JAVA others\apache-maven-3.6.1\bin;C:\Users\Administrator\AppData\Local\Microsoft\WindowsApps;C:\Users\Administrator\AppData\Roaming\npm;E:\Mysql\mysql-5.7.27-winx64\\bin;C:\Program Files (x86)\GtkSharp\2.12\bin;C:\Program Files\Common Files\Autodesk Shared\;C:\Program Files (x86)\Autodesk\Backburner\;C:\Users\Administrator\AppData\Local\Microsoft\WindowsApps;C:\Users\Administrator\AppData\Roaming\npm;C:\Users\Administrator\Desktop;;.] 十一月 22, 2019 8:08:04 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["http-nio-8080"] 十一月 22, 2019 8:08:04 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 十一月 22, 2019 8:08:05 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["ajp-nio-8009"] 十一月 22, 2019 8:08:05 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 十一月 22, 2019 8:08:05 下午 org.apache.catalina.startup.Catalina load 信息: Initialization processed in 686 ms 十一月 22, 2019 8:08:05 下午 org.apache.catalina.core.StandardService startInternal 信息: Starting service [Catalina] 十一月 22, 2019 8:08:05 下午 org.apache.catalina.core.StandardEngine startInternal 信息: Starting Servlet Engine: Apache Tomcat/8.5.41 十一月 22, 2019 8:08:05 下午 org.apache.jasper.servlet.TldScanner scanJars 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 十一月 22, 2019 8:08:10 下午 org.apache.catalina.util.SessionIdGeneratorBase createSecureRandom 警告: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [5,002] milliseconds. 十一月 22, 2019 8:08:10 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\docs] 十一月 22, 2019 8:08:10 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\docs] has finished in [19] ms 十一月 22, 2019 8:08:10 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\examples] 十一月 22, 2019 8:08:10 下午 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: contextInitialized() 十一月 22, 2019 8:08:10 下午 org.apache.catalina.core.ApplicationContext log 信息: SessionListener: contextInitialized() 十一月 22, 2019 8:08:10 下午 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: attributeAdded('StockTicker', 'async.Stockticker@1a91efec') 十一月 22, 2019 8:08:10 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\examples] has finished in [306] ms 十一月 22, 2019 8:08:10 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\host-manager] 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\host-manager] has finished in [26] ms 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\manager] 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\manager] has finished in [31] ms 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\ROOT] 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory [D:\JAVA others\apache-tomcat-8.5.41\webapps\ROOT] has finished in [19] ms 十一月 22, 2019 8:08:11 下午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["http-nio-8080"] 十一月 22, 2019 8:08:11 下午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["ajp-nio-8009"] 十一月 22, 2019 8:08:11 下午 org.apache.catalina.startup.Catalina start 信息: Server startup in 6062 ms ![图片说明](https://img-ask.csdn.net/upload/201911/22/1574424946_347972.png)![图片说明](https://img-ask.csdn.net/upload/201911/22/1574424951_857846.png)
javaweb程序在eclipse上突然无法运行
之前写的一个web项目,能正常运行。然后中间考试了几天,再打开程序就不能运行了。 直接maven打包放到tomcat中的webapps中可以运行,但是在eclipse中就一直报下面的错误: 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/insurance]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:939) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:748) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/insurance]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ... 6 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.webresources.StandardRoot@a00ee03] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:4860) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4995) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more Caused by: org.apache.catalina.LifecycleException: Failed to initialize component [org.apache.catalina.webresources.JarResourceSet@17bf21a6] at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:112) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140) at org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.java:724) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 9 more Caused by: java.lang.IllegalArgumentException: java.util.zip.ZipException: invalid LOC header (bad signature) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:142) at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107) ... 12 more Caused by: java.util.zip.ZipException: invalid LOC header (bad signature) at java.util.zip.ZipFile.read(Native Method) at java.util.zip.ZipFile.access$1400(ZipFile.java:60) at java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:717) at java.util.zip.ZipFile$ZipFileInflaterInputStream.fill(ZipFile.java:419) at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158) at sun.misc.IOUtils.readFully(IOUtils.java:65) at java.util.jar.JarFile.getBytes(JarFile.java:425) at java.util.jar.JarFile.getManifestFromReference(JarFile.java:193) at java.util.jar.JarFile.getManifest(JarFile.java:180) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:140) ... 13 more 十二月 05, 2017 7:50:16 下午 org.apache.catalina.core.ContainerBase startInternal 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:939) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.startup.Catalina.start(Catalina.java:670) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:748) Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:947) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 6 more 十二月 05, 2017 7:50:16 下午 org.apache.catalina.startup.Catalina start 严重: The required Server component failed to start so Tomcat is unable to start. org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.startup.Catalina.start(Catalina.java:670) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:353) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:493) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 7 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 9 more Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:947) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 11 more 网上找遍方法都不行,在IDEA也是一样的错误,其他的项目也是一样的错。重装tomcat了也不行。 maven仓库没问题,删了重新下也是一样,然后项目maven test也是build success的。
新手提问,十万火急:eclipse中启动服务器报错
以前运行好好的,现在不能启动了,不知道怎么回事,网上也找不到原因,求大神们帮忙解决一下,十分感谢!! <br><br><br> Server Tomcat v8.0 Server at localhost failed to start. ![图片说明](https://img-ask.csdn.net/upload/201909/21/1569074501_604160.png) <br><br><br> 有人说是配置文件问题,看一下。。 <br><br><br> ![图片说明](https://img-ask.csdn.net/upload/201909/21/1569074681_560506.png) <br><br><br> 报错信息比较多,我复制一下:<br><br><br> ``` 九月 21, 2019 10:06:36 下午 org.apache.tomcat.util.digester.SetPropertiesRule begin 警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:testssm' did not find a matching property. 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server version: Apache Tomcat/8.0.52 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server built: Apr 28 2018 16:24:29 UTC 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Server number: 8.0.52.0 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Name: Windows 7 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: OS Version: 6.1 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Architecture: x86 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Java Home: C:\Java\jdk\jre 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Version: 1.8.0_65-b17 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: JVM Vendor: Oracle Corporation 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_BASE: C:\code\.metadata\.plugins\org.eclipse.wst.server.core\tmp0 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: CATALINA_HOME: C:\tomcat\apache-tomcat-8.0.52 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.base=C:\code\.metadata\.plugins\org.eclipse.wst.server.core\tmp0 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dcatalina.home=C:\tomcat\apache-tomcat-8.0.52 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dwtp.deploy=C:\tomcat\apache-tomcat-8.0.52\webapps 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Djava.endorsed.dirs=C:\tomcat\apache-tomcat-8.0.52\endorsed 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.VersionLoggerListener log 信息: Command line argument: -Dfile.encoding=GBK 九月 21, 2019 10:06:36 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent 信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Java\jdk\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Java/jdk/bin/../jre/bin/client;C:/Java/jdk/bin/../jre/bin;C:/Java/jdk/bin/../jre/lib/i386;C:\Java\jdk\bin;C:\Java\apache-maven-3.5.3\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Intel\OpenCL SDK\2.0\bin\x86;C:\Program Files (x86)\Intel\OpenCL SDK\2.0\bin\x64;C:\Program Files\Git\cmd;C:\code\eclipse;;. 九月 21, 2019 10:06:36 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["http-nio-8080"] 九月 21, 2019 10:06:36 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 九月 21, 2019 10:06:36 下午 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["ajp-nio-8009"] 九月 21, 2019 10:06:36 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector 信息: Using a shared selector for servlet write/read 九月 21, 2019 10:06:36 下午 org.apache.catalina.startup.Catalina load 信息: Initialization processed in 680 ms 九月 21, 2019 10:06:36 下午 org.apache.catalina.core.StandardService startInternal 信息: Starting service Catalina 九月 21, 2019 10:06:36 下午 org.apache.catalina.core.StandardEngine startInternal 信息: Starting Servlet Engine: Apache Tomcat/8.0.52 九月 21, 2019 10:06:37 下午 org.apache.catalina.util.SessionIdGeneratorBase createSecureRandom 警告: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [125] milliseconds. 九月 21, 2019 10:06:37 下午 org.apache.catalina.core.ContainerBase startInternal 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/testssm]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:945) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:871) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1410) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1400) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/testssm]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) ... 6 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.webresources.StandardRoot@fdd2b1] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:5016) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5149) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 6 more Caused by: org.apache.catalina.LifecycleException: Failed to initialize component [org.apache.catalina.webresources.JarResourceSet@154fd45] at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:135) at org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.java:722) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 9 more Caused by: java.lang.IllegalArgumentException: java.util.zip.ZipException: invalid LOC header (bad signature) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:142) at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:102) ... 12 more Caused by: java.util.zip.ZipException: invalid LOC header (bad signature) at java.util.zip.ZipFile.read(Native Method) at java.util.zip.ZipFile.access$1400(ZipFile.java:60) at java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:716) at java.util.zip.ZipFile$ZipFileInflaterInputStream.fill(ZipFile.java:419) at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158) at sun.misc.IOUtils.readFully(IOUtils.java:65) at java.util.jar.JarFile.getBytes(JarFile.java:425) at java.util.jar.JarFile.getManifestFromReference(JarFile.java:193) at java.util.jar.JarFile.getManifest(JarFile.java:180) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:140) ... 13 more 九月 21, 2019 10:06:37 下午 org.apache.catalina.core.ContainerBase startInternal 严重: A child container failed during start java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at java.util.concurrent.FutureTask.report(FutureTask.java:122) at java.util.concurrent.FutureTask.get(FutureTask.java:192) at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:945) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:441) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:789) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) at org.apache.catalina.startup.Catalina.start(Catalina.java:641) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:349) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:483) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1410) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1400) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:953) at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:871) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 6 more 九月 21, 2019 10:06:37 下午 org.apache.catalina.startup.Catalina start 严重: The required Server component failed to start so Tomcat is unable to start. org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.startup.Catalina.start(Catalina.java:641) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:349) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:483) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:789) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 7 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:441) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 9 more Caused by: org.apache.catalina.LifecycleException: A child container failed during start at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:953) at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145) ... 11 more 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol pause 信息: Pausing ProtocolHandler ["http-nio-8080"] 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol pause 信息: Pausing ProtocolHandler ["ajp-nio-8009"] 九月 21, 2019 10:06:37 下午 org.apache.catalina.core.StandardService stopInternal 信息: Stopping service Catalina 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol destroy 信息: Destroying ProtocolHandler ["http-nio-8080"] 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol destroy 严重: Failed to destroy end point associated with ProtocolHandler ["http-nio-8080"] java.lang.NullPointerException at org.apache.tomcat.util.net.NioEndpoint.releaseCaches(NioEndpoint.java:315) at org.apache.tomcat.util.net.NioEndpoint.unbind(NioEndpoint.java:491) at org.apache.tomcat.util.net.AbstractEndpoint.destroy(AbstractEndpoint.java:896) at org.apache.coyote.AbstractProtocol.destroy(AbstractProtocol.java:551) at org.apache.catalina.connector.Connector.destroyInternal(Connector.java:1023) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:589) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:879) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.startup.Catalina.start(Catalina.java:645) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:349) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:483) 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol destroy 信息: Destroying ProtocolHandler ["ajp-nio-8009"] 九月 21, 2019 10:06:37 下午 org.apache.coyote.AbstractProtocol destroy 严重: Failed to destroy end point associated with ProtocolHandler ["ajp-nio-8009"] java.lang.NullPointerException at org.apache.tomcat.util.net.NioEndpoint.releaseCaches(NioEndpoint.java:315) at org.apache.tomcat.util.net.NioEndpoint.unbind(NioEndpoint.java:491) at org.apache.tomcat.util.net.AbstractEndpoint.destroy(AbstractEndpoint.java:896) at org.apache.coyote.AbstractProtocol.destroy(AbstractProtocol.java:551) at org.apache.catalina.connector.Connector.destroyInternal(Connector.java:1023) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:589) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:879) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.startup.Catalina.start(Catalina.java:645) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:349) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:483) ```
mybatis在使用foreach进行List集合查询时,sql映射时多余问号,网上没有类似问题,求大神指教
近日,在编写Spring Mvc的时候,出现一个特别怪的事情,我正常使用 ``` <select id="findListWithIdsString" resultType="OrderProduct" parameterType="java.util.List"> SELECT <include refid="orderProductOwnColumns"/> a.del_flag AS "delFlag" FROM tbl_order_product a <where> a.del_flag = '0' AND a.id in ('XXXXX','XXXX') </where> </select> ``` 以上这个这个是** 没问题的**,但是,当我改为从java**传值List**的时候,就出问题了,xml代码: ``` <select id="findListWithIdsString" resultType="OrderProduct" parameterType="java.util.List"> SELECT <include refid="orderProductOwnColumns"/> a.del_flag AS "delFlag" FROM tbl_order_product a <where> a.del_flag = '0' <choose> <when test="inComingIds != null and inComingIds.size()>0"> AND a.id in <foreach collection="inComingIds" item="item" index="index" open="(" close=")" separator="," >                  #{item}              </foreach> </when> <otherwise> AND a.id='0' </otherwise> </choose> </where> </select> ``` 然后我的前java端代码是: ``` List<String> idList=new ArrayList<>();//传入的List String opIds=mp.getRelatedOrderProductIds();//前端获取的String Collections.addAll(idList,StringUtils.split(opIds, ","));//转化为List OrderProduct opForSearch=new OrderProduct(); opForSearch.setInComingIds(idList); orderProductService.findListWithIdsString(opForSearch); ``` 数据库配置如下: ``` ?useUnicode=true&characterEncoding=utf-8 ``` 出错信息: ``` 2019-05-01 15:28:43,034 DEBUG [modules.sys.dao.OrderProductDao.findListWithIdsString] - ==> Preparing: SELECT a.id AS "id", a.order_id AS "order.id", a.actual_flow_id AS "actualFlowId", a.category_id AS "companyCategory.id", a.parent_order_product_id as "parentOrderProductId", a.price AS "price", a.amount AS "amount", a.product_name AS "productName", a.a_product_name AS "aProductName", a.product_description AS "productDescription", a.delivery_time AS "deliveryTime", a.rate AS "rate", a.is_a_confirm AS "isAConfirm", a.confirm_userid AS "confirmUserid", a.A_confirm_time AS "aConfirmTime", a.order_product_type AS "orderProductType", a.inner_delivery_time AS "innerDeliveryTime", a.companyB_priority AS "companyBPriority", a.companyA_priority AS "companyAPriority", a.order_product_status AS "orderProductStatus", a.product_sn AS "productSn", a.a_product_sn AS "aProductSn", a.source AS "source", a.A_company_id AS "aCompany.id", a.B_company_id AS "bCompany.id", a.take_materiel_status AS "takeMaterielStatus", a.create_by AS "createBy.id", a.create_date AS "createDate", a.update_by AS "updateBy.id", a.update_date AS "updateDate", "ORDER_PRODUCT" AS "resourceType", a.remarks AS "remarks", a.down_order_status AS "downOrderStatus", a.batch_number AS "batchNumber", a.closure AS "closure", a.closure_money AS "closureMoney", a.del_flag AS "delFlag" FROM tbl_order_product a WHERE a.del_flag = '0' AND a.id in ( ???????????? ??? ? ???????? ??? , ???????????? ??? ? ???????? ??? ) 2019-05-01 15:28:43,034 DEBUG [modules.sys.dao.OrderProductDao.findListWithIdsString] - ==> Parameters: 54eca8e0409a4f5b81919ecbf7b85d44(String), 4fda20df078945aeaae3960f265795c1(String) 2019-05-01 15:28:43,094 ERROR [500.jsp] - ### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 ### The error may exist in D:\apache-tomcat-8.0.53-ft\webapps\blanink-web\WEB-INF\classes\mappings\modules\sys\OrderProductDao.xml ### The error may involve com.blanink.business.modules.sys.dao.OrderProductDao.findListWithIdsString-Inline ### The error occurred while setting parameters ### SQL: SELECT a.id AS "id", a.order_id AS "order.id", a.actual_flow_id AS "actualFlowId", a.category_id AS "companyCategory.id", a.parent_order_product_id as "parentOrderProductId", a.price AS "price", a.amount AS "amount", a.product_name AS "productName", a.a_product_name AS "aProductName", a.product_description AS "productDescription", a.delivery_time AS "deliveryTime", a.rate AS "rate", a.is_a_confirm AS "isAConfirm", a.confirm_userid AS "confirmUserid", a.A_confirm_time AS "aConfirmTime", a.order_product_type AS "orderProductType", a.inner_delivery_time AS "innerDeliveryTime", a.companyB_priority AS "companyBPriority", a.companyA_priority AS "companyAPriority", a.order_product_status AS "orderProductStatus", a.product_sn AS "productSn", a.a_product_sn AS "aProductSn", a.source AS "source", a.A_company_id AS "aCompany.id", a.B_company_id AS "bCompany.id", a.take_materiel_status AS "takeMaterielStatus", a.create_by AS "createBy.id", a.create_date AS "createDate", a.update_by AS "updateBy.id", a.update_date AS "updateDate", "ORDER_PRODUCT" AS "resourceType", a.remarks AS "remarks", a.down_order_status AS "downOrderStatus", a.batch_number AS "batchNumber", a.closure AS "closure", a.closure_money AS "closureMoney", a.del_flalag AS "delFlag" FROM tbl_order_product a WHERE a.del_flag = '0' AND a.id in ( ???????????? ??? ? ???????? ??? , ???????????? ??? ? ???????? ??? ) ### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 ; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 org.springframework.jdbc.BadSqlGrammarException: ### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 ### The error may exist in D:\apache-tomcat-8.0.53-ft\webapps\blanink-web\WEB-INF\classes\mappings\modules\sys\OrderProductDao.xml ### The error may involve com.blanink.business.modules.sys.dao.OrderProductDao.findListWithIdsString-Inline ### The error occurred while setting parameters ### SQL: SELECT a.id AS "id", a.order_id AS "order.id", a.actual_flow_id AS "actualFlowId", a.category_id AS "companyCategory.id", a.parent_order_product_id as "parentOrderProductId", a.price AS "price", a.amount AS "amount", a.product_name AS "productName", a.a_product_name AS "aProductName", a.product_description AS "productDescription", a.delivery_time AS "deliveryTime", a.rate AS "rate", a.is_a_confirm AS "isAConfirm", a.confirm_userid AS "confirmUserid", a.A_confirm_time AS "aConfirmTime", a.order_product_type AS "orderProductType", a.inner_delivery_time AS "innerDeliveryTime", a.companyB_priority AS "companyBPriority", a.companyA_priority AS "companyAPriority", a.order_product_status AS "orderProductStatus", a.product_sn AS "productSn", a.a_product_sn AS "aProductSn", a.source AS "source", a.A_company_id AS "aCompany.id", a.B_company_id AS "bCompany.id", a.take_materiel_status AS "takeMaterielStatus", a.create_by AS "createBy.id", a.create_date AS "createDate", a.update_by AS "updateBy.id", a.update_date AS "updateDate", "ORDER_PRODUCT" AS "resourceType", a.remarks AS "remarks", a.down_order_status AS "downOrderStatus", a.batch_number AS "batchNumber", a.closure AS "closure", a.closure_money AS "closureMoney", a.del_flag AS "delFlag", a.del_flag AS "delFlag" FROM tbl_order_product a WHERE a.del_flag = '0' AND a.id in ( ???????????? ??? ? ???????? ??? , ???????????? ??? ? ???????? ??? ) ### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 ; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '??? '54eca8e0409a4f5b81919ecbf7b85d44' ???????? ??? , ?????' at line 47 at org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator.doTranslate(SQLErrorCodeSQLExceptionTranslator.java:231) at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:73) at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:74) at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:399) at com.sun.proxy.$Proxy27.selectList(Unknown Source) at org.mybatis.spring.SqlSessionTemplate.selectList(SqlSessionTemplate.java:205) at org.apache.ibatis.binding.MapperMethod.executeForMany(MapperMethod.java:119) at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:63) ```
相见恨晚的超实用网站
相见恨晚的超实用网站 持续更新中。。。
Java学习的正确打开方式
在博主认为,对于入门级学习java的最佳学习方法莫过于视频+博客+书籍+总结,前三者博主将淋漓尽致地挥毫于这篇博客文章中,至于总结在于个人,实际上越到后面你会发现学习的最好方式就是阅读参考官方文档其次就是国内的书籍,博客次之,这又是一个层次了,这里暂时不提后面再谈。博主将为各位入门java保驾护航,各位只管冲鸭!!!上天是公平的,只要不辜负时间,时间自然不会辜负你。 何谓学习?博主所理解的学习,它是一个过程,是一个不断累积、不断沉淀、不断总结、善于传达自己的个人见解以及乐于分享的过程。
程序员必须掌握的核心算法有哪些?
由于我之前一直强调数据结构以及算法学习的重要性,所以就有一些读者经常问我,数据结构与算法应该要学习到哪个程度呢?,说实话,这个问题我不知道要怎么回答你,主要取决于你想学习到哪些程度,不过针对这个问题,我稍微总结一下我学过的算法知识点,以及我觉得值得学习的算法。这些算法与数据结构的学习大多数是零散的,并没有一本把他们全部覆盖的书籍。下面是我觉得值得学习的一些算法以及数据结构,当然,我也会整理一些看过...
有哪些让程序员受益终生的建议
从业五年多,辗转两个大厂,出过书,创过业,从技术小白成长为基层管理,联合几个业内大牛回答下这个问题,希望能帮到大家,记得帮我点赞哦。 敲黑板!!!读了这篇文章,你将知道如何才能进大厂,如何实现财务自由,如何在工作中游刃有余,这篇文章很长,但绝对是精品,记得帮我点赞哦!!!! 一腔肺腑之言,能看进去多少,就看你自己了!!! 目录: 在校生篇: 为什么要尽量进大厂? 如何选择语言及方...
大学四年自学走来,这些私藏的实用工具/学习网站我贡献出来了
大学四年,看课本是不可能一直看课本的了,对于学习,特别是自学,善于搜索网上的一些资源来辅助,还是非常有必要的,下面我就把这几年私藏的各种资源,网站贡献出来给你们。主要有:电子书搜索、实用工具、在线视频学习网站、非视频学习网站、软件下载、面试/求职必备网站。 注意:文中提到的所有资源,文末我都给你整理好了,你们只管拿去,如果觉得不错,转发、分享就是最大的支持了。 一、电子书搜索 对于大部分程序员...
linux系列之常用运维命令整理笔录
本博客记录工作中需要的linux运维命令,大学时候开始接触linux,会一些基本操作,可是都没有整理起来,加上是做开发,不做运维,有些命令忘记了,所以现在整理成博客,当然vi,文件操作等就不介绍了,慢慢积累一些其它拓展的命令,博客不定时更新 free -m 其中:m表示兆,也可以用g,注意都要小写 Men:表示物理内存统计 total:表示物理内存总数(total=used+free) use...
比特币原理详解
一、什么是比特币 比特币是一种电子货币,是一种基于密码学的货币,在2008年11月1日由中本聪发表比特币白皮书,文中提出了一种去中心化的电子记账系统,我们平时的电子现金是银行来记账,因为银行的背后是国家信用。去中心化电子记账系统是参与者共同记账。比特币可以防止主权危机、信用风险。其好处不多做赘述,这一层面介绍的文章很多,本文主要从更深层的技术原理角度进行介绍。 二、问题引入 假设现有4个人...
程序员接私活怎样防止做完了不给钱?
首先跟大家说明一点,我们做 IT 类的外包开发,是非标品开发,所以很有可能在开发过程中会有这样那样的需求修改,而这种需求修改很容易造成扯皮,进而影响到费用支付,甚至出现做完了项目收不到钱的情况。 那么,怎么保证自己的薪酬安全呢? 我们在开工前,一定要做好一些证据方面的准备(也就是“讨薪”的理论依据),这其中最重要的就是需求文档和验收标准。一定要让需求方提供这两个文档资料作为开发的基础。之后开发...
网页实现一个简单的音乐播放器(大佬别看。(⊙﹏⊙))
今天闲着无事,就想写点东西。然后听了下歌,就打算写个播放器。 于是乎用h5 audio的加上js简单的播放器完工了。 演示地点演示 html代码如下` music 这个年纪 七月的风 音乐 ` 然后就是css`*{ margin: 0; padding: 0; text-decoration: none; list-...
Python十大装B语法
Python 是一种代表简单思想的语言,其语法相对简单,很容易上手。不过,如果就此小视 Python 语法的精妙和深邃,那就大错特错了。本文精心筛选了最能展现 Python 语法之精妙的十个知识点,并附上详细的实例代码。如能在实战中融会贯通、灵活使用,必将使代码更为精炼、高效,同时也会极大提升代码B格,使之看上去更老练,读起来更优雅。
数据库优化 - SQL优化
以实际SQL入手,带你一步一步走上SQL优化之路!
2019年11月中国大陆编程语言排行榜
2019年11月2日,我统计了某招聘网站,获得有效程序员招聘数据9万条。针对招聘信息,提取编程语言关键字,并统计如下: 编程语言比例 rank pl_ percentage 1 java 33.62% 2 cpp 16.42% 3 c_sharp 12.82% 4 javascript 12.31% 5 python 7.93% 6 go 7.25% 7 p...
通俗易懂地给女朋友讲:线程池的内部原理
餐盘在灯光的照耀下格外晶莹洁白,女朋友拿起红酒杯轻轻地抿了一小口,对我说:“经常听你说线程池,到底线程池到底是个什么原理?”
《奇巧淫技》系列-python!!每天早上八点自动发送天气预报邮件到QQ邮箱
将代码部署服务器,每日早上定时获取到天气数据,并发送到邮箱。 也可以说是一个小型人工智障。 知识可以运用在不同地方,不一定非是天气预报。
经典算法(5)杨辉三角
杨辉三角 是经典算法,这篇博客对它的算法思想进行了讲解,并有完整的代码实现。
英特尔不为人知的 B 面
从 PC 时代至今,众人只知在 CPU、GPU、XPU、制程、工艺等战场中,英特尔在与同行硬件芯片制造商们的竞争中杀出重围,且在不断的成长进化中,成为全球知名的半导体公司。殊不知,在「刚硬」的背后,英特尔「柔性」的软件早已经做到了全方位的支持与支撑,并持续发挥独特的生态价值,推动产业合作共赢。 而对于这一不知人知的 B 面,很多人将其称之为英特尔隐形的翅膀,虽低调,但是影响力却不容小觑。 那么,在...
腾讯算法面试题:64匹马8个跑道需要多少轮才能选出最快的四匹?
昨天,有网友私信我,说去阿里面试,彻底的被打击到了。问了为什么网上大量使用ThreadLocal的源码都会加上private static?他被难住了,因为他从来都没有考虑过这个问题。无独有偶,今天笔者又发现有网友吐槽了一道腾讯的面试题,我们一起来看看。 腾讯算法面试题:64匹马8个跑道需要多少轮才能选出最快的四匹? 在互联网职场论坛,一名程序员发帖求助到。二面腾讯,其中一个算法题:64匹...
面试官:你连RESTful都不知道我怎么敢要你?
干货,2019 RESTful最贱实践
刷了几千道算法题,这些我私藏的刷题网站都在这里了!
遥想当年,机缘巧合入了 ACM 的坑,周边巨擘林立,从此过上了"天天被虐似死狗"的生活… 然而我是谁,我可是死狗中的战斗鸡,智力不够那刷题来凑,开始了夜以继日哼哧哼哧刷题的日子,从此"读题与提交齐飞, AC 与 WA 一色 ",我惊喜的发现被题虐既刺激又有快感,那一刻我泪流满面。这么好的事儿作为一个正直的人绝不能自己独享,经过激烈的颅内斗争,我决定把我私藏的十几个 T 的,阿不,十几个刷题网...
SQL-小白最佳入门sql查询一
不要偷偷的查询我的个人资料,即使你再喜欢我,也不要这样,真的不好;
JavaScript 为什么能活到现在?
作者 | 司徒正美 责编 |郭芮 出品 | CSDN(ID:CSDNnews) JavaScript能发展到现在的程度已经经历不少的坎坷,早产带来的某些缺陷是永久性的,因此浏览器才有禁用JavaScript的选项。甚至在jQuery时代有人问出这样的问题,jQuery与JavaScript哪个快?在Babel.js出来之前,发明一门全新的语言代码代替JavaScript...
项目中的if else太多了,该怎么重构?
介绍 最近跟着公司的大佬开发了一款IM系统,类似QQ和微信哈,就是聊天软件。我们有一部分业务逻辑是这样的 if (msgType = "文本") { // dosomething } else if(msgType = "图片") { // doshomething } else if(msgType = "视频") { // doshomething } else { // doshom...
致 Python 初学者
欢迎来到“Python进阶”专栏!来到这里的每一位同学,应该大致上学习了很多 Python 的基础知识,正在努力成长的过程中。在此期间,一定遇到了很多的困惑,对未来的学习方向感到迷茫。我非常理解你们所面临的处境。我从2007年开始接触 python 这门编程语言,从2009年开始单一使用 python 应对所有的开发工作,直至今天。回顾自己的学习过程,也曾经遇到过无数的困难,也曾经迷茫过、困惑过。开办这个专栏,正是为了帮助像我当年一样困惑的 Python 初学者走出困境、快速成长。希望我的经验能真正帮到你
Python 编程开发 实用经验和技巧
Python是一门很灵活的语言,也有很多实用的方法,有时候实现一个功能可以用多种方法实现,我这里总结了一些常用的方法和技巧,包括小数保留指定位小数、判断变量的数据类型、类方法@classmethod、制表符中文对齐、遍历字典、datetime.timedelta的使用等,会持续更新......
吐血推荐珍藏的Visual Studio Code插件
作为一名Java工程师,由于工作需要,最近一个月一直在写NodeJS,这种经历可以说是一部辛酸史了。好在有神器Visual Studio Code陪伴,让我的这段经历没有更加困难。眼看这段经历要告一段落了,今天就来给大家分享一下我常用的一些VSC的插件。 VSC的插件安装方法很简单,只需要点击左侧最下方的插件栏选项,然后就可以搜索你想要的插件了。 下面我们进入正题 Material Theme ...
实战:如何通过python requests库写一个抓取小网站图片的小爬虫
有点爱好的你,偶尔应该会看点图片文字,最近小网站经常崩溃消失,不如想一个办法本地化吧,把小照片珍藏起来! 首先,准备一个珍藏的小网站,然后就可以开始啦! 第一步 我们先写一个获取网站的url的链接,因为url常常是由page或者,其他元素构成,我们就把他分离出来,我找到的网站主页下有图片区 图片区内有标题页,一个标题里有10张照片大概 所以步骤是: 第一步:进入图片区的标题页 def getH...
“狗屁不通文章生成器”登顶GitHub热榜,分分钟写出万字形式主义大作
一、垃圾文字生成器介绍 最近在浏览GitHub的时候,发现了这样一个骨骼清奇的雷人项目,而且热度还特别高。 项目中文名:狗屁不通文章生成器 项目英文名:BullshitGenerator 根据作者的介绍,他是偶尔需要一些中文文字用于GUI开发时测试文本渲染,因此开发了这个废话生成器。但由于生成的废话实在是太过富于哲理,所以最近已经被小伙伴们给玩坏了。 他的文风可能是这样的: 你发现,...
程序员:我终于知道post和get的区别
是一个老生常谈的话题,然而随着不断的学习,对于以前的认识有很多误区,所以还是需要不断地总结的,学而时习之,不亦说乎
《程序人生》系列-这个程序员只用了20行代码就拿了冠军
你知道的越多,你不知道的越多 点赞再看,养成习惯GitHub上已经开源https://github.com/JavaFamily,有一线大厂面试点脑图,欢迎Star和完善 前言 这一期不算《吊打面试官》系列的,所有没前言我直接开始。 絮叨 本来应该是没有这期的,看过我上期的小伙伴应该是知道的嘛,双十一比较忙嘛,要值班又要去帮忙拍摄年会的视频素材,还得搞个程序员一天的Vlog,还要写BU...
加快推动区块链技术和产业创新发展,2019可信区块链峰会在京召开
11月8日,由中国信息通信研究院、中国通信标准化协会、中国互联网协会、可信区块链推进计划联合主办,科技行者协办的2019可信区块链峰会将在北京悠唐皇冠假日酒店开幕。   区块链技术被认为是继蒸汽机、电力、互联网之后,下一代颠覆性的核心技术。如果说蒸汽机释放了人类的生产力,电力解决了人类基本的生活需求,互联网彻底改变了信息传递的方式,区块链作为构造信任的技术有重要的价值。   1...
相关热词 c#中dns类 c#合并的excel c# implicit c#怎么保留3个小数点 c# 串口通信、 网络调试助手c# c# 泛型比较大小 c#解压分卷问题 c#启动居中 c# 逻辑或运算符
立即提问