Tag Archives: ioc

Using EJB3 with Spring

In my previous entry, I talked about how you could easily use Spring from within EJB 3 beans, thanks to the magic of EJB interceptors. But what about the other way? How do you use EJB 3 from Spring?

*Update:* It looks like the Interface21 guys have had similar ideas – check out Project Pitchfork

Continue reading

Using Spring with EJB 3

Back when we were planning the migration to Glassfish, I realised we would have two dependency-injection frameworks in use – EJB 3 and Spring. For obvious reasons, I wanted to know more about how these would interact. At the time (last July), I couldn’t find anyone who had used EJB 3 and Spring together – even Ben Alex from Interface21 hadn’t come across it. Six months later, and I still haven’t heard of anyone using Spring _from_ EJBs. Except for us.

Continue reading

Roll-Your-Own IoC with Struts

IoC, aka dependency injection, is the current trend. The idea is simple: create your normal class, and rather than going and fetching things you might want (like datasources, factories, and so on), get them given to you instead. This greatly facilitates things like unit testing, because you’ve got a lot less dependencies to set up.

Struts uses Actions to drive an application. This describes a way to use dependency injection techniques with Struts.
Continue reading