As the first milestone of the Spring Data release train Codd has now cooled down a little bit, I'd like to highlight some of the new features shipped with the MongoDB module.
Sometimes it can be pretty complicated to define arithmetic expressions within MongoDB aggregation framework projections.
Assume a part of an aggregation for an order is the gross price of it, effectively calculated using the following formula:
(netPrice * discountRate + fixedCharge) * taxRate. With a discount rate of 0.8, a fixed charge of 1.2 and a tax rate of 1.19, the according
DBObject to encode this formula with the MongoDB aggregation framework looks as follows:
With the recent RC2 release of Spring Framework 4.0; and GA due before the year's end, here is a little teaser of some of the changes that should improve your life if you work with Java generic types.
Spring has had pretty good Java generics support for a while. For example, with version 3.2 you can easily inject all beans of a specific type into a generic
List just by using the
@Autowired private List<MyType> beans; // all beans that extends MyType will be injected
Spring's conversion service, binding system and Web MVC framework are all 'generic aware' and there are also the handy
GenericTypeResolver utility classes that you can use in your own code.
Spring 4.0 RC2 has been released and is now available from the SpringSource repository.
This will be the final release candidate before GA, so please give it a try and let us know if you find any issues.
If you are Maven user you may be interested in the new "bill of materials" POM that we have published with this release. You can import the
spring-framework-bom project in your dependency management section to ensure that you get consistent Spring Framework dependencies. This is particularly useful when you work with other projects that may have transitive dependencies to earlier versions of Spring.
Welcome to another installment of This Week in Spring! This week I'm in Sofia, Bulgaria, talking to the great folks at the amazing Java2Days conference. This is my 5th year here and it's been an amazing show every time!
- Spring Integration 3.0 RC1 is now available! The new release features many nice, new features including a file-tailing inbound adapter, a JMX inbound adapter, redis queues, and much more.
- Don't miss Matt Stine as he discusses Spring with Immutability on Dec 10th!
- The replay of my webinar from last week, Have You Seen Spring Lately?, is now available online! The talk is a sort of introduction to the Spring IO platform, introducing many of the awesome technology released since the Spring team became part of Pivotal. It also introduces some new tech inside of Spring 4, as well as some oldies-but-goodies like Spring Social and Spring Batch, which continue to grow.
- Ben Hale's epic talk from SpringOne2GX 2013 which introduces REST API Design is now available online.
- Looking to get started quickly with Spring and application development? Check out this webinar replay of the SpringOne2GX 2013 talk introducing Spring Boot!
- InfoQ has a great post on how to use Spring Boot in conjunction with the Aerospike database
- Want to integrate a custom single-sign on authentication provider using Spring Security? This Stack Overflow discussion on integrating a custom single sign-on provider is very helpful! (I got this from the always-useful @SpringTip Twitter account)
- Xavier Padró's put together a nice post on how Spring Integration error handling works.
- Sergi Almar (@SergiAlmar) has put together a really great presentation on using Spring 4's websocket support. Definitely check it out!
- Also from @SpringTip, a great Stack Overflow post on how to filter database records using Spring Data REST and Spring MVC
- Nicolas Frankel is back at it again, this time with a nice post on using Spring Data SOLR
Speakers: Dr. David Syer and Phil Webb
Are you an impatient programmer who wishes the keyboard could keep up with you? If you've ever wished Java and Spring could do more to keep up, then this is the place to be. We present Spring Boot, a toolkit and runtime platform that will get you up and running with Spring-powered, production-grade applications and services faster than you believed possible. The goals are:
- Radically faster and widely accessible getting started experience for Spring development
- Be opinionated out of the box, but get out of the way quickly as requirements start to diverge from the defaults
- Provide a range of non-functional features that are common to large classes of projects (e.g. embedded servers, security, metrics, health checks, externalized configuration)
- First class support for REST-ful services, modern web applications, batch jobs, and enterprise integration
- Applications that adapt their behavior or configuration to their environment
- Optionally use Groovy features like DSLs and AST transformations to accelerate the implementation of basic business requirements
Speaker: Ben Hale
As data-driven applications become more widespread, the services that provide the data are becoming more critical. Most commonly these data services are exposed via REST-ful APIs. This session describes what exactly makes a service REST-ful, how to implement a REST-ful API using Spring, and how to test that API.
Learn more about REST at http://www.spring.io
http://projects.spring.io/spring-framework/ (spring MVC's REST controller)
http://projects.spring.io/spring-hateoas/ (Hypermedia Support)
Speaker: Josh Long
It's been an amazing year for Spring! 2013 saw the Spring family join Pivotal where - along with Cloud Foundry and our data driven technologies (the Pivotal HD Hadoop distribution, the GemFire data grid, and the RabbitMQ message broker) - Spring supports today's application workloads and profiles. Today's Spring embraces Java 8, Scala, Groovy, provides a best-in-class REST stack, supports the open web, mobile applications, big-data applications and batch workloads. Today's Spring is easy to get started with, easy to learn, and embraces conventions over configuration. Today's Spring is part of the Spring.IO platform. Today's Spring is...Pivotal. Join Spring developer advocate Josh Long as he re-introduces you to today's Spring, a Spring you may not have seen yet.
We are extremely pleased to announce that Spring Integration 3.0.0.RC1 is now available in the Spring Milestone Repo
This release uses Spring Framework 3.2.5 by default but is also compatible with Spring 3.1.x and 4.0.x.
The release notes, showing changes since milestone 3, are available here.
Spring Framework 4.0 has a new
spring-messagingmodule that contains a number of key abstractions from Spring Integration.
Spring Integration 3, while being compatible with Spring Framework 4, does not depend on it, and does not use these classes, so that it can also be used with Spring Framework 3.2 and 3.1.
We are planning to release Spring Integration 4 in early 2014, which will be completely compatible with (and require) Spring Framework 4, utilizing its
spring-messagingmodule as a foundation. A milestone will be available very soon after Spring Framework 4 is released.
Welcome to another installment of This Week in Spring! This week I'm in Gothenburg, Sweden talking to developers at the JDays 2013 conference about Spring. What a great crowd and a great reception. It's been a blast, but I'm headed home soon to scarf down some turkey with friends and family! If you celebrate the US Thanksgiving holiday, let us be the first to wish you a very happy holiday!
- Spring Batch lead Michael Minella has announced that Spring Batch 2.2.3 is now available!
- Spring Data lead Oliver Gierke has announced the first milestone of the next Spring Data release train named Codd. This release welcomes two new members to the train: the Spring Data Solr community project as well as Spring Data REST. Awesome!
- Dr. Mark Pollack's session introducing Spring XD from QCon SF 2013 is now available! (This is the first thing I watched out of all the content in this week's roundup. It's awesome!)
- Did you miss the webinar - Dynamic Routing at 1 Million Messages per Second with Spring Integration - that Incept 5 CEO and technology rockstar John Davies and I put on last week? Have no fear, it's online now for your consumption!
- On December 3, Reactor lead Jon Brisbin will introduce the Reactor project, hot on the trail of its recent 1.0 release!
- On December 10, 2013, Matt Stine will give the webinar, Spring with Immutability which introduces how Spring developers can most profit from item #15 in Josh Block's canonical tome on Java, Effective Java: "minimize mutability."
- A week or so ago I sat down with Oracle's epic Java ninja Stephen Chin to talk Spring Boot on his live Nighthacking series The whole thing's about 20 minutes, so check it out!
- Gunnar Hillert has been busy! He just updated the Spring Batch and Spring Integration sections with new videos and resources for the respective projects! Check them out!
- I'll be in the Los Angeles area on December 11th at a meetup being held by Disney and I'll be talking about any and all things Spring. Come say hi, take a load off and bring your questions! It's sure to be a lot of fun. I want to thank Disney's Synergy Labs in Glendale, CA for having me!
We are pleased to announce that Spring Batch 2.2.3.RELEASE is now available via Maven Central, Github and the SpringSource download repository. This is the 3rd maintenance release for the 2.2.x branch of Spring Batch and addresses a number of bugs and documentation updates. Many thanks to all of those who submitted the many pull requests that went into this release.
Spring Batch Home | Source on GitHub | Reference Documentation
We look forward to your feedback in the forum and issue tracker.