Donnerstag, 11. September 2008

An "in between" review of Sling

Now that I have been using Apache Sling for a pet project for some weeks now, I thought I could share some insights on it. The spaghetti western way, of course :). And all utterly subjective.

The Good

  • java -jar sling.jar -> http://localhost:8080 and dav://localhost:8080. This is fantastic.
  • Scripting support
  • REST: learn it the Sling way
  • webdav-support
  • A good community
  • best-of-breed technologies: OSGI (with Felix), JCR (with Jackrabbit)
  • JCR muscle flexing included: query, hierarchies, versioning
  • semi-structured data approach
  • it's fun

The Bad

Nothing bad, just great stuff with some edges:

The Ugly

  • Docu. Yeah I know. Is getting better, but should be more (please kill those "out of sync" pages)
  • After a fast start, there still is a learning curve (OSGI, REST, JCR, Maven, ...). Since these are hot topics anyway, this is no big deal, expect when you want something fast and nownownow :)
  • bootstrapping problem: despite the available help, I still did struggle with the question whether controls (scripts) or data should be created first. But this is just me, I guess :)
  • JCR Editor support: Days eclipse plugin is great, but unfortunately doesn't work on my Ubuntu-system
  • No out-of-the-box solution for rich applications (Except dojo, which is a beast on its own...)
All in all, Sling holds its head up high in a tight, competitive market. I am looking forward to do more stuff with it. The rough spots are being addressed, therefore I am positive and quite impressed. Most important thing now would be to flesh out the documentation....

update 13th Sept: The JCR Plugin for eclipse works after a fresh install, using Eclipse Ganymede and JCR Plugin version 3.6.6. Nice thing is, that Eclipse editors seem to work, e.g. when editing a HTML file. Have to check if this works with the groovy editor too ...


Michael Marth hat gesagt…

Hi Chrigel,

thanks for the review. Spaghetti western style is cool.

Some comments on the "ugly" item, though:

- I do not really understand your bootstrapping problem. You can for example create an html form to fill in content by hand or get it into the repository through a script. I guess I just dont quite get the issue.

- JCR editors: afaik (but I am not sure) Day's eclipse plugin should run on Ubuntu. Could you send a bug report to me, please? There are some more listed here:

- No RIAs: well, Dojo is supported. Json is supported out-of-the-box, so many RIA frameworks should work (if the framework is not retarded, you know who I mean). What kind of support are you looking for?


Chrigel hat gesagt…

Hey Michael

Yeah, the bootstrapping problem is my personal problem, not one of Sling. I think, I got spoiled by Grails, where you can easily plug away at your model, and then, on a certain point in time , switch over to the bells&whistles of GUI programming. But yeah, not "ugly" in that sense, just an old fart trying out a new toy :)

Re RIA: You are right, JSON should be a "must-have" requirement of a modern framework. But there are other aspects like full blown REST-support which should be adoptable to Sling specifics (like file upload handling). Again, not a point against Sling, it's just that there is a rupture in ease of usage.

Are there any good REST clients written in Java?

gklebus hat gesagt…

Hi Chrigel

Thanks for the comments, I share your view that we're missing the documentation badly.

Re problem on Ubuntu - could you please share that with us? Being the Day CRX Product Manager, and using Ubuntu as my primary OS, I'm highly interested in that!


Michael Marth hat gesagt…

Hi Chrigel,

regarding the model thing: in Sling you have the possibility to do "data-first", i.e. work without a strict model and just create nodes with the properties you need at that moment. In my experience this is the preferred approach. Compared to Rails/Grails there is no hard definition of a model in that case. It is just nodes with properties. More like "prototype in JS" than "class definition in OOP".

Re the file upload: file uploads into Sling are done through s aimple HTML upload form. That means if the RIA platform of choice can do that you are all set. I am aware that there are some problems in Flash with FileUploads (and cookies I believe or sthg similar). Question is if the server-side should work around this....

Michael Marth hat gesagt…

REST client:
(have not tried it, yet)