我已经在 Springboot Rest 上部署了简单的 Web 应用程序,并成功将其部署在 Azure 云上,就像我的其他 Web 应用程序一样。
但是当我点击 web 应用程序的 azure URL 时,我收到 HTTP 状态 404 – 未找到。
azure 上的 webapp 的状态显示为“正在运行”,但我仍然收到 404。
请注意,该应用程序在我的本地计算机上完美运行,但在 azure 上运行不佳。
以下是错误消息详细信息,
"HTTP Status 404 – Not Found Type Status Report Message / Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists. Apache Tomcat/8.5.41"
下面是我在应用程序中使用的 azure maven 插件配置,
<groupId>com.microsoft.azure</groupId>
如果有人检查并帮助我解决此问题,将会非常有帮助。
提前致谢。
最佳答案
不知道您如何执行部署。我假设您没有将 WAR 文件部署到 webapps 文件夹中。如果您只是通过 Tomcat 复制文件,则不会像 WAR 文件那样自动加载这些文件。重新启动 Tomcat 服务器并查看您的应用程序是否已加载并开始工作。
关于java - Azure webapp HTTP 状态 404 – 未找到,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56578158/