尝试连接到Localhost上的Tomcat服务器时收到HTTP 500错误

问题描述

我正在尝试在Springtools Suite中运行Tomcat 9.0服务器,该项目对我正在使用的其他开发人员有效,但是在尝试加载它时无法连接到Tomcat服务器。

这是我在浏览器中收到的HTTP 500通知旁边的错误

Message Servlet.init() for servlet [UsersTestServlet] threw exception

Description The server encountered an unexpected condition that prevented it from fulfilling the request.

Exception

javax.servlet.servletexception: Servlet.init() for servlet [UsersTestServlet] threw exception
    org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
    org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
    org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690)
    org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
    org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373)
    org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
    org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
    org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1589)
    org.apache.tomcat.util.net.socketProcessorBase.run(SocketProcessorBase.java:49)
    java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    java.lang.Thread.run(Thread.java:748)

Root Cause

com.deere.u90.iaf.exception.ContextRuntimeException: Error determining 'full path'.  'config/Local.properties' not found in ''
timestamp: 2020-08-20 09:27:47.454 AM CDT (1597933667454)
    com.deere.u90.iaf.configuration.ConfigurationPropertiesHelper.DetermineFullPath(ConfigurationPropertiesHelper.java:441)
    com.deere.u90.iaf.configuration.IAFConfigurationLocation.determineFullPath(IAFConfigurationLocation.java:309)
    com.deere.u90.iaf.configuration.IAFConfigurationLocation.loadPropertiesAsResource(IAFConfigurationLocation.java:233)
    com.deere.u90.iaf.configuration.IAFConfigurationLocation.loadPropertiesFromFile(IAFConfigurationLocation.java:181)
    com.deere.u90.iaf.configuration.IAFConfigurationLocation.loadProperties(IAFConfigurationLocation.java:146)
    com.deere.u90.iaf.configuration.IAFConfigurationAdapter.initialize(IAFConfigurationAdapter.java:209)
    com.deere.u90.iaf.configuration.ConfigurationFactory.initializeView(ConfigurationFactory.java:119)
    com.deere.u90.iaf.configuration.ConfigurationFactory.initializeView(ConfigurationFactory.java:108)
    com.deere.u90.iaf.configuration.ConfigurationFactory.getInstance(ConfigurationFactory.java:43)
    com.deere.u90785.application.Application.getConfigurationView(Application.java:1314)
    com.deere.u90785.application.ApplicationProperties.GetString(ApplicationProperties.java:296)
    com.deere.u90785.application.ApplicationProperties.GetUrlBaseJsp(ApplicationProperties.java:329)
    com.deere.u90785.view.servlets.ApplicationServlet.init(ApplicationServlet.java:276)
    org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
    org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
    org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690)
    org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
    org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373)
    org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
    org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
    org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1589)
    org.apache.tomcat.util.net.socketProcessorBase.run(SocketProcessorBase.java:49)
    java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    java.lang.Thread.run(Thread.java:748)
Note The full stack trace of the root cause is available in the server logs.

我和其他开发人员感到困惑,因为他们没有收到此问题,并且那些在项目上工作了一段时间的人从未见过此错误。我不确定问题出在哪里以及何时进入控制台并单击此行org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)

我收到此信息弹出窗口:Source not found for org.apache.tomcat.util.threads.TaskThread

我是不熟悉Tomcat和Springtools的新手,所以不确定我是否在Java环境或Springtools中设置了某些配置不正确,或者在Tomcat服务器中是否设置了不正确。即使我在设置该工作区时遇到问题也设置了另一个工作区,也收到了这个问题,我的共同开发人员也为此感到沮丧。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)