Welcome to another installment of This Week in Spring. In case you missed it last week, the vast majorty of the SpringOne2GX 2013 agenda has been published, so book now and get the early bird rate on the conference, and airfare! As usual, we've got a lot to cover this week, so let's get to it!
- Spring Batch lead Michael Minella announced Spring Batch 2.2.0 RC2. The new release is chalk full of great new features including support for the Spring Batch Java configuration API and a Spring Data GemFire
ItemReader
and ItemWriter
.
- Gary Russell just announced Spring Integration 3.0 milestone 2. Be sure to check out the new features and kick the tires!
- Join me for a webinar on Building REST-ful Services with Spring - June 13th, 2013. I'll discuss OAUTH, Spring MVC and Spring HATEOAS as it relates to REST.
- Rossen Stoyanchev's blogged about the upcoming support for WebSockets in Spring 4 and it looks very compelling!
- Gary Russell also just announced the Spring Integration MQTT extension adapter, milestone 1, that makes it easy to work with MQTT - a messaging technology that lends itself to lightweight messaging - from Spring Integration.
- Oliver Gierke has written up a great response to the question, how do I return a Spring Data page as JSON on Stack Overflow.
- Long-time readers of this roundup will know about Thymeleaf, the templating engine that breathes new life into your web application view templates and that works really well with Spring. The first, stable 2.0.0 version of Thymeleaf-testing has just been released.
- Joris Kuipers, on the Trifork blog, has announced a new set of macros for doing form inputs with Spring applications using Freemarker, an alternative - and very powerful - templating engine.
- Oleg Tsal-Tsalko put together a talk on the new bits in Spring 4. Nicely done, Oleg!
- Johnathan Mark Smith is back at it again, this time with a video on how to do Java configuration with Spring. Check it out!
- Maciej Walkowiak put together a great post on how to audit entities using Spring Data MongoDB.
- The poorly-named Java2J2EE blog has a great, short-and-sweet post on how to setup JPA and Spring MVC with Spring's Java configuration style. I would however discourage users from calling the lifecycle methods on a Spring
FactoryBean
directly, and instead choose to dereference the configured result:
@Bean public EntityManagerFactory emf(){
LocalContainerEntityManagerFactoryBean lcemfb = ..
return lcemfb;
}
@Bean public PlatformTransactionManager transactionManager(){
EntityManagerFactory emf = emf().getObject();
return new JpaTransactionManager( emf );
}