【问题标题】:Not authorized to write to this feed无权写入此提要
【发布时间】:2009-11-18 17:31:13
【问题描述】:

我在打电话

 service.insert(new URL(getContentFeedUrl()), newAttachment);  

在 servlet 中使用 MediaStreamSource 上传 Google 网站文件并获得以下异常

com.google.gdata.util.ServiceForbiddenException:好的 无权写入此提要

at com.google.gdata.client.http.HttpGDataRequest.handleErrorResponse(HttpGDataRequest.java:561)
at com.google.gdata.client.http.GoogleGDataRequest.handleErrorResponse(GoogleGDataRequest.java:543)
at com.google.gdata.client.http.HttpGDataRequest.checkResponse(HttpGDataRequest.java:536)
at com.google.gdata.client.http.HttpGDataRequest.execute(HttpGDataRequest.java:515)
at com.google.gdata.client.http.GoogleGDataRequest.execute(GoogleGDataRequest.java:515)
at com.google.gdata.client.media.MediaService.insert(MediaService.java:390)
at morefile.UploadApp.uploadAttachment(UploadApp.java:95)

【问题讨论】:

  • 它与appengine有什么关系?
  • 它是一个托管在 appengine 上的谷歌数据服务 java 客户端库应用程序
  • 我认为您正在混合使用 Google 代码和 App Engine。 Google 库托管在 Google Code 网站上,而 App Engine 是其他人运行自己的应用程序的地方

标签: java google-app-engine permissions


【解决方案1】:

你之前用好的用户名和密码调用service.getAuthToken吗?

【讨论】:

  • 为什么在使用 authsub/oauth 时需要用户名和密码?
  • 我不知道你在用什么,因为你没有在你的问题中这么说。但是我看到您遇到了身份验证错误,并且 GoogleService 类中有一些与身份验证相关的方法。
【解决方案2】:

我刚刚意识到我正在授予不是谷歌网站所有者的用户访问权限,因此出现了这个错误。我将留下此评论,因为网络上几乎没有关于此错误的帮助。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2020-12-05
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-06-22
    • 2015-11-05
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多