cancel
Showing results for 
Search instead for 
Did you mean: 

CmisConnectionException 'canCreatePolicy.Folder' not a valid value for enumAllowableActionsKey

martin_
Champ in-the-making
Champ in-the-making

Hello,

trying to get Nuxeo repositories via cmis I receive this exception:

DotCMIS.Exceptions.CmisConnectionException wurde nicht behandelt.
  Message=Parsing exception!
  Source=DotCMIS
  StackTrace:
       bei DotCMIS.Binding.AtomPub.AbstractAtomPubService.Parse[T](Stream stream) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub.cs:Zeile 416.
       bei DotCMIS.Binding.AtomPub.AbstractAtomPubService.GetRepositoriesInternal(String repositoryId) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub.cs:Zeile 726.
       bei DotCMIS.Binding.AtomPub.RepositoryService.GetRepositoryInfos(IExtensionsData extension) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub.cs:Zeile 885.
       bei DotCMIS.Binding.Impl.BindingRepositoryService.GetRepositoryInfos(IExtensionsData extension) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\binding-impl.cs:Zeile 452.
       bei DotCMIS.Client.Impl.SessionFactory.GetRepositories(IDictionary`2 parameters, IObjectFactory objectFactory, AbstractAuthenticationProvider authenticationProvider, ICache cache) in c:\Temp\chemistry-dotcmis-0.6-src\src\client\client-impl.cs:Zeile 68.
       bei DotCMIS.Client.Impl.SessionFactory.GetRepositories(IDictionary`2 parameters) in c:\Temp\chemistry-dotcmis-0.6-src\src\client\client-impl.cs:Zeile 61.
       bei CmisClient.Module1.cleanDemo() in S:\vb\OpenKMClient\Module1.vb:Zeile 51.
       bei CmisClient.Module1.Main() in S:\vb\OpenKMClient\Module1.vb:Zeile 59.
       bei System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
       bei System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       bei Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       bei System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       bei System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       bei System.Threading.ThreadHelper.ThreadStart()
  InnerException: System.InvalidOperationException
       Message=Fehler im XML-Dokument (1,5549).
       Source=System.Xml
       StackTrace:
            bei System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events)
            bei System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader)
            bei DotCMIS.Binding.AtomPub.AtomPubParser.DeserializeRepositoryInfo(XmlReader reader) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub-parser.cs:Zeile 583.
            bei DotCMIS.Binding.AtomPub.AtomPubParser.ParseWorkspaceElement(XmlReader reader) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub-parser.cs:Zeile 214.
            bei DotCMIS.Binding.AtomPub.AtomPubParser.ParseWorkspace(XmlReader reader) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub-parser.cs:Zeile 184.
            bei DotCMIS.Binding.AtomPub.AtomPubParser.ParseServiceDoc(XmlReader reader) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub-parser.cs:Zeile 150.
            bei DotCMIS.Binding.AtomPub.AtomPubParser.Parse() in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub-parser.cs:Zeile 120.
            bei DotCMIS.Binding.AtomPub.AbstractAtomPubService.Parse[T](Stream stream) in c:\Temp\chemistry-dotcmis-0.6-src\src\binding\atompub\atompub.cs:Zeile 412.
       InnerException: System.InvalidOperationException
            Message=Instanzvalisierungsfehler: 'canCreatePolicy.Folder' ist kein gültiger Wert für enumAllowableActionsKey.
            Source=ycga9uy_
            StackTrace:
                 bei Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReadercmisRepositoryInfoType.Read12_enumAllowableActionsKey(String s)
                 bei Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReadercmisRepositoryInfoType.Read13_cmisPermissionMapping(Boolean isNullable, Boolean checkType)
                 bei Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReadercmisRepositoryInfoType.Read14_cmisACLCapabilityType(Boolean isNullable, Boolean checkType)
                 bei Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReadercmisRepositoryInfoType.Read16_cmisRepositoryInfoType(Boolean isNullable, Boolean checkType)
                 bei Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReadercmisRepositoryInfoType.Read17_repositoryInfo()
            InnerException: 

I'm using apache dotcmis framework Release 0.6 from here.

This is my code (quite the same as here) It works fine with OpenKM endpoint:

Dim parameters As New Dictionary(Of String, String)

parameters(SessionParameter.BindingType) = BindingType.AtomPub
parameters(SessionParameter.AtomPubUrl) = "http://nuxeohost:8080/nuxeo/atom/cmis"
parameters(SessionParameter.User) = "Administrator"
parameters(SessionParameter.Password) = "Administrator"

Dim factory As SessionFactory = SessionFactory.NewInstance()
Dim repositories As IList(Of IRepository) = factory.GetRepositories(parameters)

This is the Nuxeo response (decoded):

HTTP/1.1 200 OK
X-UA-Compatible: IE=10; IE=11
Cache-Control: private, max-age=0
Server: Apache-Chemistry-OpenCMIS/0.12.0-NX1
Content-Type: application/atomsvc+xml
Date: Fri, 09 Jan 2015 12:25:52 GMT
Content-Length: 11050

<?xml version='1.0' encoding='UTF-8'?><app:service xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"><app:workspace><atom:title>default</atom:title><app:collection href="http://wuevm703:8080/nuxeo/atom/cmis/default/children?id=410049a2-ecb4-420d-80bf-0892ff01f0fa"><cmisra:collectionType>root</cmisra:collectionType><atom:title type="text">Root Collection</atom:title><app:accept>application/atom+xml;type=entry</app:accept><app:accept>application/cmisatom+xml</app:accept></app:collection><app:collection href="http://wuevm703:8080/nuxeo/atom/cmis/default/types"><cmisra:collectionType>types</cmisra:collectionType><atom:title type="text">Types Collection</atom:title><app:accept></app:accept></app:collection><app:collection href="http://wuevm703:8080/nuxeo/atom/cmis/default/query"><cmisra:collectionType>query</cmisra:collectionType><atom:title type="text">Query Collection</atom:title><app:accept>application/cmisquery+xml</app:accept></app:collection><app:collection href="http://wuevm703:8080/nuxeo/atom/cmis/default/checkedout"><cmisra:collectionType>checkedout</cmisra:collectionType><atom:title type="text">Checked Out Collection</atom:title><app:accept>application/cmisatom+xml</app:accept></app:collection><app:collection href="http://wuevm703:8080/nuxeo/atom/cmis/default/update"><cmisra:collectionType>update</cmisra:collectionType><atom:title type="text">Bulk Update Collection</atom:title><app:accept>application/cmisatom+xml</app:accept></app:collection><cmisra:repositoryInfo><cmis:repositoryId>default</cmis:repositoryId><cmis:repositoryName>Nuxeo Repository default</cmis:repositoryName><cmis:repositoryDescription>Nuxeo Repository default</cmis:repositoryDescription><cmis:vendorName>Nuxeo</cmis:vendorName><cmis:productName>Nuxeo OpenCMIS Connector</cmis:productName><cmis:productVersion>6.0</cmis:productVersion><cmis:rootFolderId>410049a2-ecb4-420d-80bf-0892ff01f0fa</cmis:rootFolderId><cmis:latestChangeLogToken>1420710677239</cmis:latestChangeLogToken><cmis:capabilities><cmis:capabilityACL>manage</cmis:capabilityACL><cmis:capabilityAllVersionsSearchable>true</cmis:capabilityAllVersionsSearchable><cmis:capabilityChanges>objectidsonly</cmis:capabilityChanges><cmis:capabilityContentStreamUpdatability>pwconly</cmis:capabilityContentStreamUpdatability><cmis:capabilityGetDescendants>true</cmis:capabilityGetDescendants><cmis:capabilityGetFolderTree>true</cmis:capabilityGetFolderTree><cmis:capabilityMultifiling>false</cmis:capabilityMultifiling><cmis:capabilityPWCSearchable>true</cmis:capabilityPWCSearchable><cmis:capabilityPWCUpdatable>true</cmis:capabilityPWCUpdatable><cmis:capabilityQuery>bothcombined</cmis:capabilityQuery><cmis:capabilityRenditions>read</cmis:capabilityRenditions><cmis:capabilityUnfiling>false</cmis:capabilityUnfiling><cmis:capabilityVersionSpecificFiling>false</cmis:capabilityVersionSpecificFiling><cmis:capabilityJoin>none</cmis:capabilityJoin><cmis:capabilityCreatablePropertyTypes/><cmis:capabilityNewTypeSettableAttributes/></cmis:capabilities><cmis:aclCapability><cmis:supportedPermissions>repository</cmis:supportedPermissions><cmis:propagation>propagate</cmis:propagation><cmis:permissions><cmis:permission>cmis:read</cmis:permission><cmis:description>Read</cmis:description></cmis:permissions><cmis:permissions><cmis:permission>cmis:write</cmis:permission><cmis:description>Write</cmis:description></cmis:permissions><cmis:permissions><cmis:permission>cmis:all</cmis:permission><cmis:description>All</cmis:description></cmis:permissions><cmis:permissions><cmis:permission>ReadRemove</cmis:permission><cmis:description>Remove</cmis:description></cmis:permissions><cmis:permissions><cmis:permission>CanAskForPublishing</cmis:permission><cmis:description>CanAskForPublishing</cmis:description></cmis:permissions><cmis:permissions><cmis:permission>ReadCanCollect</cmis:permission><cmis:description>ReadCanCollect</cmis:description></cmis:permissions><cmis:mapping><cmis:key>canCreateRelationship.Source</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canViewContent.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetAllVersions.VersionSeries</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canDelete.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canRemoveFromFolder.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canAddPolicy.Policy</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canRemoveFromFolder.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCreateFolder.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetObjectRelationships.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCreateRelationship.Target</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canRemovePolicy.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetACL.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCreatePolicy.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCreateDocument.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canMove.Target</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetProperties.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canApplyACL.Object</cmis:key><cmis:permission>cmis:all</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canAddToFolder.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canUpdateProperties.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canRemovePolicy.Policy</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetDescendents.Folder</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canAddToFolder.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCheckin.Document</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetChildren.Folder</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canMove.Source</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canSetContent.Document</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canAddPolicy.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetParents.Folder</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetAppliedPolicies.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canGetFolderParent.Object</cmis:key><cmis:permission>cmis:read</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canDeleteTree.Folder</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCheckout.Document</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canCancelCheckout.Document</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canMove.Object</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping><cmis:mapping><cmis:key>canDeleteContent.Document</cmis:key><cmis:permission>cmis:write</cmis:permission></cmis:mapping></cmis:aclCapability><cmis:cmisVersionSupported>1.1</cmis:cmisVersionSupported><cmis:thinClientURI>http://wuevm703:8080/nuxeo/</cmis:thinClientURI><cmis:changesIncomplete>false</cmis:changesIncomplete><cmis:changesOnType>cmis:document</cmis:changesOnType><cmis:changesOnType>cmis:folder</cmis:changesOnType><cmis:principalAnonymous>Guest</cmis:principalAnonymous><cmis:principalAnyone>Everyone</cmis:principalAnyone></cmisra:repositoryInfo><atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/typedescendants" href="http://wuevm703:8080/nuxeo/atom/cmis/default/typedesc" type="application/atom+xml;type=feed"/><atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://wuevm703:8080/nuxeo/atom/cmis/default/foldertree?id=410049a2-ecb4-420d-80bf-0892ff01f0fa" type="application/cmistree+xml"/><atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/rootdescendants" href="http://wuevm703:8080/nuxeo/atom/cmis/default/descendants?id=410049a2-ecb4-420d-80bf-0892ff01f0fa" type="application/cmistree+xml" cmisra:id="410049a2-ecb4-420d-80bf-0892ff01f0fa"/><atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/changes" href="http://wuevm703:8080/nuxeo/atom/cmis/default/changes" type="application/atom+xml;type=feed"/><cmisra:uritemplate><cmisra:template>http://wuevm703:8080/nuxeo/atom/cmis/default/id?id={id}&amp;filter={filter}&amp;includeAllowableActions={includeAllowableActions}&amp;includeACL={includeACL}&amp;includePolicyIds={includePolicyIds}&amp;includeRelationships={includeRelationships}&amp;renditionFilter={renditionFilter}</cmisra:template><cmisra:type>objectbyid</cmisra:type><cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype></cmisra:uritemplate><cmisra:uritemplate><cmisra:template>http://wuevm703:8080/nuxeo/atom/cmis/default/path?path={path}&amp;filter={filter}&amp;includeAllowableActions={includeAllowableActions}&amp;includeACL={includeACL}&amp;includePolicyIds={includePolicyIds}&amp;includeRelationships={includeRelationships}&amp;renditionFilter={renditionFilter}</cmisra:template><cmisra:type>objectbypath</cmisra:type><cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype></cmisra:uritemplate><cmisra:uritemplate><cmisra:template>http://wuevm703:8080/nuxeo/atom/cmis/default/type?id={id}</cmisra:template><cmisra:type>typebyid</cmisra:type><cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype></cmisra:uritemplate><cmisra:uritemplate><cmisra:template>http://wuevm703:8080/nuxeo/atom/cmis/default/query?q={q}&amp;searchAllVersions={searchAllVersions}&amp;includeAllowableActions={includeAllowableActions}&amp;includeRelationships={includeRelationships}&amp;maxItems={maxItems}&amp;skipCount={skipCount}</cmisra:template><cmisra:type>query</cmisra:type><cmisra:mediatype>application/atom+xml;type=feed</cmisra:mediatype></cmisra:uritemplate></app:workspace></app:service>

What is wrong?

3 REPLIES 3

Florent_Guillau
World-Class Innovator
World-Class Innovator

If you google "nuxeo canCreatePolicy.Folder" you'll find as the first hit a ticket (NXP-16245) that explains that this is fixed in Nuxeo 6.0 HF03.

Hello Florent,

Hm the fix I mentioned is for WebServices. For AtomPub bindings, which you are using, then we still send this parameter which is mentioned in the spec. However if you DotCMIS client bases its parsing on a fixed schema then you'll still have the error. Basically the client is too strict, I didn't know such clients existed for non-WebServices bindings. But I opened [NXP-16342](https

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.