使用Eclipse中的Google Cloud Endpoints调试Google Web应用程序项目 [英] Debugging Google Web Application projects with Google Cloud Endpoints in Eclipse

查看:125
本文介绍了使用Eclipse中的Google Cloud Endpoints调试Google Web应用程序项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的iOS应用程序使用基于Java的服务器,并使用Google Cloud Endpoints进行通信。通常,服务器在 https://myservice.appspot.com/_ah/api/rpc 上侦听。

My iOS app uses a Java-based server and communicates with it using Google Cloud Endpoints. Normally the server listens on https://myservice.appspot.com/_ah/api/rpc.

我可以调试我的服务器代码吗?当我运行它与调试为 | Eclipse中的Web应用程序,并将其URL更改为 https:// localhost:8888 / _ah / api / rpc 客户端无法连接。我不认为这是一个防火墙问题,因为具有 localhost:8888 的URL可用于其他客户端 - 服务器对。

How can I debug my server code? After I run it with Debug As | Web Application inside Eclipse and change its URL to https://localhost:8888/_ah/api/rpc the client cannot connect. I don't think it's a firewall issue because URLs with localhost:8888 work for other client-server pairs.

所以需要采取任何特殊的步骤来调试Google Web应用程序项目中的代码,使用Eclipse中的Google Cloud Endpoints,并且有更好的方法来设置客户端所需的URL,而不是将其编码(如我当前尝试的那样)? / p>

So does one need to take any special steps for debugging code in Google Web Application projects with Google Cloud Endpoints in Eclipse, and is there a better way to set their required URL on the client than hardcoding it (like I currently try)?

推荐答案

为什么这不工作的第一个原因是我尝试连接到 localhost over SSL。

The first cause why this did not work was that I tried to connect to localhost over SSL.

第二个原因是我的实际设备当然需要联系dev服务器,而不是 localhost ,但使用其远程IP地址(目前在我的WLAN上 10.0.0.2 )。

The second cause was that my real device of course needs to contact the dev server not as localhost, but using its remote IP address (currently 10.0.0.2 on my WLAN).

第三原因是我的OS X 10.9.3 Mac上的防火墙阻止我的真实设备连接到其端口8888.我不得不禁用所有传入连接并允许应用程序的传入连接系统偏好设置下的Eclipse 和 java 安全与安全隐私 | 防火墙选项。 (OS X将在第一次尝试连接时提示获得许可。)

The third cause was that the firewall on my OS X 10.9.3 Mac prevented my real device from connecting to its port 8888. I had to disable Block all incoming connections and allow incoming connections for the applications Eclipse and java under System Preferences | Security & Privacy | Firewall Options. (OS X will prompt for permission the first time a connection is attempted.)

这篇关于使用Eclipse中的Google Cloud Endpoints调试Google Web应用程序项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆