【问题标题】:java.net.SocketException: sendto failed: EPIPE (Broken pipe)java.net.SocketException:发送失败:EPIPE(断管)
【发布时间】:2013-01-26 05:04:15
【问题描述】:

我正在尝试通过 Android 的 OpenCMIS 查询 Alfresco 存储库。 但是低于错误但不是每次。 这是我的代码。当我作为独立程序运行但无法在 Android 上正常运行时,此代码运行良好。

getCMISClientSession();
ItemIterable<QueryResult> results = session.query("SELECT * FROM cmis:document 
                   where cmis:name ='"+docName+"'", false);

for (QueryResult result : results) { //Exception thrown from here

    String docId = result.getPropertyValueById(PropertyIds.OBJECT_ID);
    doc = (Document)session.getObject(docId);

}

堆栈跟踪

org.apache.chemistry.opencmis.commons.exceptions.CmisConnectionException: Cannot access http://<192.168.1.122>:8080/alfresco/cmisatom/eee7da3c-d3d4-48de-89a1-52145a6a6e06/query: sendto failed: EPIPE (Broken pipe)
at org.apache.chemistry.opencmis.client.bindings.spi.http.HttpUtils.invoke(HttpUtils.java:224)
at org.apache.chemistry.opencmis.client.bindings.spi.http.HttpUtils.invokePOST(HttpUtils.java:74)
at org.apache.chemistry.opencmis.client.bindings.spi.atompub.AbstractAtomPubService.post(AbstractAtomPubService.java:561)
at org.apache.chemistry.opencmis.client.bindings.spi.atompub.DiscoveryServiceImpl.query(DiscoveryServiceImpl.java:137)
at org.apache.chemistry.opencmis.client.runtime.SessionImpl$3.fetchPage(SessionImpl.java:567)
at org.apache.chemistry.opencmis.client.runtime.util.AbstractIterator.getCurrentPage(AbstractIterator.java:132) 
at org.apache.chemistry.opencmis.client.runtime.util.CollectionIterator.hasNext(CollectionIterator.java:48)

这是因为 Android Emulator 很慢吗?请告知如何解决此错误。

【问题讨论】:

  • 您使用什么版本的 OpenCMIS(库)?安卓客户端?
  • @JM.Pascal,是的,Android 客户端

标签: android alfresco httpurlconnection cmis opencmis


【解决方案1】:

您能否尝试使用此版本0.8.0-alfresco-patched 或最终使用来自Apache chemistry CI 的最新版本

【讨论】:

    【解决方案2】:

    模拟器不适用于需要互联网连接的应用。用真机试试。

    【讨论】:

      猜你喜欢
      • 2014-02-09
      • 1970-01-01
      • 2013-03-30
      • 2013-01-15
      • 1970-01-01
      • 2014-06-14
      • 1970-01-01
      相关资源
      最近更新 更多