Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
CMIS connector for Apache Camel
Java
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
src
.gitignore
README
pom.xml

README

Camel CMIS Component
====================

Enables Apache Camel to connect to CMIS supporting content repositories

Example usage:

1.Query cmis server using CMIS Query Language

from("direct:a")
    .body("SELECT * FROM cmis:document WHERE cmis:name LIKE 'test%'")
    .to("cmis://http://localhost:8080/chemistry-opencmis-server-inmemory-war-0.5.0/atom?username=admin&password=admin&repositoryId=A1&query=true");
    .to("stream:out");

To query CMIS server, create a producer by specifying query=true in the parameters and put the cmis query in the body of the message.
The result of the query is in the body of the message as a List, where each item is Map containing all the properties of the node.
Additionally it is also able to retrieve InputStream for the content itself if specified in the header as CamelCMISRetrieveContent true.


2. Create Folders and Documents on the CMIS server.

from("direct:start")
    .process(new Processor() {
        public void process(Exchange exchange) throws Exception {
            exchange.getOut().setHeader("cmis:objectTypeId", "cmis:folder");
            exchange.getOut().setHeader("cmis:name", "Test Folder");
        }
    })
    .to("cmis://http://localhost:8080/chemistry-opencmis-server-inmemory-war-0.5.0/atom?username=admin&password=admin&repositoryId=A1")

Creates a CMIS document which content is message body and properties from headers. For document with content, mimetype or content type is required header.
Creates folder if there is no message body or folder type is specified.
Name header is required for both document and folder creation.
Optional path header can specify in which location at create the new node. If not specified, the new node is created under the root folder.
Something went wrong with that request. Please try again.