[ 
https://issues.apache.org/jira/browse/CMIS-732?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Florian Müller resolved CMIS-732.
---------------------------------

    Resolution: Not A Problem

The object id not separately transported on the wire. It's a property. 
ObjectData#getId() is only a shortcut to get the value of the property 
cmis:objectId. 
Change event objects must always be accompanied by properties. In the simplest 
case the properties only consist of the object id.

> ObjectData.getId() should be used to retrieve the object's id, not the 
> properties set.
> --------------------------------------------------------------------------------------
>
>                 Key: CMIS-732
>                 URL: https://issues.apache.org/jira/browse/CMIS-732
>             Project: Chemistry
>          Issue Type: Bug
>          Components: opencmis-client
>    Affects Versions: OpenCMIS 0.10.0
>            Reporter: Jaime Porras López
>
> In the following client's method the object's id is resolved using the 
> ObjectData's properties:
>       
> org.apache.chemistry.opencmis.client.runtime.repository.ObjectFactoryImpl#convertChangeEvent(ObjectData)
> The use of the properties set in the context of the change events has the 
> following problems:
> - Return the updated properties in the events is not mandatory according to 
> the specification (see below). However, currently it is mandatory to return 
> at least the object's id.
> - Even if the properties are returned, I guess they are supposed to be only 
> the updated ones. In this case, to return the object's id is not coherent 
> since it is immutable.
> {quote}
>       ...
>       <Properties> properties Additionally, for events of changeType 
> "updated", the repository MAY optionally include the new values of properties 
> on the object (if any).
>       Repositories MUST indicate whether they include properties for 
> "updated" change events via the optional capabilityChanges.
>       ...
> {quote}
> So, in order to obtain the object's id from the Object data this method 
> should be used instead: 
>       org.apache.chemistry.opencmis.commons.data.ObjectData#getId()



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to