viernes, 18 de febrero de 2011

Introducing OSS Money

Do you like MS Money? I do. A lot. That's the main reason that saddened me when Microsoft decided to discontinue the product. There are several good free online alternatives but I don't like to trust my financial data to anybody but me and my bank. In the Open Source scene there's GNU Cash but...

During the last year I contributed very very little to the OSS scene (just some code to Gmaps4JSF actually) so I decided that I had an itch and may be I should take the opportunity to do something about it. So, without further delays, I've started a new project at Google Code, it's called OSS Money (tribute to the mentioned MS software), and it'll be an expense tracker and budget planner. Right now I've barely scratched the surface but I have something to share. Here's the desktop screen as of today (in Spanish with two currencies):



For those willing to help with the project, it's a multi-language Spring Roo application with a Dojo 1.6 frontend. Right now, I'm not going to provide binaries (very alpha status, feature wise) but checkout the code and let me know your impressions. Or open some issues if you have any ideas!

miércoles, 2 de febrero de 2011

Test driving Spring Roo..for real

I had the oportunity to evaluate Spring Roo some time ago but I didn't actually use it in a project till recently. Today, after hours and hours of heavy I wanted to share some thoughts about the tool.

First, it has some AWESOME features:

  • There's absolutely no way to create a project from scratch that packs a Spring context, Maven, a security solution, REST/MVC and persistence in less time. Everything is very well configured and just works, in a matter of seconds and four commands. Congrats here to the Roo team.

  • The @Configurable entities (ala Grails) are incredibly useful. Having an EntityManager injected in the model and predefined CRUD methods is invaluable.

I liked
  • The environment. Both, the command line tool and the STS plugin. IDE integration surprised me, it's well rounded.
So-so things I found:
  • As mentioned, Roo is fast when creating a new project. It comes at a price though as your commitment with the Spring stack is absolute. Of course, this may be a non-issue for many people as of today.
  • Roo values Convention over Configuration and in such spirit it makes a lot of assumptions..on your behalf. I've found some of them questionable. For example, in a tool so focused on persistence, why is the authentication provider configured in memory by default? Of course, it works out-of-the-box, but I'm pretty sure that 99.99% of the users will change that. Roo creates a login page for me, great but I was expecting a DB authenticator in there (and User and Role classes!)
  • Controller scaffolding...yeah. It works and it's fine. It's just that a real application may look like the generated pages...or not. If not, and that seems to be my case all the time, it's not worth the effort. For a rush...a good addition!
But there are things that are PLAIN WRONG:
  • Roo seems to take a reckless approach to programming. It's not what I would call an error friendly tool, not even by a far margin. Not that Roo fails by itself (seems quite robust in fact) but the user will undoubtedly do it. That's not actually an issue, everybody makes errors. The problem is how easily you can fix them. Any IDE basically provides an unlimited UNDO/REDO capability. Fixing something is a matter of pressing CRTL+Z in most cases.

    Things are not that easy with Roo, obviously because it lacks the UNDO command, but in more subtle ways aswell. The generated code cannot be touched (it will be overwritten time and again) and pretty much everything is generated (90% of the code is hidden to the user). And even if it could it would be a daunting task unless you're an expert in AspectJ syntax.

    Many many times, it's just better to delete the involved source files and restart the work. Do I have to mention how frustrating this can get? May be it's me, I'm so used to it that I don't really pay the due attention anymore but, lo and behold! check twice before clicking that Execute button with Roo
Will I give Roo the seal of approval then? I'm afraid I won't this time. Right now, it's a fantastic tool to create a project. And good for the advanced architect. But this is not a tool for neophits (a resounding no!) and still needs some work in key areas. But I won't ditch it. It's worked quite well for me! But before diving into Roo just check your knowledge with Spring and AOP in general. Otherwise, Roo will create you more headaches than it will solve.