I’m pleased to announce a new web application framework, called Granite, and an associated set of reusable libraries, called Uniscala. Please note that this is a work in progress: we are not announcing a release yet, or even a beta. A number people have started asking about the project, and so I felt it would be helpful to let the wider world know what is going on.
Granite is a lightweight framework for the rapid development of web applications. It is based on the very cool and richly featured Apache Wicket web framework. Granite uses an embedded object database that avoids the need for SQL or Object-Relational Mappers (ORMs), and, in the Wicket tradition, is proud of, if not smug about, its distinct lack of external XML configuration files.
Granite is not designed to build large ultra-scalable systems such as Facebook and Twitter, although conceivably it could be a component in a system like that (I sometimes dream of a world where everyone has their own database they can take with them from one application to another). It is more aimed at modest membership databases, staff directories, online shops, and so on.
My prior experience with writing applications for Zope, and Plone, which runs on Zope, was the beginning of Granite. Zope has its own object database, ZODB, which is how I came to be addicted to this kind of persistent storage. Settling on one particular database rather than trying to abstract over many kinds also has certain advantages when it comes to both simplicity and taking full advantage of the features of a database.
The object database that we are using for Granite is Versant’s DB4O, licensed under their dOCL license. Prior to the dOCL, we have been using GPL for our own components, but I believe the dOCL allows us to change to Apache 2.0. If we find the licensing intractable, we will switch to a different object database, such as NeoDatis (LGPL).
Limitations in ZODB, and a desire for type-safe code is what led to a change from the Python-Zope world to the Java world … and the Scala world, because that is what we are coding in. Yes, Scala is the final part of the Granite trinity (Wicket-DB4O-Scala), because only Scala’s expressive power could tempt me away from Python and back to the land of type-safe languages.
What else to say? We really only have one simple example at the moment, and some tectonic plates of architecture are still adrift, especially with regard to the security components. There is also very little internationalisation so far – we really need an expert to guide us here. However, a client project of ours is using Granite for some things and is almost at completion, and we have a number of internal projects on the go that depend on Granite. As well as the example, there is a “quick start” guide available to shows how to check out and use the code. There is also a development Maven repository available, but it is not yet updated often enough (or tested) to recommend that developers use it. There will be further announcements on this soon.
I invite you to check out Granite and play with it. I apologise for the lack of general documentation, but more is coming, especially if people prompt me for it . I’m always open to discussion and suggestions, and nothing is set in stone yet. I intend to publish more entries on the finer details of how Granite hangs together, as well as some detail on the reusable components (the Uniscala libraries) that can be used outside of Granite that I hope some will find useful.