views:

74

answers:

2

Does Google Apps support the Spring framework?

+3  A: 

If by saying "Google Apps" you're in fact talking about "Google App Engine" (as the tag suggests), then, "mostly". See here (I'm pointing to the cached page because the "Will it Play in App Engine" google groups post seems to be just spinning interminably). Quoting:

Edit: per @hleinone's comment below, the "mostly" answer has now become "yes" -- Spring Security 3.x runs "out-of-the-box" on Google App Engine (haven't tried it personally, I'm just trusting the comment in question!). [[end-of-edit]]

Spring MVC
Version: 2.5.6
Status: COMPATIBLE

To see Spring's MVC framework running on App Engine, check out the autoshoppe sample application. If you're using Spring forms (e.g. using the spring-form.tld tag library and subclassing SimpleFormController), you will need to register custom editors for your properties. This is covered in http://groups.google.com/group/google-appengine-java/browse_thread/thread/d93fd7385bf85bf7.

Spring ORM
Version: 2.5.6
Status: COMPATIBLE

To get Spring working with the App Engine-provided JPA interface, follow the instructions at http://objectuser.wordpress.com/2009/05/19/spring-jpa-in-google-app-engine/, which discusses a workaround to the dependency on javax.naming needed for @PersistenceContext. A more complex workaround is available at http://groups.google.com/group/google-appengine-java/browse_thread/thread/187d41712ec1d394.

Spring Security
Version(s): ?
Status: SEMI-COMPATIBLE

To work around a ClassNotFoundException, you can use a re-compiled version of the library which adds a StringInsensitiveComparator class -- the download is provided at http://www.google-app-engine.com/blog/post/Spring-security-fix-for-google-app-engine.aspx. See http://www.dotnetguru2.org/bmarchesson/index.php?p=1100 for tips on how to get Spring Security running with App Engine and GWT (in French). See http://groups.google.com/group/google-appengine-java/browse_thread/thread/964e7f5e42840d9c for discussion on the integration.

Alex Martelli
Spring Security 3.x will run there out-of-the box. Those instructions are for the 2.x branch.
hleinone
@hleinone, excellent news, thanks! Good to know.
Alex Martelli
A: 

what I heard is, the spring startup time alone makes it unfit for google app engine.

the real problem is, spring is bought by VMWare, for their own cloud strategy. They are in direct competition with google app engine. so don't expect the situation is going to get any better.

irreputable
The fact that Spring Security 3.x now works out of the box on App Engine, while 2.x required tinkering and only worked partially even so (as @hleinone pointed out on a comment to my answer) contradicts this thesis pretty strongly, doesn't it?
Alex Martelli
Alex, spring absolutely has a delicate PR job to do. after all the developer mindshare is their biggest asset. But they are snickering secretly when your spring app bombs in google app engine (for which usually google is blamed, fairly)
irreputable
The problem with startup time makes almost any complex web framework unfit for App Engine. I also don't see VMWare as a threat, Spring is after all open source.
hleinone