1

CMIS Workbench / DotCMIS Problem with SharePoint 2013

  1. Cannot GetChildren() of certain sub-folders i.e. /.../001
  2. Cannot perform cmis:query Select * From cmis:folder

1. Cannot GetChildren() of some sub-folders

DotCMIS.Client.Impl.Folder.GetChildren() exception

via Web Service endpoint (folder /.../001)

DotCMIS.Exceptions.CmisConstraintException: Cannot complete this action. Please try again.
at DotCMIS.Binding.WebServices.NavigationService.GetChildren(String repositoryId, String folderId, String filter, String orderBy, Nullable`1 includeAllowableActions, Nullable`1 includeRelationships, String renditionFilter, Nullable`1 includePathSegment, Nullable`1 maxItems, Nullable`1 skipCount, IExtensionsData extension) in D:\Projects\CMIS\DotCMIS\binding\webservices\webservices.cs:line 653
at DotCMIS.Client.Impl.Folder.<>c__DisplayClass4.<GetChildren>b__3(Int64 maxNumItems, Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-objects.cs:line 1124
at DotCMIS.Client.Impl.PageFetcher`1.FetchNextPage(Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 563
at DotCMIS.Client.Impl.AbstractEnumerator`1.GetCurrentPage() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 528
at DotCMIS.Client.Impl.CollectionEnumerator`1.MoveNext() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 608
at ConsoleTest.Module1.Demo(ENDPOINT_TYPE endpoint_type) in D:\Projects\CMIS\ConsoleTest\Module1.vb:line 396

via AtomPub endpoint (folder /.../001)

DotCMIS.Exceptions.CmisConnectionException: Parsing exception! ---> System.Xml.XmlException: An error has occurred while opening external DTD 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd': The remote server returned an error: (500) Internal Server Error. ---> System.Net.WebException: The remote server returned an error: (500) Internal Server Error.
   at System.Net.HttpWebRequest.GetResponse()
   at System.Xml.XmlDownloadManager.GetNonFileStream(Uri uri, ICredentials credentials, IWebProxy proxy, RequestCachePolicy cachePolicy)
   at System.Xml.XmlDownloadManager.GetStream(Uri uri, ICredentials credentials, IWebProxy proxy, RequestCachePolicy cachePolicy)
   at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)
   at System.Xml.XmlTextReaderImpl.OpenAndPush(Uri uri)
   at System.Xml.XmlTextReaderImpl.PushExternalEntityOrSubset(String publicId, String systemId, Uri baseUri, String entityName)
   --- End of inner exception stack trace ---
   at System.Xml.XmlTextReaderImpl.Throw(Exception e)
   at System.Xml.XmlTextReaderImpl.PushExternalEntityOrSubset(String publicId, String systemId, Uri baseUri, String entityName)
   at System.Xml.XmlTextReaderImpl.DtdParserProxy_PushExternalSubset(String systemId, String publicId)
   at System.Xml.XmlTextReaderImpl.DtdParserProxy.System.Xml.IDtdParserAdapter.PushExternalSubset(String systemId, String publicId)
   at System.Xml.DtdParser.ParseExternalSubset()
   at System.Xml.DtdParser.ParseInDocumentDtd(Boolean saveInternalSubset)
   at System.Xml.DtdParser.Parse(Boolean saveInternalSubset)
   at System.Xml.DtdParser.System.Xml.IDtdParser.ParseInternalDtd(IDtdParserAdapter adapter, Boolean saveInternalSubset)
   at System.Xml.XmlTextReaderImpl.ParseDtd()
   at System.Xml.XmlTextReaderImpl.ParseDoctypeDecl()
   at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
   at System.Xml.XmlTextReaderImpl.Read()
   at System.Xml.XmlReader.MoveToContent()
   at System.Xml.XmlReader.IsStartElement()
   at DotCMIS.Binding.AtomPub.AtomPubParser.Parse() in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub-parser.cs:line 90
   at DotCMIS.Binding.AtomPub.AbstractAtomPubService.Parse[T](Stream stream) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 418
   --- End of inner exception stack trace ---
   at DotCMIS.Binding.AtomPub.AbstractAtomPubService.Parse[T](Stream stream) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 422
   at DotCMIS.Binding.AtomPub.NavigationService.GetChildren(String repositoryId, String folderId, String filter, String orderBy, Nullable`1 includeAllowableActions, Nullable`1 includeRelationships, String renditionFilter, Nullable`1 includePathSegment, Nullable`1 maxItems, Nullable`1 skipCount, IExtensionsData extension) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 1134
   at DotCMIS.Client.Impl.Folder.<>c__DisplayClass4.<GetChildren>b__3(Int64 maxNumItems, Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-objects.cs:line 1124
   at DotCMIS.Client.Impl.PageFetcher`1.FetchNextPage(Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 563
   at DotCMIS.Client.Impl.AbstractEnumerator`1.GetCurrentPage() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 528
   at DotCMIS.Client.Impl.CollectionEnumerator`1.MoveNext() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 608
   at ConsoleTest.Module1.Demo(ENDPOINT_TYPE endpoint_type) in D:\Projects\CMIS\ConsoleTest\Module1.vb:line 399

via AtomPub endpoint (folder /.../002) note: via WS no exception. ?

DotCMIS.Exceptions.CmisRuntimeException: Unauthorized
    at DotCMIS.Binding.AtomPub.AbstractAtomPubService.Read(UrlBuilder url) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 442
    at DotCMIS.Binding.AtomPub.NavigationService.GetChildren(String repositoryId, String folderId, String filter, String orderBy, Nullable`1 includeAllowableActions, Nullable`1 includeRelationships, String renditionFilter, Nullable`1 includePathSegment, Nullable`1 maxItems, Nullable`1 skipCount, IExtensionsData extension) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 1133
    at DotCMIS.Client.Impl.Folder.<>c__DisplayClass4.<GetChildren>b__3(Int64 maxNumItems, Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-objects.cs:line 1124
    at DotCMIS.Client.Impl.PageFetcher`1.FetchNextPage(Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 563
    at DotCMIS.Client.Impl.AbstractEnumerator`1.GetCurrentPage() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 528
    at DotCMIS.Client.Impl.CollectionEnumerator`1.MoveNext() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 608
    at ConsoleTest.Module1.Demo(ENDPOINT_TYPE endpoint_type) in D:\Projects\CMIS\ConsoleTest\Module1.vb:line 399

CMIS Workbench navigate to sub-folder (via AtomPub endpoint)

Error connection: Unexpected document! Received: HTML document

enter image description here

CMIS Workbench navigate to sub-folder (via WebService endpoint)

Error runtime: Cannot complete this action. Please try again.

enter image description here

2. Cannot perform cmis:query Select * From cmis:folder

CMIS Workbench Query (via AtomPub endpoint)

enter image description here

Submitting the query again gives a different error msg

enter image description here

DotCMIS cmis:query (via AtomPub endpoint)

DotCMIS.Exceptions.CmisRuntimeException: Unauthorized
   at DotCMIS.Binding.AtomPub.AbstractAtomPubService.Post(UrlBuilder url, String contentType, Output writer) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 454
   at DotCMIS.Binding.AtomPub.DiscoveryService.Query(String repositoryId, String statement, Nullable`1 searchAllVersions, Nullable`1 includeAllowableActions, Nullable`1 includeRelationships, String renditionFilter, Nullable`1 maxItems, Nullable`1 skipCount, IExtensionsData extension) in D:\Projects\CMIS\DotCMIS\binding\atompub\atompub.cs:line 2629
   at DotCMIS.Client.Impl.Session.<>c__DisplayClass7.<Query>b__6(Int64 maxNumItems, Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-impl.cs:line 722
   at DotCMIS.Client.Impl.PageFetcher`1.FetchNextPage(Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 563
   at DotCMIS.Client.Impl.AbstractEnumerator`1.GetCurrentPage() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 528
   at DotCMIS.Client.Impl.CollectionEnumerator`1.MoveNext() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 608
   at ConsoleTest.Module1.Demo(ENDPOINT_TYPE endpoint_type) in D:\Projects\CMIS\ConsoleTest\Module1.vb:line 545

CMIS Workbench Query (via WebService endpoint)

enter image description here

DotCMIS cmis:query (via WebService endpoint)

DotCMIS.Exceptions.CmisConstraintException: Cannot complete this action.

Please try again.
   at DotCMIS.Binding.WebServices.DiscoveryService.Query(String repositoryId, String statement, Nullable`1 searchAllVersions, Nullable`1 includeAllowableActions, Nullable`1 includeRelationships, String renditionFilter, Nullable`1 maxItems, Nullable`1 skipCount, IExtensionsData extension) in D:\Projects\CMIS\DotCMIS\binding\webservices\webservices.cs:line 1425
   at DotCMIS.Client.Impl.Session.<>c__DisplayClass7.<Query>b__6(Int64 maxNumItems, Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-impl.cs:line 722
   at DotCMIS.Client.Impl.PageFetcher`1.FetchNextPage(Int64 skipCount) in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 563
   at DotCMIS.Client.Impl.AbstractEnumerator`1.GetCurrentPage() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 528
   at DotCMIS.Client.Impl.CollectionEnumerator`1.MoveNext() in D:\Projects\CMIS\DotCMIS\client\client-utils.cs:line 608
   at ConsoleTest.Module1.Demo(ENDPOINT_TYPE endpoint_type) in D:\Projects\CMIS\ConsoleTest\Module1.vb:line 545

(Only via WS endpoint) Query works when I limit to 24 max hits:

enter image description here

After some trial and error, found that some items were causing an error.

This query is OK:

SELECT * FROM cmis:folder WHERE ID < 39 OR ID > 42

However, these will cause the error Error runtime: Cannot complete this action. Please try again.:

SELECT * FROM cmis:folder Where id = 39 (/.../001/001-01) 
SELECT * FROM cmis:folder Where id = 40 (/.../001/001-02) 
SELECT * FROM cmis:folder Where id = 42 (/.../001/001-02/001-02-01)

How do I troubleshoot this issue?

I have no problem viewing the folder and its sub-folders using the same user account in SharePoint:

enter image description here

I have also patched SharePoint with latest cumulative update (Feb, Mar 2016), that fixed an issue with the change log via AtomPub endpoint thanks to Florian Müller.

Community
  • 1
  • 1
SimplyInk
  • 5,832
  • 1
  • 18
  • 27

0 Answers0