【问题标题】:Getting java.lang.RuntimeException: Unable to complete the HTTP request while uploading document获取 java.lang.RuntimeException:上传文档时无法完成 HTTP 请求
【发布时间】:2011-07-17 04:23:51
【问题描述】:

我在尝试使用 com.google.gdata.client.docs.DocsService 上传文档时遇到超时错误

这是我正在使用的代码:

DocumentListEntry documentEntry = new DocumentEntry();

documentEntry.setTitle(new PlainTextConstruct("new document"));

documentEntry.setMediaSource(new MediaByteArraySource(out.toByteArray(), mimeType));

DocumentListEntry uploadedEntry = service.insert(new URL("https://docs.google.com/feeds/default/private/full/"), documentEntry);   <-- timeout at this point.

获取时超时:https://docs.google.com/feeds/default/private/full/

我正在使用 Eclipse 中的应用引擎 sdk 以调试模式运行应用程序。

【问题讨论】:

    标签: java google-app-engine gdata-api


    【解决方案1】:

    我认为这是一个非常古老的线程,但只是在回答另一个问题时看到它。我希望你现在已经解决了。

    如果没有,那么您的服务是否经过身份验证,您是否能够创建一个简单的文档,例如

                 String title = "Doc Create Test";
                 DocumentListEntry newEntry = new DocumentEntry();
                 newEntry.setTitle(new PlainTextConstruct(title));
                 newEntry = service.insert(feedUrl, newEntry);
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2016-09-04
      • 2020-05-27
      • 1970-01-01
      • 2014-11-15
      • 2017-11-23
      • 1970-01-01
      相关资源
      最近更新 更多