Latest Posts

Archives [+]

Archive for 'May 2010'

    Posted by Jukka Zitting MAY 28, 2010

    Posted in crx, crx gems, jcr and jsr283 Add comment

    The Repository object is the front door of the JCR API. Whenever a client application needs to access a content repository, it first needs access to a Repository instance through which all the other JCR functionality can be accessed. However, JCR 1.0 didn't specify where and how such a Repository instance can be found or created, so applications had to use things like JNDI lookups or implementation-specific initialization code to bootstrap access a content repository.

    One of the goals of JCR 2.0 was to specify a standard solution to this bootstrap problem. To achieve this goal, the expert group specified the RepositoryFactory interface that allows an application to convert a Map of configuration options to the corresponding Repository instance. The recommended way to access a RepositoryFactory instance is to use the ServiceLoader class in Java 6 or the equivalent but oddly located ServiceRegistry class in Java 5. As a last resort one can also instantiate a known RepositoryFactory implementation class using the specified public zero-argument constructor. The following code snippet shows how this works:

    Map parameters = new HashMap();
    parameters.put(..., ...);

    Repository repository = null;
    Ierator<RepositoryFactory> iterator =
        ServiceRegistry.lookupProviders(RepositoryFactory.class);
    while (repository == null && iterator.hasNext()) {
        repository = iterator.next().getRepository(parameters);
    }

    The RepositoryFactory approach works pretty well, but it's a bit verbose as shown above. To avoid having to rewrite this piece of code in all JCR client applications, we implemented a simple JcrUtils.getRepository(Map) utility method in the jackrabbit-jcr-commons library. With this utility method you can simplify the above code to:

    Map parameters = new HashMap();
    parameters.put(..., ...);

    Repository repository = JcrUtils.getRepository(parameters);

    That's already pretty nice, but in practice we found that having to keep track of the map of configuration options is often a bit complicated. For example it's unnecessarily difficult to specify the configuration options as command line arguments, in servlet configuration or in a GUI configuration dialog. Wouldn't it be great if we could narrow the configuration down to a single string, like the database URIs used in JDBC? We thought so, and set out to implement the concept of a repository URI.

    To do this we defined a specific repository configuration parameter "org.apache.jackrabbit.repository.uri". All repository factories that want to support repository URIs should look for this parameter in the Map instance given to the getRepository() call. We modified all the repository factories in Jackrabbit and CRX to support this parameter and added the JcrUtils.getRepository(String) utility method to further simplify client code. For example:

    // WebDAV remoting access to a CRX server
    JcrUtils.getRepository("http://localhost:7402/crx/server");

    // RMI remoting access to a CRX server (with RMI enabled)
    JcrUtils.getRepository("rmi://localhost:1099/crx");

    The same mechanism also works for JNDI URLs or file:// URLs to local embedded repositories. You only need to make sure that you have all the correct libraries in your classpath. Accessing a JCR repository has never been easier!

    Posted by Michael Marth MAY 28, 2010

    Posted in fise, iks-project and osgi Add comment

    At this week's IKS meeting at Paderborn the second FISE Hackathon took place. FISE is an open source semantic engine that provides semantic annotation algorithms like semantic lifting. The actual annotation algorithms are pluggable through OSGi. Existing CMSs can integrate the engine through an HTTP interface (inspired from Solr). Last week, Bertrand gave an introductory talk about FISE that is available online.

    There was no explicitly set goal for the second Hackathon. Rather, the existing code base was extended in various different directions. Some examples:

    • a language detection enhancement engine (I am particularly glad to see this - automatic language detection in CMSs is a pet passion of mine)
    • a UI for FISE users that allows humans to resolve ambiguities
    • myself, I coded a JCR-based storage engine for the content and annotations

    There was also a good amount of work done on the annotation structure used by FISE and documented on the IKS wiki.

    A complete report of the Hackathon is available on the IKS wiki (the only thing it fails to mention: the event's good spirit).

    One major non-code step was to get many participants up to speed with the FISE engine and enable them to deploy the engine as well as get accustomed with the architecture and code base.

    It was only last week that I took a deeper look into FISE. I like its architecture a lot. The HTTP interface makes it easy to play with FISE as well as integrate it. Even more important, the pluggable archirecture that is mostly inherited from the OSGi services architecture makes FISE very flexible and extensible. This is particularly important given the different natures of the enhancement engines that we want to be able to deploy (hosted services, proprietary, open source, etc). I consider FISE to be a particularly well suited use case for OSGi.

    Posted by Greg Klebus MAY 28, 2010

    Posted in announcements, crx and crx gems Add comment

    We released CRX 2.1 exactly a month ago. Now that the release dust has settled a bit, I have realized how much we have done in this release, and how many interesting features and technologies we have included, either completely new or largely enhanced. In essence, we've got many gems in CRX 2.1, and gems are sometimes not easy enough to find.

    From my personal experience you can always learn interesting things about the product from the engineers who actually implemented, tested, or documented the stuff. Water cooler talk can help you understand a lot in an easy, relaxing manner.

    All that has led me to an idea to have series of blog posts, CRX Gems. Day Software developers and engineers will be presenting their favorite features from CRX 2.1, explaining how to do things, or indeed uncovering hidden gems. The inaugural post about Repository URIs will be done by Day senior developer and Apache committer, Jukka Zitting.

    Happy Reading!

    Posted by Bertrand Delacretaz MAY 20, 2010

    Posted in fise, iks-project and screencast Add comment

    Here's a recording of my presentation of IKS FISE to my colleagues today.

    As you can imagine, convincing Day folks of the value of a RESTful interface is quite easy. None of them sent me code for that killer EnhancementEngine yet, but I'm hopeful ;-)

    IKS is organizing a FISE hackathon next week during the General Assembly, hope to see you there, and remote participation via IRC is also welcome.

    IKS FISE

    Posted by David Nuescheler MAY 14, 2010

    Posted in cmis, content management, ipad, iphone, java content repository, jcr, mobile and wcms Comment 1

    I was invited to speak at the CM Forum in Brussels on the Future of WCM. I think it is a very broad topic and it is hard to make specific predictions, so it was tricky to come up with something meaningful.

    Here is what I came up with. Feedback (as always) very welcome.

    According to my predictions (or wishes) in this presentation the Future is...

    1. OPEN.
    2. CLOUDY.
    3. BUSINESS.
    4. CONTEXT.
    5. AGILE.
    6. MOBILE.

    Is your WCM future proof?

    Posted by Greg Klebus MAY 10, 2010

    Posted in communique and crx Add comment

    I've been getting many questions from our Support and Services organizations, as well as from some customers, whether it is recommended to upgrade the CQ 5.3 instance to CRX 2.1. I'd like to share my view on this here and provide some information to help decide on this subject.

    As with any upgrade, you have to carefully weigh the expected benefit versus inherent risk any upgrade has. And of course, the closer given environment to "production" usage, the more cautious you should be with upgrade planning.

    More details follow, but I would basically recommend considering the upgrade if:

    • on development machines, you use CRXDE or CRXDE Lite, and especially if you use SVN Integration
    • on other machines, some of the enhancements or bugfixes done in CRX 2.1 (after 2.0) are relevant to your deployments (see subsections titled "CRX 2.1" in the release notes section on Changes in CRX 2.1)

    CRX 2.1 Highlights for CQ 5.3 Users. CQ 5.3 has already CRX 2.0 - internally released version of CRX 2 repository - embedded in the product, so it benefits from the many enhancements and fixes in the 2.0 release. The most important changes introduced in CRX 2.1 after the 2.0 release are as follows:

    Development environments: CRX IDEs

    • CRXDE 1.0 has been released. However, you don't need to upgrade to CRX 2.1 to benefit from it - you can also just install the updated support package.
    • CRXDE Lite has a few usability enhancements
    • Both environments have improved and extended integration with CQ5/CRX
      • Subversion integration has been extended (import and export) and improved (checkin, better best-effort conflict resolution)
      • Project wizard added (this is mostly for CRX, in CQ5 there is a more powerful Site Importer)

    Important repository enhancements

    • Online backup has now option to backup to a directory (without creating a zip), and to specify delay value for "slower" backup, which puts less overhead on the live system
    • Added configurable sizes for internal repository caches (enhancement #28288 in Release Notes), allowing for advanced performance fine-tuning
    • Stability and scalability fixes and enhancements
    • The included open-source libraries have been updated and the changes since CRX 2.0 (CQ 5.3) release included

    See Release Notes for details of changes. The Changes section has been broken down into changes up to CRX 2.0 (labeled "CRX 2.0") and those up to CRX 2.1 (labeled "CRX 2.1") to help CQ 5.3 customers understand the value of upgrading repository to CRX 2.1 easier.

    Other enhancements - the new GUI for CRX Package Manager and added compatibility with Package Share do not directly concern CQ 5.3 users (whether they decided to upgrade to CRX 2.1 or not). CQ 5.3 users should continue using the CQ 5.3 Package Manager (also enabled for Package Share). Both products offer a different GUI for the same basic functionalities and package format.

    Posted by Michael Marth MAY 04, 2010

    Posted in agile, data first, davids model, jcr and modelling Comment 1

    Recently, I read up on quite a number of NoSQL protagonists. Of course, one dominant theme in NoSQL land is "schemaless" as opposed to the full-schema nature of relational databases. As usual, both approaches have their specific pros and cons. A common critism of schemaless data stores is that the entropy of the data would create problems in the long run when too much unstructured data has been amassed. On the other, hand full-schema data bases are much less flexible or downright the wrong tool for unstructured data.

    In this post I would like to point out that you do not necessarily have to choose between those extremes: JCR-based data stores allow you to store unstructured data, fully structured data and anything inbetween. In lack of a better term I would like to call this a "schema-optional" data store with "semi-structured" data.

    • The JCR node type nt:unstructured is designed to accept any properties, so you can dump at will strings, dates or even binaries into such a node. This node type is very useful to get started with coding an application when you do not know what the end result should look like. It allows for a development approach coined "data first, structure later" where structure emerges from data, rather than be defined a priori.
    • On the other end of the spectrum you can have rigidly defined node types. JCR allows you to specify e.g. mandatory properties, default values or the allowed child node types in a node hierarchy. The Apache Jackrabbit site has a good overview of the Compact Namespace and Node Type Definition which is a notation used to define such structure.

    In between these two extreme cases any middle ground is possible in JCR repositories:

    • First, a rigid node type definition for a specific node can define "residual" properties. Such an approach allows the application to set not only the properties that were defined a priori in the node type definition, but also anything else. This is particularly useful for scenarios were only a part of the requirements is known beforehand or where the requirements are known to evolve over time. You can define the known parts but an application can still freely write anything into the node as if it was unstructured.
    • Second, it should also be noted that these structured, unstructured and semi-structured nodes can happily live next to each other in the same repository tree. So different parts of your application can make use of different levels of structure not only through different node types, but also through different parts in the node hierarchy.

    With JCR 2.0 it has become quite a bit easier to evolve the structure (after all, the mantra is "data first, structure later", not "structure never"): one can now change the node types of existing nodes. That facilitates a migration from, say, nt:unstructured nodes to more structured types.

    Posted by Greg Klebus MAY 01, 2010

    Posted in announcements, cmis, crx, jcr and jsr-283 Comment 1

    I'm proud and excited to see Day CRX 2.1 generally available. This first standalone release of our enterprise content repository product implementing the new JCR 2 (JSR 283) standard, and enabled for the upcoming CMIS standard, is a milestone in Day Software content technology and product strategy. The first release of CRX 2 technology, CRX 2.0 engineering controlled release embedded in our CQ 5.3 product, has been shipping already since January 2010.

    Download the free developer edition of CRX for all your evaluation, development, and testing needs. Watch the product screencast on www.day.com/crx. Follow the First Steps with CRX guide to web application development on CRX platform. You will discover the product features in the matter of minutes. 

    Our enterprise customers and partners can download CRX from DayCare support platform. If you are interested in the enterprise license, contact our regional office. For smaller projects developed using the CRX developer edition, which need to go into production, you can order our competitively priced CRX ONE edition. Projects based on Apache Jackrabbit can also benefit from CRX enterprise or ONE edition's commercial offering & support thanks to drop-in compatibility with CRX.

    This release is the result of industry cooperation in defining the JCR 2 and CMIS standars, open source community providing the reference implementation of JCR and other modules used in CRX, and our customers, partners, and developer edition users providing us with valuable feedback and challenging enhancements requests. I'd like to thank you for this great cooperation on behalf of Day's highly motivated and qualified delivery team, who have made every effort to ensure it is a great product release.

    For more information, see Release Notes and product online documentation at docs.day.com, and knowledge base articles.

    Also, do not miss the upcoming events related to CRX 2.1:

    • Mark the date for the CRX 2.1 Launch Webinars on Thursday, May 6th, 2010: for Europe at 11 a.m. CEST and for US at 10 a.m. PT / 1 p.m. ET.
    • Participate in Day's IT Agility Cup development competition for developers of composite content applications, with categories including Innovative JCR Application, Innovative CMIS Application, and Innovative Mobile Application.