Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0

Jackrabbit Branch Development / Integration

In this section I want to summarize the process of the content repository integration.

...

  • When we have an external content Repository it's easy to connect third party tools to the repository (i.e. CMS Systems)
  • If we have a generic JCR implementation we can simply add different content repositories
  • Content Repositories allow easier maintenance of complex content structures, as contents are no longer stored in different tables (Content, Resource, ElectronicText ...).
  • Content Repositories can provide revisioning of contents and content modifications

What has been done

  • Created a new independent JCR module in the framework
  • Start the Jackrabbit Container on ofbiz startup
  • Created a Repository Factory
  • Created a Jackrabbit - Ofbiz architecture proposal: Image Removed
  • (Implementation of the proposal is done and will be committed after review)  done @Rev: *1094250:
    • * You can create new repository nodes
      * Nodes are represented in a tree structure
      * Nodes can store Text (Text, HTML, FTL ....) and File content
      * There is a separate tree to store files and text content because the repository don't allow to mix them up, but this absolutely transparent for the user
      * Each new node is linked to a content entity
      * The link in the content entity can be used for maintainable reasons (permission checks, user specific content, content status etc.)
      * Everything can be tested under Examples --> Jackrabbit Sandbox
  • Jackrabbit Node Structure for (i18n) text content and files: 
  • JCR contents and nodes are always be revisioned
  • ---------------------------------------
  • Code refactoring, now using Jackrabbit OCM (ObjectContentMapping) to store Content Objects in the repository. Which makes it much easier to store different content objects, and we are flexible to add as much content fields, information as we want.
  • New Class Diagramm:  Image Removed
  • Nodes and Content can now stored in different languages
  • Nodes and Content will always be versioned
  • A new layer in the application area provides a simpler API to work with the Ofbiz Content Mapping Objects, this layer contains content and application specific code and is build on top of the generic jcr framework level

Ofbiz Jackrabbit architecture description

In the next few lines I would like to describe the architecture diagram and explain why I chose this way to integrate Jackrabbit in OFBiz.

The design is based on the Jackrabbit OCM (ObjectContentMapping) Package which gives us the ability to map objects to the content repository. Choosing this approach makes us more flexible to use different types of content. I.e. it’s possible to create different Content Objects with specific fields for blogs, forums, Products, Files, partys and so on.

In the current release I avoid any connections to the database, that makes the implementation absolute independent from the application site.

...

Framework side – An interface to JCR implementations and the example implementation

...

The Framework provides interfaces which should be implemented to make a JCR repository available in OFBiz. Furthermore the JCR reference implementation Jackrabbit can be found in the framework.

...

org.ofbiz.jcr.access

...

This package contains interfaces to connect to the Jackrabbit OCM.

The RepositoryAccess class creates the OCM connection and provides methods for CRUD operations. The CRUD operations are defined in the ContentWriter and ContentReader classes.

The VersionManager is responsible for all versioning related operations and is used by the ContentReader/Writer to grant access to versioned nodes.

...

org.ofbiz.jcr.orm

...

The ORM (OfbizRepositoryMapping) package is the OFBiz abstraction of the content objects. The OfbizRepositoryMapping interface is used by the ContentReader/Writer to interact with the ObjectContentMappingManager.

...

org.ofbiz.jcr.loader

...

Contains all classes to start the jcr/jackrabbit container, register everything in the JNDI and make sure that all additional namespaces and nodeTypes a registered.

...

org.ofbiz.jcr.util

...

The util classes contain static methods, which helps to work with the content repository.

...

org.ofbiz.jcr.handler

...

The repository need an own handler with no overhead, to stream (i.e.) images to a webpage.

...

org.ofbiz.jcr.security

...

Provide some security functions to control the repository access.

...

 Application side

...

For now there are no application related implementations. It is conceivable that we have a application related content database connection or different Content Workers which provide additional functionality for the specific context.

Still to be done

Ideas

Table of Content