3
我的应用程序抛出这个错误:GAE网址提取服务为HTTPS
[INFO] Caused by: java.lang.ClassCastException: com.google.apphosting.utils.security.urlfetch.URLFetchServiceStreamHandler$Connection cannot be cast to javax.net.ssl.HttpsURLConnection
[INFO] at info.modprobe.browserid.Verifier.verify(Verifier.java:76)
而导致错误的代码是:
URL verifierURL = new URL(this.url);
String response = "";
HttpsURLConnection connection = (HttpsURLConnection) verifierURL
.openConnection(); // error here...
connection.setRequestMethod("POST");
connection.setRequestProperty("Content-Type",
"application/json; charset=utf-8");
connection.setDoOutput(true);
当尝试使用此library做Mozilla的个人验证。我想知道自从GAE网址提取服务支持HTTPS后会出现什么问题。
闻起来像一个导入问题,你可以请提供该类的导入块? – jirungaray 2015-04-06 22:18:26