Return-Path: X-Original-To: apmail-chemistry-dev-archive@www.apache.org Delivered-To: apmail-chemistry-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 96C82679 for ; Thu, 5 May 2011 01:23:40 +0000 (UTC) Received: (qmail 15869 invoked by uid 500); 5 May 2011 01:23:38 -0000 Delivered-To: apmail-chemistry-dev-archive@chemistry.apache.org Received: (qmail 15832 invoked by uid 500); 5 May 2011 01:23:38 -0000 Mailing-List: contact dev-help@chemistry.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@chemistry.apache.org Delivered-To: mailing list dev@chemistry.apache.org Received: (qmail 15797 invoked by uid 99); 5 May 2011 01:23:38 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 05 May 2011 01:23:38 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of florian.mueller@alfresco.com designates 207.126.144.131 as permitted sender) Received: from [207.126.144.131] (HELO eu1sys200aog111.obsmtp.com) (207.126.144.131) by apache.org (qpsmtpd/0.29) with SMTP; Thu, 05 May 2011 01:23:28 +0000 Received: from zimbra.alfresco.com ([88.151.129.3]) by eu1sys200aob111.postini.com ([207.126.147.11]) with SMTP ID DSNKTcH7+2xYG3NqiLGTj+0+QBfDTEgcpJXF@postini.com; Thu, 05 May 2011 01:23:08 UTC Received: from localhost (localhost.localdomain [127.0.0.1]) by zimbra.alfresco.com (Postfix) with ESMTP id B107C50C02C; Thu, 5 May 2011 02:23:06 +0100 (BST) X-Virus-Scanned: amavisd-new at unx-d-manc4.tc.ifeltd.com Received: from zimbra.alfresco.com ([127.0.0.1]) by localhost (zimbra.alfresco.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5a1iOjcRoThG; Thu, 5 May 2011 02:23:06 +0100 (BST) Received: from Florian-Mullers-MacBook-Pro-2.local (static-72-85-230-51.bstnma.east.verizon.net [72.85.230.51]) (Authenticated sender: florian.mueller) by zimbra.alfresco.com (Postfix) with ESMTP id 91AB450C02A; Thu, 5 May 2011 02:23:05 +0100 (BST) Message-ID: <4DC1FBF7.9010007@alfresco.com> Date: Wed, 04 May 2011 21:23:03 -0400 From: =?ISO-8859-1?Q?Florian_M=FCller?= User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.17) Gecko/20110414 Thunderbird/3.1.10 MIME-Version: 1.0 To: dev@chemistry.apache.org, "johnnyhowey@gmail.com >> Jonathan Lee" Subject: Re: getObjectOfLatestVersion() returns getObjectOfLatestVersion with SharePoint 2010 References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hi Jonathan, This is one of the few exceptions where the two CMIS bindings differ. The Web Services binding accepts the version series id and the AtomPub binding requires an object id. OpenCMIS is spec compliant in this case and SharePoint seems not to be compliant. There is not much we can do on the OpenCMIS side - except for introducing a "SharePoint mode", which is probably not a good idea. The only (expensive) workaround is to get the version history. The first entry in the list is the latest version. Florian On 04/05/2011 20:39, Jonathan Lee wrote: > Hi All, > > Here is another issue related mounting a sharepoint 2010 repository. > Hopefully I can explain the problem clearly! > > When I call document.getObjectOfLatestVersion(false), sharepoint returns the > following exception > > *Microsoft.SharePoint.CMIS.Data.Exception.InvalidArgumentException: Item id > is invalid 458-1* > > 458-1 is the objectId of the document, however it will only work if you pass > in the versionSeriesId which is 458. > > Basically, > > This request won't work.. > > http://[server]/_vti_bin/cmis/rest/[repositoryId]?getObject&objectId=*458-1* > &filter=&includeAllowableActions=true&includeACL=false&returnVersion=latest > > This will > > http://[server]/_vti_bin/cmis/rest/[repositoryId]?getObject&objectId=*458* > &filter=&includeAllowableActions=true&includeACL=false&returnVersion=latest > > However with SharePoint 2010 I cannot get an document object with only it's > versionSeriesId( ex. 458), I have to get the document with the objectId ( > ex. 458-1). *session.getObject(458-1)* > > So my question is. Is getObjectOfLatestVersion() using the versionSeriesId > of an object to send the request? To me it seems like its only using the > objectId to generate the request. > > Is this something OpenCMIS can fix? > > Thanks!! > > Jonathan Lee >