上下文
CMISparent
操作允许从对象id获取对象的完整路径。
例如,我给出/alfresco/service/cmis/s/versionStore:version2Store/i/2f4cbf7a-0f8e-4fa1-81e5-8be69eb0532e
,我得到/Sites/swsdp/documentLibrary/Presentations
。
我有一个Alfresco社区4.2.e服务器
不确定是否相关,但除了我启用了ChangeLog:之外,它完全是开箱即用的
audit.enabled=true
audit.alfresco-access.enabled=true
audit.cmischangelog.enabled=true
发生了什么
当我运行下面的"父"CMIS请求时,我会得到下面的响应,其中包含零个Atom条目:
GET /alfresco/service/cmis/s/versionStore:version2Store/i/2f4cbf7a-0f8e-4fa1-81e5-8be69eb0532e/parents?includeAllowableActions=false&includeRelationships=none&includeRelativePathSegment=true HTTP/1.1
User-Agent: Apache Chemistry DotCMIS
Authorization: Basic YWRtaW46YWRtaW4=
Host: 192.168.0.66:8080
Connection: Keep-Alive
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Cache-Control: no-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Pragma: no-cache
Content-Type: application/atom+xml; type=feed;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 Mar 2014 06:57:46 GMT
477
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:app="http://www.w3.org/2007/app" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:alf="http://www.alfresco.org" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/">
<author><name>admin</name></author>
<generator version="4.2.0 (r56674-b4848)">Alfresco (Community)</generator>
<icon>http://192.168.0.66:8080/alfresco/images/logo/AlfrescoLogo16.ico</icon>
<id>urn:uuid:2f4cbf7a-0f8e-4fa1-81e5-8be69eb0532e-parents</id>
<link rel="service" href="http://192.168.0.66:8080/alfresco/service/cmis"/>
<link rel="self" href="http://192.168.0.66:8080/alfresco/service/cmis/s/versionStore:version2Store/i/2f4cbf7a-0f8e-4fa1-81e5-8be69eb0532e/parents?includeAllowableActions=false&includeRelationships=none&includeRelativePathSegment=true"/>
<link rel="via" href="http://192.168.0.66:8080/alfresco/service/cmis/s/versionStore:version2Store/i/2f4cbf7a-0f8e-4fa1-81e5-8be69eb0532e"/>
<title>text1.txt Parents</title>
<updated>2014-03-05T16:32:44.359+09:00</updated>
</feed>
0
我认为应该发生什么
作为参考,CMIS标准有一个parents
的请求/响应示例
示例响应包含一个Atom条目,该条目具有我要查找的路径:
<atom:entry>
[...]
<cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/">
<cmis:properties>
[...]
<cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path">
<cmis:value>/My_Folder-0-0/MultifiledFolder1</cmis:value>
问题
为什么Alfresco没有给我任何Atom条目?
我的请求出了什么问题?我确信id正确地引用了现有的文件/Sites/swsdp/documentLibrary/Presentations/test1.txt
。
您使用的是一个已弃用的CMIS端点和一个过时的CMIS实现。
尝试:
http://<host>/alfresco/api/-default-/public/cmis/versions/1.0/atom