Red Hat
Aug 27, 2014
by Randall

The ModeShape community is proud to announce the immediately availability of our latest 4.0 pre-release, ModeShape 4.0.0.Beta1. The JARs and other artifacts are available in the JBoss Maven repository and in our downloads area, and will be soon in Maven Central. See our Getting Started guide for details.

Thanks to our whole community for the work that’s gone into this release!

What’s new?

This beta release contains 46 fixes and a few new features. In the previous alpha releases we previewed a new query engine that no longer indexes everything in the repository like in 3.x, but instead always executes a query even if no indexes are available and can be used. With this beta release, you can now explicitly define indexes that index only the information necessary to make your queries faster. This means lower overhead, smaller footprint, and more efficient query processing. .

Here’s a rundown of the most important features and changes in 4.0 so far:

  • JDK 7 – ModeShape 4.0 requires JDK 7. We’ve not yet begun testing with Java 8, but we’d be happy to hear about it if you do.
  • Queries – The new query engine is more capable than in 3.x, and it buffers results off-heap to prevent large queries from exhausting your application’s memory. The engine still supports a variety of query languages, though JCR-SQL2 is still the most powerful and with 4.0 has a few more extensions. Explicitly define indexes to make your queries faster. All indexes are stored locally on the file system, and in clustered repositories each process in the cluster maintains its own copy of the indexes. In 4.1 we’ll start offering the ability to mix these with indexes stored in Solr, ElasticSearch, and/or Lucene.
  • Clustering – Configuring a cluster of ModeShape repositories is even easier. All configuration is done within the Infinispan’s clustering setup – if Infinispan is clustered, then ModeShape is part of the same cluster. We’ve also upgraded to a newer version of JGroups.
  • Journaling – ModeShape has a new event journal mechanism that helps the new (or returning) processes in a cluster better come up to speed with the history of events. You get all this with no work on your part, but even your applications can use the new feature via the JCR 2.0 event journal API.  This is a great alternative to JCR event listeners that in some situations might be very expensive or time-consuming.
  • Event bus – We’ve completely rewritten the way ModeShape repositories internally handle events. We now use a ring buffer that is substantially faster than what we had in 3.x. There’s no change in the event APIs so your listener implementations will continue to work unchanged – they’ll just be faster. The speed improvement is important, because we’re internally using listeners in more areas.
  • Infinispan – We’ve moved to Infinispan 6.0.x.Final, which is faster and has new cache stores. Some older and poorly-performaing cache stores are no longer valid, so check out the new file-based cache stores. Also, the LevelDB cache store is supposedly very fast.
  • Wildfly 8 – You can embed ModeShape within your applications, or you can install ModeShape as a subsystem within Wildfly so that your web apps and services can store and access content via the JCR API.
  • Repository Explorer – We’ve redesigned this web application to be much more usable.

The set of 4.0 alpha and beta releases also include 118 bug fixes and other improvements.

What’s next?

Over the next few weeks we’ll keep fixing bugs and trying to stabilize the release. But as of today, there are just a few outstanding issues. Not only is the codebase already pretty stable, but we may be able to get to the final release pretty quickly.

What can you do?

Simple: test this release. Download it, use it, try the new features, and put it through its paces. Try it out and see how Infinispan 6 works, how much faster it is, and try one of the new and high-performance cache stores. Try out ModeShape in Wildfly 8. Give queries a whirl, and let us know if there are any queries that worked in 3.x no longer work in 4.x; remember they’ll probably be slower than in 3.x until you explicitly add indexes that cover your query constraints.

Original Post