Monday, May 15, 2006

JavaOne: Spring 2.0

I met with Rod Johnson this morning, and he demonstrated Spring's new first class support for custom scopes (no more AOP/proxy hacks!). That alone justifies taking Spring for another spin, but he also showed off their new support for injecting constructor parameters by name, i.e. no more worrying about parameter indices or mixing up parameters of the same type. You can capture the parameter names by compiling in debug mode or using a special tool at compile time. Let's see you do that with plain Java. Last but not least, keep an eye out for Spring's new plain Java bean definitions. The Java definitions play nicely with Spring XML which means you can mix and match Java and XML using the best option for the task at hand. For example you might use plain Java to declare that a given class has a dependency on a data source and XML to configure the data source itself. Thanks, Rod.

7 Comments:

Blogger Eugene Kuleshov said...

He he. I guess that makes them another candidate for ASM users page... :-)

Anyways, any pointers to the code or examples for scoped beans?

6:16 PM  
Blogger Bob Lee said...

Rod checked in an example unit test this morning. I'm sure they have some docs coming soon.

6:22 PM  
Blogger Eugene Kuleshov said...

Found it already. Not a rocket science after all. :-)

7:21 PM  
Anonymous Jason Carreira said...

So has Rod converted you to the One True Path (tm)?

;-)

12:49 PM  
Blogger Bob Lee said...

We're getting there. I'm still not crazy about the implementation, but I guess I can always fix it.

12:54 PM  
Blogger Graeme Rocher said...

Good Lord, next step is to convert you to a Groovy user and then we'll really see some progress ;-)

2:32 PM  
Blogger Bob Lee said...

Ha ha. Don't hold your breath, Graeme. ;)

3:29 PM  

Post a Comment

Links to this post:

Create a Link

<< Home