Latest Posts

Archives [+]

Entries filed under 'jsr283'

    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 Cedric Huesler SEP 24, 2009

    Posted in announcements, cq5 and jsr283 Add comment

    In 3 weeks from today we are going to kick-off our annual Customer Summit in Zurich (and two weeks later in Chicago). Going through the office in Basel feels like everybody is busy making sure the events are going to be awesome.

    The engineering team is putting the final touch on what has been in the making for multiple years - yes - I'm talking about JCR 2.0. It is exciting to witness the implementation of the next generation content infrastructure API and see what it does for the user facing content applications. The next version of our WCM, DAM and Social Collaboration platform CQ5 - to be unveiled at the Customer Summits - is taking full advantage of JCR 2.0 (JSR-283). This for sure is great news for developers. They get an extended rock solid API to build content applications and integration services.

    Another mission - with focus to reduce the distance between the author and the consumer (visitor) - resulted in a slew of new CQ5 features. We want content authors to have a better insight on how their content is consumed and provide feedback what worked and what not. With this, we are closing an important loop in providing targeted content to an apparently unknown audience.

    If that is not enough, I'm sure you are interested to learn how the City of Chicago, Adobe, New York University (in Chicago), Telecom Italia, Boehringer Ingelheim and Investec (in Zurich) are using the Day products. That's only an excerpt of companies and partners that will participate - we are finalizing the agenda this week and will make it available starting next week.

    For all of you already signed-up for the Summit - we are looking forward to share with you the latest awesomeness in Zurich or Chicago. If you haven't - it's not too late.

    Posted by Peeter Piegaze SEP 18, 2009

    Posted in jackrabbit, jcr, jsr283 and standards Comment 1

    And of course, JSR-283 builds on the work done in JSR-170:
     
    734 issues
    662 issues in JSR 170
     
    1456 days
    1213 days from start to finish of JSR 170.  
    72 individual members of the expert group
    1/2 as many members in the 170 expert group.  
    43 organizations represented
    1/2 as many organizations represented.  
    277 pages of spec
    297 pages in 170. Yet 283 contains so much more! :-)  
    87 interfaces and classes
    59 interfaces and classes in 170.  
    522 fields and methods
    334 fields and methods in 170.  

    Posted by David Nuescheler SEP 14, 2009

    Posted in jackrabbit, jcr, jsr283 and standards Comment 1

     

    734 issues
    1456 days
    72 individual members of the expert group
    43 organizations represented
    3 ballots of the executive committee of the JCP
    41 yes votes
    0 abstentions
    0 no votes
    5 face-to-face meetings
    76 telephone conferences
    277 pages of spec
    87 interfaces and classes
    522 fields and methods
    1895 testcases in the official TCK
    100% signature coverage of the TCK
    2.0 Content Repository for Java Technology API