Is it possible for Nuxeo CMIS client to know how long a document has been currently checked-out?
Most pessimistic locking (check-out/check-in/cancel-check-out) scenarios must plan for the case where a client performs a check-out and then fails to ever either check-in or cancel the check-out. One way to handle this problem is for all clients to be able to track how long a document has been currently checked-out and if it exceeds a certain threshold, cancel the offending check-out and then perform its own check-out.
In CMIS, the PWC has a cmis:creationDate
property which would seem to represent the date the PWC was created which is also the checked-out date. This date could be used to implement the scheme described above. In Nuxeo, however, the Live Document is the PWC and therefore its cmis:creationDate
does not represent the check-out date. Would it be appropriate for Nuxeo to support the scheme described above by maintaining the checkedOutDate for the Live Document and exposing it as a nuxeo:
schema property to CMIS clients?
You make a good point regarding the cmis:creationDate of the PWC. I'm not sure what the spec says about it exactly; even though it probably requires nothing special what you suggest would make more sense.
But we'd have to decide in what schema to store this property and then modify the code accordingly to update it, and map it through the CMIS connector.
The only time the derived isCheckedIn value would be true is when the new column hierarchy.checkedout is NULL and hierarchy.baseversionid is not NULL.
Should I create a JIRA to capture the work needed to follow-up NXP-8515 by correctly populating cmis:versionSeriesIsCheckedOutBy?