Проблема Tomcat 7 после обновления с загрузкой сервлетов - PullRequest
0 голосов
/ 19 марта 2020

Итак, я сделал обновление до Tomcat 7, и теперь он работает под управлением 7.0.100. Пока все хорошо, но после запуска сервера мои веб-приложения теперь выдают ошибку, которую я никогда раньше не видел:

    Mrz 19, 2020 5:58:19 PM org.apache.catalina.core.StandardWrapperValve invoke
SCHWERWIEGEND: Servlet.service() for servlet [jsp] in context with path [/Project] threw exception [Unable to compile class for JSP] with root cause
java.lang.ClassNotFoundException: # Licensed to the Apache Software Foundation (ASF) under one or more
    at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1951)
    at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1794)
    at javax.el.ExpressionFactory.newInstance(ExpressionFactory.java:171)
    at javax.el.ExpressionFactory.newInstance(ExpressionFactory.java:117)
    at org.apache.jasper.compiler.PageInfo.<init>(PageInfo.java:79)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:116)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:394)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:370)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:354)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:660)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:400)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    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:219)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:492)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:165)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:1025)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:452)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1195)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:654)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:317)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Unknown Source)

Мне кажется, что я пытаюсь загрузить файл конфигурации как класс !? У кого-нибудь есть идея, откуда это взялось?

Каталина начинает нормально:

INFORMATION: Initialisiere ProtocolHandler["http-Project-8080"]
Mrz 19, 2020 5:46:35 PM org.apache.coyote.AbstractProtocol init
INFORMATION: Initialisiere ProtocolHandler["http-Project-443"]
Mrz 19, 2020 5:46:35 PM org.apache.coyote.AbstractProtocol init
INFORMATION: Initialisiere ProtocolHandler["ajp-Project-127.0.0.1-8009"]
Mrz 19, 2020 5:46:35 PM org.apache.catalina.startup.Catalina load
INFORMATION: Initialization processed in 3593 ms
Mrz 19, 2020 5:46:36 PM org.apache.catalina.core.StandardService startInternal
INFORMATION: Starting service [Catalina]
Mrz 19, 2020 5:46:36 PM org.apache.catalina.core.StandardEngine startInternal
INFORMATION: Starting Servlet Engine: Apache Tomcat/7.0.100
Mrz 19, 2020 5:46:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deploye Web-Applikations-Verzeichnis [C:\Program Files\Project\tomcat\webapps\ProjectWeb]
Mrz 19, 2020 5:46:39 PM org.apache.catalina.startup.TldConfig execute
INFORMATION: 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.
Mrz 19, 2020 5:47:41 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deployment of web application directory [C:\Program Files\Project\tomcat\webapps\ProjectWeb] has finished in [65.554] ms
Mrz 19, 2020 5:47:41 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deploye Web-Applikations-Verzeichnis [C:\Program Files\Project\tomcat\webapps\ROOT]
Mrz 19, 2020 5:47:41 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deployment of web application directory [C:\Program Files\Project\tomcat\webapps\ROOT] has finished in [240] ms
Mrz 19, 2020 5:47:41 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deploye Web-Applikations-Verzeichnis [C:\Program Files\Project\tomcat\webapps\SystemConfigurator]
Mrz 19, 2020 5:47:43 PM org.apache.catalina.startup.TldConfig execute
INFORMATION: 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.
Mrz 19, 2020 5:47:43 PM org.apache.catalina.startup.HostConfig deployDirectory
INFORMATION: Deployment of web application directory [C:\Program Files\Project\tomcat\webapps\SystemConfigurator] has finished in [1.342] ms
Mrz 19, 2020 5:47:43 PM org.apache.coyote.AbstractProtocol start
INFORMATION: Starting ProtocolHandler ["http-Project-8080"]
Mrz 19, 2020 5:47:43 PM org.apache.coyote.AbstractProtocol start
INFORMATION: Starting ProtocolHandler ["http-Project-443"]
Mrz 19, 2020 5:47:43 PM org.apache.coyote.AbstractProtocol start
INFORMATION: Starting ProtocolHandler ["ajp-Project-127.0.0.1-8009"]
Mrz 19, 2020 5:47:43 PM org.apache.catalina.startup.Catalina start
INFORMATION: Server startup in 67424 ms

1 Ответ

0 голосов
/ 23 апреля 2020

Возникла похожая проблема после обновления tomcat 7. Наконец обнаружил, что файл: / etc / tomcat / server. xml обновлен. И теперь AJP Connector был закомментирован.

 <!-- Define an AJP 1.3 Connector on port 8009 -->
    <!--
    <Connector protocol="AJP/1.3"
               address="::1"
               port="8009"
               redirectPort="8443" />
    -->

После отмены комментариев к строке и перезапуска tomcat наше приложение снова заработало.

...