IDEA 5.1

IDEA 5.1 has been released to much rejoicing. Well, I rejoiced at least. I've seen some occasional instabilities with 5.0.2 but I think I've traced it to cache corruption/staleness. IDEA would suddenly fail to parse my code and I'd get stack traces involving the PSI code in the error tracker. The workaround is to shutdown, delete the cache from disk, and restart. I don't think this is fixed in 5.1 as I just looked at the bug(s) entered against it but hopefully at least the Jetbrains guys are aware of it now. 5.1 is a bit snappier with some nice new features. You should definitely check it out.

RSS Readers

It's been a while since I've posted anything, but I did want to share a tidbit with you. I've been looking for a decent RSS aggregator for windows for the last week or two. Under KDE, I've been using akregator and been overall pleased with it (not to mention accustomed to its operation). So I've been trying to find something similar under windows. I think I've found it : RSS Bandit. It's a nice slick interface and is easily integrated with firefox though it does boast a built-in browser window, too. So if you're looking for a good reader, I'd definitely suggest you check out RSS Bandit.

EJB3 and Hibernate

Tonight at the Denver JUG the main topic was EJB3. While the spec isn't official just yet, it's as good as and people have started using it. The hibernate annotations developers, for example. I've been using these annotations for a while now on a couple of projects but I haven't really thought of them in the context of what's coming with EJB3. One of things coming is dependency injection from the EJB container. When the speaker mentioned this, it made much more sense of the dust up a few months back when the hibernate team started scrubbing references to IoC containers such as Spring from their website. Why bother with some other IoC when your parent (JBoss) is going to offer one. In one sense, this makes a little sense. On the other hand, EJB3's dependency injection doesn't really work outside the scope of the EJB classes. So if you want it for something that's not an EJB of one form or another, you're screwed.

I applaud the direction that EJB3 is taking: borrowing from RoR's example of convention over configuration, e.g. Having used that a fair bit with my Hibernate beans, I can say it's definitely a relief. The need for XML with EJB3 is almost nothing. The only XML the presenter used tonight was for the .par file (yes, another Blah ARchive) and that was for the datasource definition. It was about 7 or 8 lines. Nothing odious. A developer can use some XML to override the annotations at deployment time, if desired, but from how it appears, the XML is just about gone with EJB3.

EJB3 has some nice features that aren't really available in Hibernate, as far as I can tell, like extended transactions across calls for things like multiple step wizards. With the simple little example he went through tonight, EJB3 looks to be very very light indeed. The whole time I kept thinking, "These EntityBeans look like Hibernate POJOs." Which begs the question, "Why migrate to EJB3 if you're already using hibernate?"

And that's a fair question. There's not a lot of immediate value at first glance for sure. On the other hand, management of things like the SessionBeans and the like might be worth it. Integrated life cycle management from the container might be worth it. Overall, I didn't see a whole lot that says "Let's migrate!" However, EJB3 apps look more and more like how I've traditionally done Hibernate applications with some of the plumbing done for me. The one possible lack I see is the dependency injection being limited to EJBs only and no apparent way to plug in alternate implementations of those dependencies for testing. Have two DI mechanisms in place could get very messy, indeed. Perhaps the next version of the J2EE spec can address that. I haven't seen or used the new stuff enough to say whether that lack is real or perceived. Perhaps using the optional XML allows you to plug implementations. I'll have to wait and see.

Overall, I liked what I saw. EJBs certainly look a lot lighter than when I first saw 1.0 of the spec. And since EntityBeans are basically Hibernate POJOs (at least in JBoss' case), I'm halfway there.