簡體   English   中英

如何找到在谷歌應用引擎服務器上找不到的請求的URL / MailDispatcherServlet?

[英]How to locate the requested URL /MailDispatcherServlet that was not found on google app engine server?

我在使用谷歌應用引擎部署的網站上找到我的MailDispatcherServlet java文件時遇到問題。 這是一個單頁的網站,問題出在contact me表單中,我點擊提交瀏覽器的那一刻說它無法從Java Mail API找到我的servlet和我的邏輯。 我認為問題出在app.yaml文件中。 如何在我的java項目中找到我的Servlet和EJB文件的路徑? BTW我的項目在使用Glassfish服務器的本地機器上正常工作。

runtime: python27
api_version: 1
threadsafe: true

handlers:
- url: /
  static_files: website/index.html
  upload: website/index.html


- url: /
  static_dir: website

考慮到您使用的是app.yaml文件,我相信您正在使用App Engine Flexible環境。 您需要將文件更改為更像這樣[1],因為您的文件是為Python應用程序設置的。

您可以在此處找到App Engine靈活應用程序的示例[2]以獲取更多指導。

如果您使用的是App Engine Standard環境,則根本不需要app.yaml。 您可以在此處關注App Engine Standard上的示例應用程序[3]。

[1] App Engine上的Java應用程序上的App.yaml文件靈活性: https//github.com/GoogleCloudPlatform/getting-started-java/blob/master/bookshelf/2-structured-data/src/main/appengine/的app.yaml

[2] App Engine靈活文檔上的Bookshelf教程: https//cloud.google.com/java/getting-started/tutorial-app

[3] App Engine標准文檔留言板教程: https//cloud.google.com/appengine/docs/standard/java/building-app/

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM