Added: incubator/chemistry/trunk/opencmis/src/site/apt/client-provider.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/client-provider.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/client-provider.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/client-provider.apt Tue Feb
16 16:03:38 2010
@@ -0,0 +1,113 @@
+ -----
+ OpenCMIS Provider Layer
+ -----
+
+OpenCMIS Provider Layer
+
+ The OpenCMIS provider layer hides the CMIS AtomPub and Web Services bindings
+ and provides an interface that is very similar to the
+
{{{http://docs.oasis-open.org/cmis/CMIS/v1.0/cd06/cmis-spec-v1.0.html#_Toc243905428}CMIS
domain model}}.
+ The services, operations, parameters, and structures are named after the
+ CMIS domain model and behave as described in the CMIS specification.
+
+ The primary objective of the provider layer is to be complete, covering all
+ CMIS operations and extension points. The result is a somewhat bulky
+ interface. The {{{./client-api.html}OpenCMIS Client API}} sits on top of the
+ provider layer and exposes a nicer and simpler to use interface. It is the
+ better choice for most applications.
+
+ A connection to a CMIS repository is represented by a
+
<<<{{{./opencmis-commons-api/apidocs/org/apache/opencmis/commons/provider/CmisProvider.html}CmisProvider}}>>>
+ object. Such an object can be created by the
+
<<<{{{./opencmis-provider-impl/apidocs/org/apache/opencmis/client/provider/factory/CmisProviderFactory.html}CmisProviderFactory}}>>>.
+ The factory provides two main methods, one for each binding, that require
+ binding specific connection information. The created <<<CmisProvider>>>
+ object exposes a binding agnostic interface.
+
+ <<<CmisProvider>>> is the entry point to the CMIS services and a few utility
+ operations. It contains a transparent cache for repository infos and type
+ definitions. The object is serializable, although dehydrating can be
+ expensive.
+
+ The <<<get*Service()>>> methods provide access to the CMIS services.
+ Some service operations take provider layer specific objects. These objects
+ should be created with the <<<ProviderObjectFactory>>>. This factory can be
+ obtained through the <<<getObjectFactory()>>> method of the
+ <<<CmisProvider>>> object.
+
+ Please refer to the
+ {{{./opencmis-commons-api/apidocs/index.html}OpenCMIS Commons JavaDoc}}
+ and
+ {{{./opencmis-client-api/apidocs/index.html}OpenCMIS Provider JavaDoc}}
+ for more details on the interfaces.
+
+
+* Sample Code
+
+** Creating an AtomPub Provider
+
+ The AtomPub provider requires the URL of the CMIS service document.
+ HTTP basic authentication is enabled by default and a username and a
+ password have to be provided.
+
++---
+Map<String, String> parameters = new HashMap<String, String>();
+
+parameters.put(SessionParameter.USER, user);
+parameters.put(SessionParameter.PASSWORD, password);
+
+parameters.put(SessionParameter.ATOMPUB_URL, url); // service document URL
+
+CmisProviderFactory factory = CmisProviderFactory.newInstance();
+CmisProvider provider = factory.createCmisAtomPubProvider(parameters);
++---
+
+
+** Creating a Web Services Provider
+
+ The Web Services provider requires a WSDL URL for each CMIS service.
+ This might the same the URL for all services. WS-Security (UsernameToken)
+ is enabled by default and a username and a password have to be provided.
+
++---
+Map<String, String> parameters = new HashMap<String, String>();
+
+parameters.put(SessionParameter.USER, username);
+parameters.put(SessionParameter.PASSWORD, password);
+
+parameters.put(SessionParameter.WEBSERVICES_REPOSITORY_SERVICE,
repositoryServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_NAVIGATION_SERVICE,
navigationServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_OBJECT_SERVICE,
objectServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_VERSIONING_SERVICE,
versioningServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_DISCOVERY_SERVICE,
discoveryServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_RELATIONSHIP_SERVICE,
relationshipServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_MULTIFILING_SERVICE,
multiFilingServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_POLICY_SERVICE,
policyServiceWsdlUrl);
+parameters.put(SessionParameter.WEBSERVICES_ACL_SERVICE, aclServiceWsdlUrl);
+
+CmisProviderFactory factory = CmisProviderFactory.newInstance();
+CmisProvider provider = factory.createCmisWebServicesProvider(parameters);
++---
+
+
+** Getting an Object
+
+ The following snippet gets the name of the object "myObject" in repository
+ "myRepository". The parameters of <<<getObject()>>> can be found in the
+ CMIS specification.
+
++---
+CmisProvider provider = ...
+
+ObjectData myObject = provider.getObjectService().getObject("myRepository",
"myObject",
+ "*", true, IncludeRelationships.BOTH, "cmis:none", true, true, null);
+
+PropertiesData properties = myObject.getProperties();
+PropertyData<String> nameProperty =
properties.getProperties().get(PropertyIds.CMIS_NAME);
+String name = nameProperty.getFirstValue();
++---
+
+
+* Custom Authentication Provider
+
+ tbw.
\ No newline at end of file
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/client-provider.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/apt/how-to-build.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/how-to-build.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/how-to-build.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/how-to-build.apt Tue Feb 16
16:03:38 2010
@@ -0,0 +1,43 @@
+ -----
+ How to build OpenCMIS
+ -----
+
+How to build OpenCMIS
+
+ There is no official release of OpenCMIS, yet. In order to use it, you have
+ to build it. That's a simple task:
+
+ * Make sure you have JDK 1.5 or higher, Maven and a Subversion client
+ installed.
+
+ * Fetch the source code via Subversion from here:
+ <<<https://svn.apache.org/repos/asf/incubator/chemistry/opencmis>>>
+
+ * Change to the <<<trunk>>> directory and run:
+
+ []
+
++---------------+
+mvn clean install
++---------------+
+
+
+* Build the Client Libraries
+
+ If you need the OpenCMIS client libraries with all dependencies,
+ change to the <<<trunk>>> directory and run:
+
++---------------------------+
+mvn package assembly:assembly
++---------------------------+
+
+ This will create a zip file in the <<</target>>> directory with all
+ requires JAR files.
+
+
+* Build the Server Framework
+
+ The server framework will be build with the whole project. There are no
additional step necessary.
+ Please refer to the {{{./server.html}Server Framework}} page for more
information how to use it.
+
+
\ No newline at end of file
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/how-to-build.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/apt/index.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/index.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/index.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/index.apt Tue Feb 16
16:03:38 2010
@@ -0,0 +1,29 @@
+ -----
+ OpenCMIS
+ -----
+
+OpenCMIS
+
+ OpenCMIS is an open source implementation of the
+ {{{http://xml.coverpages.org/cmis.html}OASIS CMIS specification}}
+ for Java.
+
+ The project consists of the following parts:
+
+ * <<CMIS Client>>
+
+ * {{{./client-api.html}Client API}}
+
+ * {{{./client-provider.html}Provider Layer}}
+
+ * <<CMIS Server>>
+
+ * {{{./server.html}Server Framework}}
+
+ * {{{./server-inmemory.html}InMemory Test Repository}}
+
+ * {{{./server-fileshare.html}FileShare Test Repository}}
+
+ * <<Tests and Tools>>
+
+ * {{{./browser.html}CMIS Browser}}
\ No newline at end of file
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/index.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/apt/server-fileshare.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/server-fileshare.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/server-fileshare.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/server-fileshare.apt Tue
Feb 16 16:03:38 2010
@@ -0,0 +1,60 @@
+ -----
+ OpenCMIS FileShare Repository
+ -----
+
+OpenCMIS FileShare Repository
+
+ <<This repository is not indented for productive use!>>
+
+ The FileShare repository uses the file system as its back-end store and
+ provides read/write access to content and metadata. In other words, it puts
+ a CMIS interface on top of your file system.
+
+ The repository is restricted by the capabilities of the file system and
+ therefore does not support relationships, policies, document versions,
+ multi-filing, un-filing and query.
+
+ By default it provides a repository "test" that uses your home directory
+ as the repository root. It requires authentication. A user "test" with the
+ password "test" is pre-configured.
+
+
+* Build and Deploy the Test Repository
+
+ [[1]] {{{./how-to-build.html}Build OpenCMIS}}.
+
+ [[2]] A ready-to-use WAR file should now exist in
<<</opencmis-server/opencmis-server-fileshare/target>>>.
+
+ [[3]] Deploy the WAR file to your favorite servlet engine.
+
+
+* Configure the Repository
+
+ The configuration file in the WAR file is
+ <<</WEB-INF/classes/repository.properties>>>.
+
++----+
+# Don't touch this line
+class=org.opencmis.fileshare.ServicesFactory
+
+# Login configuration
+# login.<no> = <user>:<password>
+login.1 = test:test
+login.2 = cmisuser:password
+login.3 = reader:reader
+
+# Type defintions (see example-type.xml)
+# type.<no> = <absolute path to type definition XML file>
+type.1 = /home/cmistest/type1.xml
+type.2 = /home/cmistest/type2.xml
+
+# Repository configuration
+# repository.<repositoryId> = <absolute path to repository root folder>
+# repository.<repositoryId>.readwrite = <comma separated list of login names>
+# repository.<repositoryId>.readonly = <comma separated list of login names>
+repository.test = /home/cmistest/myreproot
+repository.test.readwrite = test, cmisuser
+repository.test.readonly = reader
++----+
+
+
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/server-fileshare.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/apt/server-inmemory.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/server-inmemory.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/server-inmemory.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/server-inmemory.apt Tue Feb
16 16:03:38 2010
@@ -0,0 +1,19 @@
+ -----
+ OpenCMIS InMemory Repository
+ -----
+
+OpenCMIS InMemory Repository
+
+ <<This repository is not indented for productive use!>>
+
+
+* Build and Deploy the Test Repository
+
+ [[1]] {{{./how-to-build.html}Build OpenCMIS}}.
+
+ [[2]] A ready-to-use WAR file should now exist in
<<</opencmis-server/opencmis-server-inmemory/target>>>.
+
+ [[3]] Deploy the WAR file to your favorite servlet engine.
+
+
+* Configure the Repository
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/server-inmemory.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/apt/server.apt
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/apt/server.apt?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/apt/server.apt (added)
+++ incubator/chemistry/trunk/opencmis/src/site/apt/server.apt Tue Feb 16
16:03:38 2010
@@ -0,0 +1,82 @@
+ -----
+ OpenCMIS Server Framework
+ -----
+
+OpenCMIS Server Framework
+
+ The OpenCMIS Server Framework provides a server implementation of both
+ CMIS bindings, AtomPub and Web Services, and maps them to Java interfaces.
+ Requests and data from CMIS clients are converted and pushed to a repository
+ connector. The connector translates the CMIS calls into native repository
+ calls.
+
+
+* Repository Connector Development
+
+ This is a brief description of the interfaces and classes a repository
+ connector has to extend and implement. For interface details see the
+ {{{./opencmis-server-spi/apidocs/index.html}OpenCMIS Server Framework SPI
JavaDoc}}.
+
+
+** Framework Entry Point
+
+ A repository connector has to extend the
+
<<<{{{./opencmis-server-spi/apidocs/org/apache/opencmis/server/spi/AbstractServicesFactory.html}AbstractServicesFactory}}>>>
+ class. This class manages the objects that implement the interfaces of
+ the different CMIS services. There is only one active instance of this
+ class per servlet context. The class name has to be set in the
+ configuration file <<</WEB-INF/classes/repository.properties>>>.
+
++----+
+# set fully qualified class name
+class=org.repository.ServicesFactory
++----+
+
+ The configuration file can contain more key-value pairs. They are passed
+ to the <<<init()>>> method of the <<<AbstractServicesFactory>>> object
+ when the servlet context starts up.
+
+
+** Service Interfaces
+
+ There is an interface for each service in the
+ {{{http://docs.oasis-open.org/cmis/CMIS/v1.0/cd06/cmis-spec-v1.0.html}CMIS
specification}}.
+ Most methods are named after the operations described in the CMIS
+ specification document. There are a few exceptions to that rule because the
+ AtomPub binding doesn't always allow a one-to-one mapping. Those divergences
+ are explained in the JavaDoc.
+
+ The methods take the same parameters as described in the CMIS specification.
+ There are also a few exceptions that are explained in the JavaDoc.
+
+ The first parameter of all methods is the
+
<<<{{{./opencmis-server-spi/apidocs/org/apache/opencmis/server/spi/CallContext.html}CallContext}}>>>.
+ It is used to
+ transport authentication data to the connector.
+ (See section "Authentictaion Framework".)
+
+ Some methods have an additional
+
<<<{{{./opencmis-server-spi/apidocs/org/apache/opencmis/server/spi/ObjectInfoHolder.html}ObjectInfoHolder}}>>>
+ parameter. This object
+ is only set if the call is an AtomPub call. AtomPub entries and feeds
require
+ additional data about the objects that should be returned AND the object that
+ has been passed. In case of a <<<getChildren()>>> call, for example, data
about
+ the children AND folder itself would be required.
+ <<<ObjectInfoHolder>>> collects <<<ObjectInfo>>> objects.
+
+
+** Authentictaion Framework
+
+ tbw.
+
+* Repository Connector Deployment
+
+ The OpenCMIS build procress creates a WAR file in
+ <<</opencmis-server/opencmis-server/target>>>. This WAR file should be used
+ as a template. It can be deployed as it is but doesn't do anything.
+
+ In order to use your connector, copy your compiled connector code into this
+ WAR file and overwrite <<</WEB-INF/classes/repository.properties>>>.
+
+ Have a look at the {{{./server-fileshare.html}OpenCMIS FileShare test
repository}}
+ code and <<<pom.xml>>>. It's a simple example of a repository connector.
Propchange: incubator/chemistry/trunk/opencmis/src/site/apt/server.apt
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/chemistry/trunk/opencmis/src/site/site.xml
URL:
http://svn.apache.org/viewvc/incubator/chemistry/trunk/opencmis/src/site/site.xml?rev=910572&view=auto
==============================================================================
--- incubator/chemistry/trunk/opencmis/src/site/site.xml (added)
+++ incubator/chemistry/trunk/opencmis/src/site/site.xml Tue Feb 16 16:03:38
2010
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="OpenCMIS">
+ <body>
+ <menu name="OpenCMIS">
+ <item name="Introduction" href="index.html" />
+ <item name="How to build OpenCMIS" href="how-to-build.html" />
+ </menu>
+ <menu name="CMIS Client">
+ <item name="Client API" href="client-api.html" />
+ <item name="Provider Layer" href="client-provider.html" />
+ </menu>
+ <menu name="CMIS Server">
+ <item name="Server Framework" href="server.html" />
+ <item name="InMemory Repository" href="server-inmemory.html" />
+ <item name="FileShare Repository" href="server-fileshare.html" />
+ </menu>
+ <menu name="Tests and Tools">
+ <item name="CMIS Browser" href="browser.html" />
+ </menu>
+ <menu ref="reports" />
+ <menu ref="modules" />
+ </body>
+</project>
\ No newline at end of file
Propchange: incubator/chemistry/trunk/opencmis/src/site/site.xml
------------------------------------------------------------------------------
svn:eol-style = native