The Spring Blog

Engineering
Releases
News and Events

Building RabbitMQ apps using Python

RabbitMQ is a powerful messaging broker based on the Advanced Message Queueing Protocol (AMQP). Thanks to the neutral nature of the AMQP spec, it is easy to connect to it from many platforms, including Python. In this blog entry, we will:


  • Create a simple stock ticker Python application

  • Create a brokerage Python application that decides when to buy and sell.

  • Compare pika, an AMQP library created by the RabbitMQ team, with py-amqplib.


http://github.com/gregturn/amqp-demo instructions for your platform
Read more...

Simplified Spring Security with Grails

Spring Security is a powerful library for securing your applications that comes with a bewildering number of options. Based on Spring, it can be readily integrated into a Grails application. But why not save the hassle and use the new improved Grails plugin?

The plugin has gone through several evolutionary stages that started with the Acegi plugin. Its most recent incarnation is a complete rewrite for Spring Security 3 and Spring 3. One of the results of this is that the plugin will only work with Grails 1.2.2 and above. Another significant change is that there is no longer just one Spring Security plugin: some features have been broken out into optional plugins. So now you only include the features you need in your application.

Read more...

Virgo Milestone M03 Ships

Virgo 2.1.0.M03-incubator is available from the Virgo website. The changes include:

  • Further performance improvements, especially for Windows users.
  • Update the version of Logback to 0.9.24 and SLF4J to 1.6.1
  • Minor bug fixes

The performance improvement was achieved by adjusting the log level of entry exit tracing.

As a result of the new version of Logback the syntax of the configuration file ‘serviceability.xml’ has changed slightly. More information can be found here.

We have now published a plan outline for the future of Virgo so you have a better idea of where we are going.

Read more...

Hyperic Broadens vSphere Support through vCenter APIs in Version 4.4

SpringSource Hyperic 4.4 was released earlier this week that brings enhanced management of VMware virtualized environments through integration with VMware vCenter.  While Hyperic has long had support for VMware technologies (a.k.a. VMware Infrastructure or VI), the availability of the VI Java API (http://vijava.sf.net) made our jobs much easier, because the power SDK streamlined how a Java application can interact with VI back then.  By adopting the VI Java API, we were able to keep up with VMware’s evolution easily from VI to VMware vSphere, as it is known today.  This also allowed us to communicate directly with both ESX and ESXi servers without differentiation or modification as those technologies evolved.  As VMware became an increasingly larger component of the datacenter infrastructure, it began to seem incomplete to manage each ESX and ESXi server as a separate entity while it is a member of a larger infrastructure.  In fact, VMware moved forward with overlaying technologies over the physical hardware resources to bind them together in a holistic environment called vSphere.  The management of VMware vSphere is handled by a software initially named VirtualCenter, and is now dubbed vCenter.  Being part of the VMware family, we began to realize that our VMware support needed to evolve beyond simply leveraging an easy-to-use SDK.  As we learned more about the latest vSphere technology from our new VMware colleagues, we realized that we needed to rethink how we support the monitoring and performance management of vSphere environments.  Hyperic 4.4 is the result of that re-architecture of Hyperic’s VIM plugin, which has been deprecated in favor of a new vSphere plugin.  It makes much more sense to use VI Java to invoke the vCenter APIs, which provided much more functionalities than ESX or ESXi and can query for the data aggregated at the vCenter server.  Certainly, there is an obvious benefit to consolidating the number of vSphere connections to a single one.  Furthermore, there is the newer ability to perform and track vMotion in vCenter that you would not be able to do elsewhere.  The new level of vSphere integration through vCenter yields many new benefits and features in Hyperic 4.4, some of which include:

Read more...

Spring Web Flow 2.2.0.M1 Released

I’m pleased to announce the first milestone of Spring Web Flow 2.2 is now available for download. The release is also available through the Maven milestone repository at http://maven.springframework.org/milestone. As with Spring Web Flow 2.1, this release requires JDK 1.5, Spring 3 and Spring Security 3.

The main focus of the release is to address the needs of JSF users by extending the list of supported JSF 2 features. Not long ago Web Flow 2.1 made it possible to use JSF 2 dependencies without the need for the separate Sun Facelets jar that is commonly used with JSF 1.2 today.

Read more...

Spring GemFire 1.0.0.M1 released for Java and .NET

I am happy to announce the first milestone release of the Spring GemFire project, the newest member in the Spring family. Spring GemFire (for short SGF) brings the Spring concepts and programming model to GemFire, SpringSource’s distributed data management platform. The release is available for both Java and .NET.

The features in 1.0.0.M1 include:


  • declarative dependency injection style configurations for the GemFire infrastructure (such as Cache, Region, Interest, etc)

  • exception translation to Spring’s portable DataAccess exception hierarchy

  • Template and callback support for easy native API access

  • transaction management support

  • Spring-backed wiring for GemFire managed objects

  • auto-generation of non-reflection based Instantiators

Read more...

Spring Security in Google App Engine

Spring Security is well-known for being highly customizable, so for my first attempt at working with Google App Engine, I decided to create a simple application which would explore the use of GAE features by implementing some core Spring Security interfaces. In this article we’ll see how to:


  • Authenticate using Google Accounts.

  • Implement “on-demand” authentication when a user accesses a secured resource.

  • Supplement the information from Google Accounts with application-specific roles.

  • Store user account data in an App Engine datastore using the native API.

  • Setup access-control restrictions based on the roles assigned to users.

  • Disable the accounts of specific users to prevent access.

Read more...

GORM Gotchas (Part 3)

It’s great to hear that people are finding these articles useful, so it’s with great pleasure that I add another to the series. This time I’m going to talk about associations again, but with the focus on when they are loaded into memory.

Update 2 Aug 2010 I have added more information on eager fetching with one-to-many relationships because there are some issues you need to be aware of.

It's cool to be lazy

One of the first things people learn about GORM relationships is that they are loaded lazily by default. In other words, when you fetch a domain instance from the database, none of its relations will be loaded. Instead, GORM will only load a relation when you actually use it.

Read more...

Spring MVC 3 Showcase

Since the big Spring 3 release last year, I’ve been working on a number of application development projects and extracting “showcases” of various framework features. These “showcases” are not reference applications or tutorials, they’re more like acceptance tests for specific framework capabilities. After seeing a showcase, you should have a good idea of what the technology can do.

The first showcase I’ve put together is for Spring MVC 3, our web framework. It includes a sample project, along with a supporting slide presentation and screencast. After digging in, you should have a good understanding of what Spring MVC can do and get a feel for how easy it is to use.

Read more...

Grails tooling improvements in SpringSource Tool Suite 2.3.3 M2

The recently released STS 2.3.3 M2 introduced a series of enhancements to our Grails support for Eclipse. In this article I’ll be discussing what you can expect to find if you try it out (grab it here: SpringSource Tool Suite).

Groovy-Eclipse


Eclipse-Con 2010 New and Noteworthy

  • refactoring support: now supporting extract method, extract constant, extract local variable
  • improvements in code formatting and indentation


Getting a new perspective


Window>OpenPerspective>Grails

Grails Perspective

Also, related to plugins, we have a new Grails Plugin Project wizard. This is very similar to the Grails Project Wizard, but instead of running create-app, it will cause the create-plugin command to run. With this new wizard and the new support we have for local (inplace) plugins, it is much easier to develop your application following a plugin oriented architecture.

Read more...