From 7b143330734ed1cf4af886d729da394e6c8aafe3 Mon Sep 17 00:00:00 2001 From: Taylor Leese Date: Sun, 15 Jan 2012 15:40:05 -0800 Subject: [PATCH] make jappstart more up to date * use GAE 1.6.0 * use Spring 3.1 * use jquery 1.7.1 * no longer need user/pass bean post processer * various dependency updates to use latest versions --- README.md | 34 +++++++ filter-dev.properties | 2 +- filter-local.properties | 2 +- filter-prod.properties | 2 +- pom.xml | 45 +++++---- .../com/jappstart/model/auth/UserAccount.java | 2 +- .../UserPassAuthFilterBeanPostProcessor.java | 98 ------------------- .../WEB-INF/applicationContext-data.xml | 4 +- .../WEB-INF/applicationContext-security.xml | 11 +-- .../WEB-INF/applicationContext-service.xml | 2 +- .../webapp/WEB-INF/applicationContext.xml | 4 +- .../webapp/WEB-INF/dispatcher-servlet.xml | 6 +- src/main/webapp/WEB-INF/urlrewrite.xml | 2 +- 13 files changed, 75 insertions(+), 139 deletions(-) delete mode 100644 src/main/java/com/jappstart/service/auth/UserPassAuthFilterBeanPostProcessor.java diff --git a/README.md b/README.md index 2005f3b..faa1d07 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,40 @@ # Getting Started Guide jappstart is a Java framework for Google App Engine built on Spring, Spring Security, and Sitemesh. The project aims to be the starting point for Google App Engine Java applications. It's not a framework in the traditional sense -- rather it is designed to provide a solid foundation for GAE/Java applications that can be easily extended by developers. +# Features +* Appstats Support +* Google AJAX Library API (jQuery) +* Gravatar Integration +* JRebel Support +* Local Development Console Support (http://localhost:8080/_ah/admin) +* Maven Support + * CSS/JS minification via the yuicompressor-maven-plugin + * Uses the maven-gae-plugin +* Remote API/Bulk Loader Support +* Sitemesh Integration +* Spring 3 + * JPA support + * JSON/AJAX integration (Jackson) + * JSR-303 validation + * Localization support +* Spring Security 3 + * Authentication + * Expression based access control + * Fully integrated with the App Engine Datastore and Memcache + * Login/create account functionality with e-mail confirmation + * Remember Me + * Support for hierarchical roles +* Static Error Handler Support +* Task Queue Support +* URL Rewrite Integration + +# Versions +* Goole App Engine SDK for Java 1.6.0 +* jQuery 1.7.1 +* Maven GAE Plugin 0.9.2 +* Spring 3.1.0 +* Spring Security 3.1.0 + ## Configure Property Files Configure the following properties in `filter-local.properties`, `filter-dev.properties`, and `filter-prod.properties`. diff --git a/filter-dev.properties b/filter-dev.properties index ecd1397..a2eb853 100644 --- a/filter-dev.properties +++ b/filter-dev.properties @@ -7,6 +7,6 @@ google.jsapi.https.key=enterKey application.secureChannel=https application.hostname=enterId.appspot.com -jquery.ver=1.6.3 +jquery.ver=1.7.1 mail.fromAddress=do-not-reply@enterDomain.com diff --git a/filter-local.properties b/filter-local.properties index 541cd99..fa1c244 100644 --- a/filter-local.properties +++ b/filter-local.properties @@ -7,6 +7,6 @@ google.jsapi.https.key=enterKey application.secureChannel=http application.hostname=localhost:8080 -jquery.ver=1.6.3 +jquery.ver=1.7.1 mail.fromAddress=do-not-reply@localhost.com diff --git a/filter-prod.properties b/filter-prod.properties index 802f33c..57e86fb 100644 --- a/filter-prod.properties +++ b/filter-prod.properties @@ -7,6 +7,6 @@ google.jsapi.https.key=enterKey application.secureChannel=https application.hostname=enterDomain.com -jquery.ver=1.6.3 +jquery.ver=1.7.1 mail.fromAddress=do-not-reply@enterDomain.com diff --git a/pom.xml b/pom.xml index cde5c5b..07f3664 100644 --- a/pom.xml +++ b/pom.xml @@ -73,15 +73,15 @@ UTF-8 UTF-8 - 1.5.5 - 1.5.5 + 1.6.0 + 1.6.0 ${settings.localRepository}/com/google/appengine/appengine-java-sdk/${gae.version}/appengine-java-sdk-${gae.version} ${env.REBEL_HOME} 0.9.2 1.1.5 - 3.0.6.RELEASE - 3.0.7.RELEASE - 1.6.1 + 3.1.0.RELEASE + 3.1.0.RELEASE + 1.6.4 @@ -118,7 +118,7 @@ junit junit - 4.7 + 4.10 test @@ -162,13 +162,13 @@ org.hibernate hibernate-validator - 4.1.0.Final + 4.2.0.Final runtime cglib cglib - 2.2 + 2.2.2 runtime @@ -200,7 +200,7 @@ javax.mail mail - 1.4.1 + 1.4.4 provided @@ -279,7 +279,7 @@ org.tuckey urlrewritefilter - 3.1.0 + 3.2.0 javax.validation @@ -289,7 +289,7 @@ org.codehaus.jackson jackson-mapper-asl - 1.5.1 + 1.9.3 org.slf4j @@ -299,13 +299,18 @@ commons-codec commons-codec - 1.4 + 1.6 commons-lang commons-lang - 2.5 - + 2.6 + + + org.aspectj + aspectjweaver + 1.5.4 + @@ -409,7 +414,7 @@ org.apache.maven.plugins maven-war-plugin - 2.0.2 + 2.1.1 @@ -426,7 +431,7 @@ org.apache.maven.plugins maven-compiler-plugin - 2.1 + 2.3.2 1.6 1.6 @@ -435,12 +440,12 @@ org.apache.maven.plugins maven-javadoc-plugin - 2.7 + 2.8 org.apache.maven.plugins maven-deploy-plugin - 2.5 + 2.7 org.apache.maven.plugins @@ -450,7 +455,7 @@ org.apache.maven.plugins maven-release-plugin - 2.0 + 2.2.2 @@ -514,7 +519,7 @@ org.zeroturnaround jrebel-maven-plugin - 1.0.7 + 1.1.0 generate-rebel-xml diff --git a/src/main/java/com/jappstart/model/auth/UserAccount.java b/src/main/java/com/jappstart/model/auth/UserAccount.java index f09cc13..8a997c5 100644 --- a/src/main/java/com/jappstart/model/auth/UserAccount.java +++ b/src/main/java/com/jappstart/model/auth/UserAccount.java @@ -30,7 +30,7 @@ import javax.persistence.Id; import javax.persistence.OneToOne; -import org.springframework.security.core.codec.Hex; +import org.springframework.security.crypto.codec.Hex; import org.springframework.stereotype.Repository; import com.google.appengine.api.datastore.Key; diff --git a/src/main/java/com/jappstart/service/auth/UserPassAuthFilterBeanPostProcessor.java b/src/main/java/com/jappstart/service/auth/UserPassAuthFilterBeanPostProcessor.java deleted file mode 100644 index 8cd8b30..0000000 --- a/src/main/java/com/jappstart/service/auth/UserPassAuthFilterBeanPostProcessor.java +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright (C) 2010 Taylor Leese (tleese22@gmail.com) - * - * This file is part of jappstart. - * - * jappstart is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * jappstart is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with jappstart. If not, see . - */ -package com.jappstart.service.auth; - -import org.springframework.beans.factory.config.BeanPostProcessor; -import org.springframework.security.web.authentication. - UsernamePasswordAuthenticationFilter; -import org.springframework.stereotype.Service; - -/** - * The username password authentication filter bean post processor - * implementation. - */ -@Service -public class UserPassAuthFilterBeanPostProcessor implements BeanPostProcessor { - - /** - * The username parameter. - */ - private String usernameParameter; - - /** - * The password parameter. - */ - private String passwordParameter; - - @Override - public final Object postProcessAfterInitialization(final Object bean, - final String beanName) { - return bean; - } - - @Override - public final Object postProcessBeforeInitialization(final Object bean, - final String beanName) { - if (bean instanceof UsernamePasswordAuthenticationFilter) { - final UsernamePasswordAuthenticationFilter filter = - (UsernamePasswordAuthenticationFilter) bean; - filter.setUsernameParameter(getUsernameParameter()); - filter.setPasswordParameter(getPasswordParameter()); - } - - return bean; - } - - /** - * Sets the username parameter. - * - * @param usernameParameter the username parameter - */ - public final void setUsernameParameter(final String usernameParameter) { - this.usernameParameter = usernameParameter; - } - - /** - * Gets the username parameter. - * - * @return the username parameter - */ - public final String getUsernameParameter() { - return usernameParameter; - } - - /** - * Sets the password parameter. - * - * @param passwordParameter the password parameter - */ - public final void setPasswordParameter(final String passwordParameter) { - this.passwordParameter = passwordParameter; - } - - /** - * Gets the password parameter. - * - * @return the password parameter - */ - public final String getPasswordParameter() { - return passwordParameter; - } - -} diff --git a/src/main/webapp/WEB-INF/applicationContext-data.xml b/src/main/webapp/WEB-INF/applicationContext-data.xml index be246dd..62d8863 100644 --- a/src/main/webapp/WEB-INF/applicationContext-data.xml +++ b/src/main/webapp/WEB-INF/applicationContext-data.xml @@ -21,9 +21,9 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tx="http://www.springframework.org/schema/tx" xsi:schemaLocation="http://www.springframework.org/schema/beans - http://www.springframework.org/schema/beans/spring-beans-3.0.xsd + http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://www.springframework.org/schema/tx - http://www.springframework.org/schema/tx/spring-tx-3.0.xsd"> + http://www.springframework.org/schema/tx/spring-tx-3.1.xsd"> diff --git a/src/main/webapp/WEB-INF/applicationContext-security.xml b/src/main/webapp/WEB-INF/applicationContext-security.xml index 55fc494..62f8d1c 100644 --- a/src/main/webapp/WEB-INF/applicationContext-security.xml +++ b/src/main/webapp/WEB-INF/applicationContext-security.xml @@ -21,9 +21,9 @@ xmlns:beans="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans - http://www.springframework.org/schema/beans/spring-beans-3.0.xsd + http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://www.springframework.org/schema/security - http://www.springframework.org/schema/security/spring-security-3.0.xsd"> + http://www.springframework.org/schema/security/spring-security-3.1.xsd"> @@ -36,16 +36,11 @@ - + - - - - - diff --git a/src/main/webapp/WEB-INF/applicationContext-service.xml b/src/main/webapp/WEB-INF/applicationContext-service.xml index d61141a..e707bcb 100644 --- a/src/main/webapp/WEB-INF/applicationContext-service.xml +++ b/src/main/webapp/WEB-INF/applicationContext-service.xml @@ -20,7 +20,7 @@ + http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/src/main/webapp/WEB-INF/applicationContext.xml b/src/main/webapp/WEB-INF/applicationContext.xml index fb28ed5..fe14365 100644 --- a/src/main/webapp/WEB-INF/applicationContext.xml +++ b/src/main/webapp/WEB-INF/applicationContext.xml @@ -21,9 +21,9 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/beans - http://www.springframework.org/schema/beans/spring-beans-3.0.xsd + http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://www.springframework.org/schema/context - http://www.springframework.org/schema/context/spring-context-3.0.xsd"> + http://www.springframework.org/schema/context/spring-context-3.1.xsd"> diff --git a/src/main/webapp/WEB-INF/dispatcher-servlet.xml b/src/main/webapp/WEB-INF/dispatcher-servlet.xml index dd158b2..9274c2a 100644 --- a/src/main/webapp/WEB-INF/dispatcher-servlet.xml +++ b/src/main/webapp/WEB-INF/dispatcher-servlet.xml @@ -22,11 +22,11 @@ xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/beans - http://www.springframework.org/schema/beans/spring-beans-3.0.xsd + http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://www.springframework.org/schema/mvc - http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd + http://www.springframework.org/schema/mvc/spring-mvc-3.1.xsd http://www.springframework.org/schema/context - http://www.springframework.org/schema/context/spring-context-3.0.xsd"> + http://www.springframework.org/schema/context/spring-context-3.1.xsd"> diff --git a/src/main/webapp/WEB-INF/urlrewrite.xml b/src/main/webapp/WEB-INF/urlrewrite.xml index 24de659..71626b5 100644 --- a/src/main/webapp/WEB-INF/urlrewrite.xml +++ b/src/main/webapp/WEB-INF/urlrewrite.xml @@ -17,7 +17,7 @@ You should have received a copy of the GNU Lesser General Public License along with jappstart. If not, see . --> - + ^/appstats(.*)$