tags:

views:

112

answers:

2

I'm building a small experimental application using BlazeDS AMF, Java and Hibernate, and I was wondering if I could at all benefit from using the Spring Framework?

Since I'm using BlazeDS, that acts as my controller, but I might use something like Aspect Oriented Programming for example for logging.

What other benefits could I get from using Spring with my AMF (Action Message Format) service based RIA?

Thanks.

+2  A: 

I think the answer is an emphatic "yes".

Spring is a solid framework that will help you use Hibernate better. Your application will be layered using the Spring recommended idiom. You'll have all the benefits of IoC and AOP and solid code. You'll have a nicely decoupled application when you're done. If you write Spring "contract first" web services you'll have the user and service tiers nicely delineated.

As I understand Blaze DS + Spring, it's just another servlet that they provide, you configure, and map requests to handlers. It's very similar to their MVC architecture. My advice would be to do one thing at a time. Don't take on everything at once. Use Spring JDBC before tackling Hibernate. Don't worry about AOP at first.

duffymo
Thanks for that! I have to say, I find Spring intimidating, I kinda do not know where to start.As you said, Inversion of Control / Dependency Injection is exactly what I need, as well as AOP. And since I strongly advocate decoupling, I'm going to need and implement some kind of framework, and so far I think it's going to be Spring.I'll probably look into the BlazeDS + Spring integration project on SpringSource, but then again, it's all huge, but THEN again, I'm going to climb this mountain!!!Thanks for your reply!
Joe Zephyr
Spring can look scary because it's so comprehensive. You can start small, though. Read the first chapter of the reference docs, or get the Pro Spring brook. It's really quite straightforward.
skaffman
+1  A: 

The other option to consider is GraniteDS, an open-source re-implementation of BlazeDS, with Spring support baked in.

skaffman
Thanks for your reply, I'll definitely take a peek at GraniteDS!
Joe Zephyr