我正在使用Linkedin - want制作Linkedin application.The,我面临的问题是我想要开发一个简单的桌面应用程序。相反,我必须说是一个控制台应用程序。问题出现在我得到这个错误的地方
Exception in thread "main" com.google.code.linkedinapi.client.oauth.LinkedInOAuthServiceException: oauth.signpost.exception.OAuthCommunicationException: Communication with the service provider failed: api.linkedin.com
at com.google.code.linkedinapi.client.oauth.LinkedInOAuthServiceImpl.getOAuthRequestToken(LinkedInOAuthServiceImpl.java:159)
at com.lineedapp.common.LinkedinApp.main(LinkedinApp.java:17)
Caused by: oauth.signpost.exception.OAuthCommunicationException: Communication with the service provider failed: api.linkedin.com
at oauth.signpost.AbstractOAuthProvider.retrieveToken(AbstractOAuthProvider.java:214)
at oauth.signpost.AbstractOAuthProvider.retrieveRequestToken(AbstractOAuthProvider.java:69)
at com.google.code.linkedinapi.client.oauth.LinkedInOAuthServiceImpl.getOAuthRequestToken(LinkedInOAuthServiceImpl.java:148)
... 1 more
Caused by: java.net.UnknownHostException: api.linkedin.com
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(Unknown Source)
at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.<init>(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.New(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(Unknown Source)
at oauth.signpost.basic.DefaultOAuthProvider.sendRequest(DefaultOAuthProvider.java:48)
at oauth.signpost.AbstractOAuthProvider.retrieveToken(AbstractOAuthProvider.java:177)
... 3 more我想我不能在申请注册表中提供主机。我确实提供了本地主机,但它不工作。请帮帮忙??
发布于 2011-06-24 17:30:44
Caused by: java.net.UnknownHostException: api.linkedin.com看起来您没有访问api.linkedin.com的网络权限。请确保,无论您是否在代理服务器之后,您都可以访问https://api.linkedin.com。
发布于 2011-06-24 17:29:45
java.net.UnknownHostException: api.linkedin.com表示您无法连接到服务器。
检查您的服务器是否位于代理服务器之后。如果是这样,您必须找到在linkedin API中绕过此代理的方法。
https://stackoverflow.com/questions/6465786
复制相似问题