org.mule.modules

mule-module-cmis

config

Namespacehttp://www.mulesoft.org/schema/mule/cmis
Schema Locationhttp://www.mulesoft.org/schema/mule/cmis/current/mule-cmis.xsd  (View Schema)
Schema Version1.1
Minimum Mule Version3.2

Module Overview

CMIS (Content Management Interoperability Services) is a standard for improving interoperability between ECM systems.

Summary

Configuration
<cmis:config>
Configure an instance of this module
Message Processors
<cmis:apply-acl>
Set the permissions associated with an object.
<cmis:apply-aspect>
Apply and aspect to an object and set some properties of that aspect.
<cmis:apply-policy>
Applies policies to this object.
<cmis:cancel-check-out>
If applied to a PWC (private working copy) of the document, the check out will be reversed.
<cmis:changelog>
Gets repository changes.
<cmis:check-in>
If applied to a PWC (private working copy) it performs a check in.
<cmis:check-out>
Checks out the document and returns the object id of the PWC (private working copy).
<cmis:create-document-by-id>
Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by an object ID.
<cmis:create-document-by-id-from-content>
Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by an object ID.
<cmis:create-document-by-path>
Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by a repository path.
<cmis:create-document-by-path-from-content>
Creates a new document in the repository where the content is specified as the value of the "content" parameter and the target folder node is specified by a repository path.
<cmis:create-folder>
Creates a folder.
<cmis:create-relationship>
Creates a parent/child relationships between two nodes in the repository of the specified relationship object type.
<cmis:delete>
Remove an object

<cmis:delete-tree>
Deletes a folder and all subfolders.
<cmis:folder>
Navigates the folder structure.
<cmis:get-acl>
Returns the ACL if it has been fetched for an object.
<cmis:get-all-versions>
Retrieve an object's version history

<cmis:get-applied-policies>
Get the policies that are applied to an object.
<cmis:get-checkout-docs>
Retrieve list of checked out documents.
<cmis:get-content-stream>
Retrieves the content stream of a Document.
<cmis:get-object-by-id>
Returns a CMIS object from the repository and puts it into the cache.
<cmis:get-object-by-path>
Returns a CMIS object from the repository and puts it into the cache.
<cmis:get-object-relationships>
Returns the relationships if they have been fetched for an object.
<cmis:get-or-create-folder-by-path>
Creates a new folder in the repository if it doesn't already exist.
<cmis:get-parent-folders>
Retrieves the parent folders of a fileable cmis object

<cmis:get-type-definition>
Returns the type definition of the given type id.
<cmis:move-object>
Moves a fileable cmis object from one location to another.
<cmis:query>
Sends a query to the repository

<cmis:repositories>
Returns all repositories that are available at the endpoint.
<cmis:repository-info>
Returns information about the CMIS repository, the optional capabilities it supports and its Access Control information if applicable.
<cmis:update-object-properties>
Update an object's properties

Configuration

To use the this module within a flow the namespace to the module must be included. The resulting flow will look similar to the following:

<mule xmlns="http://www.mulesoft.org/schema/mule/core"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns:cmis="http://www.mulesoft.org/schema/mule/cmis"
      xsi:schemaLocation="
               http://www.mulesoft.org/schema/mule/core
               http://www.mulesoft.org/schema/mule/core/current/mule.xsd
               http://www.mulesoft.org/schema/mule/cmis
               http://www.mulesoft.org/schema/mule/cmis/current/mule-cmis.xsd">

      <!-- here goes your flows and configuration elements -->

</mule>

This module is configured using the config element. This element must be placed outside of your flows and at the root of your Mule application. You can create as many configurations as you deem necessary as long as each carries its own name.

Each message processor, message source or transformer carries a config-ref attribute that allows the invoker to specify which configuration to use.

Attributes
TypeNameDefault ValueDescriptionJava TypeMIME TypeEncoding
xs:string name Optional. Give a name to this configuration so it can be later referenced.
xs:string baseUrl URL base for the SOAP connector.
xs:string connectionTimeout Optional. The connection time-out specification.
xs:string password Password
xs:string repositoryId Optional. The identifier for the Repository that this connector instance works with
xs:string useAlfrescoExtension Optional. Specifies whether the Alfresco Object Factory implementation should be utilized.
xs:string username Username

Message Processors

<cmis:apply-acl>

Set the permissions associated with an object.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object whose Acl is intended to change. CmisObject */*
objectId Optional. The id of the object String */* UTF-8
aclPropagation Wheter to propagate changes or not. can be REPOSITORYDETERMINED | OBJECTONLY | PROPAGATE AclPropagation */*
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:add-aces> Added access control entities List<Ace>
<cmis:remove-aces> Removed access control entities List<Ace>
Returns
Return Type Description
Acl the new access control list

<cmis:apply-aspect>

Apply and aspect to an object and set some properties of that aspect.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
objectId The object's id. String */* UTF-8
aspectName The name of the aspect to be applied to the object. String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> The properties to set. Map<String, String>
Returns
Return Type Description
void The ID of the object that was updated.

<cmis:apply-policy>

Applies policies to this object.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The document from which to get the stream. Can be null if "objectId" is set. CmisObject */*
objectId Optional. Id of the document from which to get the stream. Can be null if "object" is set. String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:policy-ids> Policy ID's to apply List<ObjectId>

<cmis:cancel-check-out>

If applied to a PWC (private working copy) of the document, the check out will be reversed. Otherwise, an exception will be thrown.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
document Optional. The checked out document. Can be null if "documentId" is set. CmisObject */*
documentId Optional. Id of the checked out document. Can be null if "document" is set. String */* UTF-8

<cmis:changelog>

Gets repository changes.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
changeLogToken Optional. The change log token to start from or null String */* UTF-8
includeProperties Indicates if changed properties should be included in the result boolean */*
Returns
Return Type Description
ChangeEvents a ChangeEvents instance

<cmis:check-in>

If applied to a PWC (private working copy) it performs a check in. Otherwise, an exception will be thrown.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
document Optional. The document to check-in. Can be null if "documentId" is set. CmisObject */*
documentId Optional. Id of the document to check-in. Can be null if "document" is set. String */* UTF-8
content File content (no byte array or input stream for now) Object */*
filename Name of the file String */* UTF-8
mimeType Stream content-type String */* UTF-8
major Whether it is major boolean */*
checkinComment Check-in comment String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> Optional. Custom properties Map<String, String>
Returns
Return Type Description
ObjectId the ObjectId of the checkedin document

<cmis:check-out>

Checks out the document and returns the object id of the PWC (private working copy).

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
document Optional. The document to be checked out. Can be null if "documentId" is set. CmisObject */*
documentId Optional. Id of the document to be checked out. Can be null if "document" is set. String */* UTF-8
Returns
Return Type Description
ObjectId PWC ObjectId

<cmis:create-document-by-id>

Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by an object ID.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderId Folder Object Id String */* UTF-8
filename Name of the file String */* UTF-8
content File content as specified in the payload Object */*
mimeType Stream content-type String */* UTF-8
versioningState An enumeration specifying what the versioning state of the newly-created object MUST be. If the repository does not support versioning, the repository MUST ignore the versioningState parameter. Valid values are: o none: The document MUST be created as a non-versionable document. o checkedout: The document MUST be created in the checked-out state. o major (default): The document MUST be created as a major version o minor: The document MUST be created as a minor version. VersioningState */*
objectType The type of the object String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> false Optional. The properties optional document properties to set Map<String, String>
Returns
Return Type Description
ObjectId the object id ObjectId of the created

<cmis:create-document-by-id-from-content>

Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by an object ID. *

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderId Folder Object Id String */* UTF-8
filename Name of the file String */* UTF-8
content File content Object */*
mimeType Stream content-type String */* UTF-8
versioningState An enumeration specifying what the versioning state of the newly-created object MUST be. If the repository does not support versioning, the repository MUST ignore the versioningState parameter. Valid values are: o none: The document MUST be created as a non-versionable document. o checkedout: The document MUST be created in the checked-out state. o major (default): The document MUST be created as a major version o minor: The document MUST be created as a minor version. VersioningState */*
objectType The type of the object String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> false Optional. The properties optional document properties to set Map<String, String>
Returns
Return Type Description
ObjectId the object id ObjectId of the created

<cmis:create-document-by-path>

Creates a new document in the repository where the content comes directly from the payload and the target folder node is specified by a repository path. *

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderPath Folder in the repository that will hold the document String */* UTF-8
filename Name of the file String */* UTF-8
content File content as specified in the payload Object */*
mimeType Stream content-type String */* UTF-8
versioningState An enumeration specifying what the versioning state of the newly-created object MUST be. If the repository does not support versioning, the repository MUST ignore the versioningState parameter. Valid values are: o none: The document MUST be created as a non-versionable document. o checked-out: The document MUST be created in the checked-out state. o major (default): The document MUST be created as a major version o minor: The document MUST be created as a minor version. VersioningState */*
objectType The type of the object String */* UTF-8
force false Optional. If should folder structure must be created when there are missing intermediate folders boolean */*
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> Optional. The properties optional document properties to set Map<String, String>
Returns
Return Type Description
ObjectId the object id ObjectId of the created

<cmis:create-document-by-path-from-content>

Creates a new document in the repository where the content is specified as the value of the "content" parameter and the target folder node is specified by a repository path.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderPath Folder in the repository that will hold the document String */* UTF-8
filename Name of the file String */* UTF-8
content File content Object */*
mimeType Stream content-type String */* UTF-8
versioningState An enumeration specifying what the versioning state of the newly-created object MUST be. If the repository does not support versioning, the repository MUST ignore the versioningState parameter. VersioningState */*
objectType The type of the object. String */* UTF-8
force false Optional. If should folder structure must be created when there are missing intermediate folders boolean */*
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> Optional. The properties optional document properties to set Map<String, String>
Returns
Return Type Description
ObjectId the ObjectId of the created

<cmis:create-folder>

Creates a folder. Note that this is not recusive creation. You just create one folder

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderName Folder name (eg: "my documents") String */* UTF-8
parentObjectId Parent folder for the folder being created (eg: repository.rootFolder) String */* UTF-8
Returns
Return Type Description
ObjectId the ObjectId of the created

<cmis:create-relationship>

Creates a parent/child relationships between two nodes in the repository of the specified relationship object type.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
parentObjectId The ID of the parent (or source) object in the relationship. String */* UTF-8
childObjectId The ID of the child (or target) object in the relationship. String */* UTF-8
relationshipType The name of the relationship type that should be associated with the objects. String */* UTF-8

<cmis:delete>

Remove an object

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object to be deleted. Can be null if "objectId" is set. CmisObject */*
objectId Optional. The object's id. Can be null if "cmisObject" is set. String */* UTF-8
allVersions false Optional. If true, deletes all version history of the object. Defaults to "false". boolean */*

<cmis:delete-tree>

Deletes a folder and all subfolders.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folder Optional. Folder Object. Can be null if "folderId" is set. CmisObject */*
folderId Optional. Folder Object id. Can be null if "folder" is set. String */* UTF-8
allversions If true, then delete all versions of the document. If false, delete only the document object specified. boolean */*
unfile Optional. Specifies how the repository must process file-able child- or descendant-objects. UnfileObject */*
continueOnFailure Specified whether to continue attempting to perform this operation even if deletion of a child- or descendant-object in the specified folder cannot be deleted or not. boolean */*
Returns
Return Type Description
List<String> a list of object ids which failed to be deleted.

<cmis:folder>

Navigates the folder structure.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folder Optional. Folder Object. Can be null if "folderId" is set. Folder */*
folderId Optional. Folder Object id. Can be null if "folder" is set. String */* UTF-8
get NavigationOptions that specifies whether to get the parent folder, the list of immediate children or the whole descendants tree NavigationOptions */*
depth Optional. If "get" value is DESCENDANTS, represents the depth of the descendants tree Integer */*
filter Optional. Comma-separated list of properties to filter (only for CHILDREN or DESCENDANTS navigation) String */* UTF-8
orderBy Optional. Comma-separated list of query names and the ascending modifier "ASC" or the descending modifier "DESC" for each query name (only for CHILDREN or DESCENDANTS navigation) String */* UTF-8
Returns
Return Type Description
Object the following, depending on the value of "get" parameter:
  • PARENT: returns the parent Folder
  • CHILDREN: returns a CmisObject ItemIterable with objects contained in the current folder
  • DESCENDANTS: List> representing the whole descentants tree of the current folder
  • TREE: List> representing the directory structure under the current folder.

<cmis:get-acl>

Returns the ACL if it has been fetched for an object.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object whose Acl is needed CmisObject */*
objectId Optional. The id of the object String */* UTF-8
Returns
Return Type Description
Acl the object's Acl

<cmis:get-all-versions>

Retrieve an object's version history

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
document Optional. The document whose versions are to be retrieved CmisObject */*
documentId Optional. Id of the document whose versions are to be retrieved String */* UTF-8
filter Optional. Comma-separated list of properties to filter (only for CHILDREN or DESCENDANTS navigation) String */* UTF-8
orderBy Optional. Comma-separated list of query names and the ascending modifier "ASC" or the descending modifier "DESC" for each query name (only for CHILDREN or DESCENDANTS navigation) String */* UTF-8
Returns
Return Type Description
List<Document> versions of the document.

<cmis:get-applied-policies>

Get the policies that are applied to an object.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The document from which to get the stream. Can be null if "objectId" is set. CmisObject */*
objectId Optional. Id of the document from which to get the stream. Can be null if "object" is set. String */* UTF-8
Returns
Return Type Description
List<Policy> List of applied policies

<cmis:get-checkout-docs>

Retrieve list of checked out documents.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
filter Optional. Comma-separated list of properties to filter String */* UTF-8
orderBy Optional. Comma-separated list of query names and the ascending modifier "ASC" or the descending modifier "DESC" for each query name String */* UTF-8
Returns
Return Type Description
ItemIterable<Document> list of Document.

<cmis:get-content-stream>

Retrieves the content stream of a Document.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The document from which to get the stream. Can be null if "objectId" is set. CmisObject */*
objectId Optional. Id of the document from which to get the stream. Can be null if "object" is set. String */* UTF-8
Returns
Return Type Description
ContentStream The content stream of the document.

<cmis:get-object-by-id>

Returns a CMIS object from the repository and puts it into the cache.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
objectId The object id String */* UTF-8
Returns
Return Type Description
CmisObject a CmisObject instance

<cmis:get-object-by-path>

Returns a CMIS object from the repository and puts it into the cache.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
path Path of the object to retrieve String */* UTF-8
Returns
Return Type Description
CmisObject a CmisObject instance

<cmis:get-object-relationships>

Returns the relationships if they have been fetched for an object.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object whose relationships are needed CmisObject */*
objectId Optional. The id of the object String */* UTF-8
Returns
Return Type Description
List<Relationship> list of the object's relationships

<cmis:get-or-create-folder-by-path>

Creates a new folder in the repository if it doesn't already exist.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
folderPath Path to the folder String */* UTF-8
Returns
Return Type Description
CmisObject the ObjectId of the created

<cmis:get-parent-folders>

Retrieves the parent folders of a fileable cmis object

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object whose parent folders are needed. can be null if "objectId" is set. CmisObject */*
objectId Optional. Id of the object whose parent folders are needed. can be null if "object" is set. String */* UTF-8
Returns
Return Type Description
List<Folder> a list of the object's parent folders.

<cmis:get-type-definition>

Returns the type definition of the given type id.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
typeId Object type Id String */* UTF-8
Returns
Return Type Description
ObjectType type of object ObjectType

<cmis:move-object>

Moves a fileable cmis object from one location to another. Take into account that a fileable object may be filled in several locations. Thats why you must specify a source folder.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. The object to move. Can be null if "objectId" is set. FileableCmisObject */*
objectId Optional. The object's id. Can be null if "cmisObject" is set. String */* UTF-8
sourceFolderId Id of the source folder String */* UTF-8
targetFolderId Id of the target folder String */* UTF-8
Returns
Return Type Description
FileableCmisObject The object moved (FileableCmisObject)

<cmis:query>

Sends a query to the repository

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
statement The query statement (CMIS query language) String */* UTF-8
searchAllVersions Specifies if the latest and non-latest versions of document objects should be included Boolean */*
filter Optional. Comma-separated list of properties to filter String */* UTF-8
orderBy Optional. Comma-separated list of query names and the ascending modifier "ASC" or the descending modifier "DESC" for each query name String */* UTF-8
Returns
Return Type Description
ItemIterable<QueryResult> an iterable of QueryResult

<cmis:repositories>

Returns all repositories that are available at the endpoint.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
Returns
Return Type Description
List<Repository> a list of Repository.

<cmis:repository-info>

Returns information about the CMIS repository, the optional capabilities it supports and its Access Control information if applicable.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
Returns
Return Type Description
RepositoryInfo a RepositoryInfo instance

<cmis:update-object-properties>

Update an object's properties

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescriptionJava TypeMIME TypeEncoding
config-ref Optional. Specify which configuration to use.
cmisObject Optional. Object to be updated. Can be null if "objectId" is set. CmisObject */*
objectId Optional. The object's id. Can be null if "cmisObject" is set. String */* UTF-8
Child Elements
NameDefault ValueDescriptionJava Type
<cmis:properties> The properties to update Map<String, String>
Returns
Return Type Description
CmisObject The updated object (a repository might have created a new object)

Message Sources

Transformers