Sunday, January 25, 2015
Spring by Example (1.5)
The Spring by Example site has been updated to use Spring Framework 4.1.x. Most other libraries have also been upgraded. Some major ones are Spring Integration 4.1.2, Spring Security 3.2.5, Spring Data JPA 1.7.1, and Hibernate 4.3.8.
Monday, March 17, 2014
Spring by Example (1.4)
The Spring by Example site has been updated to use Spring Framework 4.0.x. Most other libraries have also been upgraded. Some major ones are Spring Integration 3.0.1, Spring Security 3.2.2, Spring Data JPA 1.5.0, and Hibernate 4.3.4.
The GWT and Spring dm Server examples had not been updated since Spring 2.5.x and have been removed.
Saturday, September 28, 2013
Spring by Example (1.3)
The site has been updated to use Spring Framework 3.2.x. The Contact Application has been updated to reference SBE REST Modules, which I will write about shortly (available on Spring by Example's GitHub). The modules are to help abstract some of the REST classes in the Contact Application and also to allow annotations on an interface to generate the REST client & controller. Two smaller items are that the Contact Application has a better example of a production ready DB connection pool configuration, and it's using Jackson 2.0 for JSON. Below are the Contact Application modules.
- DAO - DB Schema, JPA Entities, Spring Data JPA repositories.
- Web Service Beans - JAXB beans generated from XSDs.
- Services - APIs use JAXB beans and Dozer is used to convert between this beans and the JPA entities. Security and transactions are configured in this layer.
- REST Services - The module has clients & controllers, as well as their Spring configurations. JSON and XML views are supported for requests.
- Webapp - The webapp as a standard JSP UI, Sencha ExtJS, and also a Sencha Touch UI.
- Test - The DAO, Services, and REST Services all have an abstract test class for each module that each test extends. This way within each module, all tests have a shared context so Spring only has to load once. All of these tests use an in memory database and the REST Services have an embedded jetty server. REST Services tests can be run with clients using JSON or XML for marshalling.
Sunday, November 11, 2012
Spring by Example (1.2.2)
A new multi-module Contact Application has been added. It is comprised of the following modules:
- DAO - DB Schema, JPA Entities, Spring Data JPA repositories.
- Web Service Beans - JAXB beans generated from XSDs.
- Services - APIs use JAXB beans and Dozer is used to convert between this beans and the JPA entities. Security and transactions are configured in this layer.
- REST Services - The module has clients & controllers, as well as their Spring configurations. JSON and XML views are supported for requests.
- Webapp - The webapp as a standard JSP UI, Sencha ExtJS, and also a Sencha Touch UI.
- Test - The DAO, Services, and REST Services all have an abstract test class for each module that each test extends. This way within each module, all tests have a shared context so Spring only has to load once. All of these tests use an in memory database and the REST Services have an embedded jetty server. REST Services tests can be run with clients using JSON or XML for marshalling.
Labels:
jaxb,
jpa,
json,
spring data jpa,
spring mvc,
spring security
Friday, August 24, 2012
Spring by Example (1.2.1)
Two new examples have been added on Spring Data JPA. One basic example showing how to create and use a repository, along with creating some basic custom queries. And another example showing how to use Spring Data JPA auditing with custom field mappings. All of the main webapps using JPA were updated to use Spring Data JPA instead of custom repository classes. Also, all of the JPA examples were upgraded to use Hibernate 4.1.
Spring JavaScript was removed from the Spring Web Flow examples. There were some issues around the AJAX tiles usage.
Updated Webapps
- Simple Spring MVC Form Annotation Configuration Webapp
- Simple Spring Security Webapp
- Simple Spring Web Flow Webapp
- Spring Web Flow Subflow Webapp
- Simple Flex Webapp
Friday, August 17, 2012
Spring by Example Update (1.2)
All examples have been upgraded to Spring 3.1 and Java 6. The exceptions are that the GWT examples have been removed, and Spring dm Server (OSGi) examples have not been updated but are still available for reference.
All modules have also been upgraded to Spring 3.1 and Java 6. Maven group and artifact IDs have been changed back to standard Maven naming and also all project dependencies (no OSGi ones in standard examples).
Spring by Example JDBC has been removed and all projects (except for OSGi ones) have been changed to use the Spring JDBC Custom Namespace.
The Spring by Example repository has been moved to GitHub. New git Spring by Example Repository. The old Subversion repository can still be found here.
Thursday, December 24, 2009
Spring by Example Update (1.1)
Almost all examples have been upgraded to Spring 3.0 (except for the Aspect LTW example, GWT ones, and OSGi ones). Also a new Grails example has been added.
The web examples in particular have all been upgraded (except for GWT/OSGi) to use the new Spring MVC Namespace. Keith Donald, from SpringSource, wrote a great blog going over some of the new Spring MVC simplifications in MVC Simplifications in Spring 3.0. All the webapps were updated to use Spring MVC best practices as much as possible, except their URLs aren't currently RESTful. That will be changed as soon as soon as possible.
All modules have been upgraded to Spring 3.0 and Maven group and artifact IDs have been changed to follow Spring naming conventions (ex: custom-thread-scope --> org.springbyexample.threadscope).
The Spring 2.5.x version of the site and all examples are still available. It's available at Spring by Example 2.5.x, which is version 1.0.3.
Sunday, May 31, 2009
Spring by Example Update (1.03)
Two new examples were added. One is the Simple Flex Webapp and the other is Simple Spring Integration. Also the setup in the appendix was updated to have a section configuring SpringSource Tool Suite. Besides getting extra features like tutorials, tips when using Spring, and access to the Spring knowledge base for diagnosing stack traces, you also get a reduced installation since it comes with other plugins like for AspectJ and Maven.
The Simple Flex Webapp, which is based on Simple Spring MVC Form Annotation Configuration Webapp but replaces the HTML search page with a Flex application. It uses Spring BlazeDS Integration (verson 1.0.0.RC2) for remoting. The Flex app also has logging, internationalization in sync with the server side locale, and uses the MVC framework Cairngorm.
Simple Spring Integration uses Spring Integration to process a book order and appropriately route the message depending on if it's a pickup from the store or it should be delivered.
Wednesday, April 8, 2009
Spring by Example Update (1.02)
Spring by Example Utils' HttpClientTemplate, HttpClientOxmTemplate, and SolrOxmClient are used for making different Apache Solr client requests. Solr provides an XML based API over HTTP to the Apache Lucene search engine. Spring OXM is used for marshalling and unmarshalling requests using a custom marshaller made with dom4j.
The SolrOxmClient was added to the Spring by Example Utils module. The SolrOxmClient provides for easier client communication with Apache Solr. It marshalls/unmarshalls searches and updates to and from a JavaBean. It also allows calls to commit, rollback, and optimize. It is built on top of HttpClientTemplate and HttpClientOxmTemplate.
The SolrOxmClient was added to the Spring by Example Utils module. The SolrOxmClient provides for easier client communication with Apache Solr. It marshalls/unmarshalls searches and updates to and from a JavaBean. It also allows calls to commit, rollback, and optimize. It is built on top of HttpClientTemplate and HttpClientOxmTemplate.
Tuesday, March 10, 2009
Spring by Example Update (1.01)
A preface, introduction to Inversion of Control (IoC) and Dependency Injection (DI), and basic XML configuration in Spring were added to the beginning of examples.
Enhancements to Valang based on Spring Modules Validation Version 0.9 was added to the module library. When changes are complete, the code will be offered back to the Spring Modules project. There are a number of enhancements to the Valang part of the project. A few key enhancements are where clause support, enum support, and a number of performance enhancements (such as bytecode generation). Currently none of the enhancements were added to the custom JSP tag that generates JavaScript.
Also the 'Simple Spring MVC Form Annotation Configuration Webapp' was updated to follow the best practices for Spring MVC annotation based configuration presented by Rossen Stoyanchev at SpringOne. Rossen along with Keith Donald and the rest of the web team helped put together what they consider best practices for using Spring MVC annotations based on their experience and interaction with many use case scenarios from Spring users. Thanks to Rossen Stoyanchev for helping with this. The example was also updated to use JPA.
Enhancements to Valang based on Spring Modules Validation Version 0.9 was added to the module library. When changes are complete, the code will be offered back to the Spring Modules project. There are a number of enhancements to the Valang part of the project. A few key enhancements are where clause support, enum support, and a number of performance enhancements (such as bytecode generation). Currently none of the enhancements were added to the custom JSP tag that generates JavaScript.
Also the 'Simple Spring MVC Form Annotation Configuration Webapp' was updated to follow the best practices for Spring MVC annotation based configuration presented by Rossen Stoyanchev at SpringOne. Rossen along with Keith Donald and the rest of the web team helped put together what they consider best practices for using Spring MVC annotations based on their experience and interaction with many use case scenarios from Spring users. Thanks to Rossen Stoyanchev for helping with this. The example was also updated to use JPA.
Sunday, February 1, 2009
Sunday, January 11, 2009
Spring by Example Update (0.98-0.99)
The Spring by Example 0.98 update added a Spring dm Server example for a very simple Spring MVC application, and the 0.99 update added a JMS example sending messages with a JMS template and receiving them with a JMS listener.
Sunday, December 14, 2008
Spring by Example Update (0.95-0.97)
In these updates, three new examples were added (links below), there were some miscellaneous typos fixed, and also the Simple Spring Web Services using JAXB for Marshalling was updated to use non-deprecated dynamic WSDL generation classes and to use the JAXB Fluent API (which is less verbose than the standard one).
Thursday, November 20, 2008
Spring by Example Update (0.94)
There isn't any change in the content, but the URLs generated aren't numbered anymore. Before if an article was inserted, it would bump all the other numbers up. Now the example articles will be easy to bookmark through a symlink from version to version as they're updated. So instead of '/static/0.93/html/ar21.html' for Dynamic Tiles 2 Spring MVC Module the url is now '/static/0.94/html/dynamic-tiles-spring-mvc-module.html' or through the symlink to the latest version it's '/static/examples/html/dynamic-tiles-spring-mvc-module.html'.
Tuesday, November 18, 2008
Spring by Example Update (0.93)
The site's static examples have just been updated to version 0.93. It's mainly some minor updates correcting errors again. A note was added about classloading issues when using the custom ServletContext scope. Also, Barry M. pointed out that the Dynamic Tiles 2 Spring MVC Module had a typo for the tilesBodyAttributeName default value. It said 'body' instead of 'content'. Thank you Barry!
Sunday, October 26, 2008
Spring by Example Web Module GWT & Comet Support
The Spring by Example Web Module has added a Spring GWT Controller for standard GWT usage and also Spring Bayeux integration for using Comet on Jetty.
Wednesday, October 22, 2008
Spring by Example RSS Feed
The Spring by Example RSS feed has been updated to a new url, which is http://www.springbyexample.org/feed/. Before the feed was generated by the TWiki so it wasn't also including the static examples.
Spring by Example Update
The site's static examples have just been updated to version 0.91. It's mainly some minor updates correcting errors, adding a setup appendix that is more detailed than the old setup, and updating the articles to point to the new setup appendix. Also a new custom scope module for the ServletContext has been added.
Custom ServletContext Scope Module
A new module has just been posted. It's a custom scope for a ServletContext. Typically a Spring singleton would be adequate for a single application, but this could be used to share a bean across multiple web applications if the servlet container has cross context support.
<bean class="org.springframework.beans.factory.config.CustomScopeConfigurer">
<property name="scopes">
<map>
<entry key="servletContext">
<bean class="org.springbyexample.web.context.ServletContextScope" />
<property name="context" value="/advanced-form" />
</bean>
</entry>
</map>
</property>
</bean>
<bean class="org.springframework.beans.factory.config.CustomScopeConfigurer">
<property name="scopes">
<map>
<entry key="servletContext">
<bean class="org.springbyexample.web.context.ServletContextScope" />
<property name="context" value="/advanced-form" />
</bean>
</entry>
</map>
</property>
</bean>
Saturday, October 11, 2008
Commons Configuration with Spring Modules
Subscribe to:
Posts (Atom)