Commit Graph

158 Commits

Author SHA1 Message Date
Chris Beams 87a021d5c9 Add <license> section to 3.1.x Maven poms
Issue: SPR-8927
2012-01-31 15:18:05 +01:00
Chris Beams 41c405998e Convert CRLF=>LF on files missed earlier
Complete pass with `dos2unix` found additional files missed on earlier
related commit.

Issue: SPR-5608
2011-12-22 14:06:44 +01:00
Chris Beams 88913f2b23 Convert CRLF (dos) to LF (unix)
Prior to this change, roughly 5% (~300 out of 6000+) of files under the
source tree had CRLF line endings as opposed to the majority which have
LF endings.

This change normalizes these files to LF for consistency going forward.

Command used:

$ git ls-files | xargs file | grep CRLF | cut -d":" -f1 | xargs dos2unix

Issue: SPR-5608
2011-12-21 14:52:47 +01:00
Chris Beams e158f61e93 Increment version to 3.1.1.BUILD-SNAPSHOT 2011-12-16 11:59:06 +01:00
Chris Beams ac107d0c2a Release Spring Framework 3.1.0.RELEASE 2011-12-13 16:35:49 +00:00
Juergen Hoeller 66b4eb16a5 Portlet MVC annotation mapping allows for distributing action names across controllers (SPR-7685) 2011-12-05 21:20:27 +00:00
Juergen Hoeller 21f61e3680 Portlet session mutex uses global session attribute to be shared among all portlets in the session (SPR-8888) 2011-12-02 12:03:35 +00:00
Juergen Hoeller b55040cf02 Servlet/PortletContextResource's getFile prefers "file:" URL resolution over calling getRealPath (SPR-8461) 2011-11-28 16:51:42 +00:00
Juergen Hoeller 2fdc2b5822 fixed StandardServlet/PortletEnvironment to check for JNDI (for Google App Engine compatibility) 2011-10-20 10:46:16 +00:00
Sam Brannen 1de71c6e37 [SPR-8222] Upgraded to JUnit 4.9. 2011-08-30 13:16:12 +00:00
Chris Beams 2c239e30d5 Update spring-webmvc-portlet template.mf
Add Import-Template entry for org.spring-framework.jndi

Issue: SPR-8038
2011-08-20 10:23:08 +00:00
Chris Beams f0460ce6fd Register JndiPropertySource by default in portlet environments
Issue: SPR-8038, SPR-8545, SPR-8490
2011-08-20 03:02:37 +00:00
Sam Brannen 87dad65ff0 [SPR-8622] Upgraded to JUnit 4.8.2 2011-08-18 16:06:31 +00:00
Juergen Hoeller fad865fbad polishing 2011-07-27 22:38:59 +00:00
Juergen Hoeller 4385367f2d optimized getMethodResolver implementation to actually benefit from ConcurrentHashMap 2011-07-27 22:26:05 +00:00
Juergen Hoeller 571535352b revised Servlet 3.0 based StandardServletMultipartResolver for correct param/file distinction; added multipart content type and headers access to MultipartRequest (dropping the previous header access solution on MultipartFile); MultipartFilter uses a Servlet 3.0 based StandardServletMultipartResolver by default 2011-07-20 20:46:53 +00:00
Juergen Hoeller 3bbefb3e65 fixed getHeaderNames signature 2011-06-28 14:08:47 +00:00
Juergen Hoeller 0371f569ec added headers support to MultipartFile abstraction 2011-06-27 23:02:13 +00:00
Juergen Hoeller c60511bf04 shortened build properties "org.junit.version" to "junit.version" and "org.testng.version" to "testng.version"; reverted SLF4J version back to 1.5.3 (for Hibernate 3.3.1 compatibility) 2011-06-09 09:58:15 +00:00
Chris Beams 0756a6abfe Polish PropertySource and Environment Javadoc 2011-05-25 10:52:03 +00:00
Chris Beams c4363673dc Delegate parent environment to child app contexts
Calls to AbstractApplicationContext#setParent delegate the parent
context environment to the child.

This ensures that any property sources added to the parent are available
to the child as well as ensuring that any profiles activated are
activated everywhere.

Child contexts may still choose to replace their environment (through an
ApplicationContextInitializer, for example).  In any case, however, in
the root/child web application context relationship established by
ContextLoader + DispatcherServlet, the child is guaranteed to have
already been given the parent environment by the time it is delegated
to any ACIs.

See AbstractApplicationContext#setParent for implementation

See FrameworkServlet#createWebApplicationContext for order in which
setParent then initializeWebApplicationContext are called.

Issue: SPR-8185
2011-05-23 10:04:00 +00:00
Chris Beams c481d2e9fb Rename {Default=>Standard}PortletEnvironment
Issue: SPR-8348
2011-05-20 03:57:35 +00:00
Chris Beams f893b62a9b Rename {DefaultWeb=>StandardServlet}Environment
Issue: SPR-8348
2011-05-20 03:55:56 +00:00
Chris Beams c06752ef72 Rename {Default=>Standard}Environment
Issue: SPR-8348
2011-05-20 03:53:37 +00:00
Chris Beams 7271ba8182 Introduce AbstractEnvironment#customizePropertySources
This new hook in the AbstractEnvironment lifecycle allows for more
explicit and predictable customization of property sources by
subclasses.  See Javadoc and existing implementations for detail.

Issue: SPR-8354
2011-05-20 03:50:14 +00:00
Chris Beams 2f7c2230f0 Include license.txt and notice.txt in module JARs 2011-02-09 06:56:40 +00:00
Juergen Hoeller b3f039ae5f Servlet/PortletRequestDataBinder perform unwrapping for MultipartRequest as well (SPR-7795) 2011-01-26 20:09:42 +00:00
Chris Beams 2b99cf6d29 Refactor Environment and PropertySource
* Environment now extends PropertyResolver
* Environment no longer exposes resolver and sources
* PropertySource is String,Object instead of String,String
* PropertySource no longer assumes enumerability of property names
* Introduced EnumerablePropertySource for those that do have enumerable property names
2011-01-05 22:24:14 +00:00
Chris Beams 5e6912302a Introduce "Aware" superinterface
All existing *Aware interfaces have been refactored to extend this
new marker interface, serving two purposes:

    * Easy access to a type hierarchy that can answer the question
      "What *Aware interfaces are available?", without requiring
      text-based searches. Also clearly excludes false positives like
      TargetClassAware and ParamAware, which while similarly named,
      are not semantically similar to traditional *Aware interfaces
      in Spring.

    * Minor potential performance improvements in
      AbstractAutowireCapableBeanFactory and
      ApplicationContextAwareProcessor. Both have blocks of sequential
      instanceof checks in order to invoke any *Aware interface callback
      methods. For a bean that implements none of these interfaces,
      the whole sequence can be avoided by guarding first with
          if (bean instanceof Aware) {
              ...
          }

Implementors of custom *Aware-style interfaces (and presumably
the BeanPostProcessors that handle them), are encouraged to refactor to
extending this interface for consistency with the framework as well as
the points above.
2011-01-03 10:13:57 +00:00
Chris Beams b3ff9be78f M1 cut of environment, profiles and property work (SPR-7508)
Decomposed Environment interface into PropertySources, PropertyResolver
objects

    Environment interface and implementations are still present, but
    simpler.

    PropertySources container aggregates PropertySource objects;
    PropertyResolver provides search, conversion, placeholder
    replacement. Single implementation for now is
    PropertySourcesPlaceholderResolver

Renamed EnvironmentAwarePropertyPlaceholderConfigurer to
PropertySourcesPlaceholderConfigurer

    <context:property-placeholder/> now registers PSPC by default, else
    PPC if systemPropertiesMode* settings are involved

Refined configuration and behavior of default profiles

    See Environment interface Javadoc for details

Added Portlet implementations of relevant interfaces:

    * DefaultPortletEnvironment
    * PortletConfigPropertySource, PortletContextPropertySource
    * Integrated each appropriately throughout Portlet app contexts

Added protected 'createEnvironment()' method to AbstractApplicationContext

    Subclasses can override at will to supply a custom Environment
    implementation.  In practice throughout the framework, this is how
    Web- and Portlet-related ApplicationContexts override use of the
    DefaultEnvironment and swap in DefaultWebEnvironment or
    DefaultPortletEnvironment as appropriate.

Introduced "stub-and-replace" behavior for Servlet- and Portlet-based
PropertySource implementations

    Allows for early registration and ordering of the stub, then
    replacement with actual backing object at refresh() time.

    Added AbstractApplicationContext.initPropertySources() method to
    support stub-and-replace behavior. Called from within existing
    prepareRefresh() method so as to avoid impact with
    ApplicationContext implementations that copy and modify AAC's
    refresh() method (e.g.: Spring DM).

    Added methods to WebApplicationContextUtils and
    PortletApplicationContextUtils to support stub-and-replace behavior

Added comprehensive Javadoc for all new or modified types and members

Added XSD documentation for all new or modified elements and attributes

    Including nested <beans>, <beans profile="..."/>, and changes for
    certain attributes type from xsd:IDREF to xsd:string

Improved fix for detecting non-file based Resources in
PropertiesLoaderSupport (SPR-7547, SPR-7552)

    Technically unrelated to environment work, but grouped in with
    this changeset for convenience.

Deprecated (removed) context:property-placeholder
'system-properties-mode' attribute from spring-context-3.1.xsd

    Functionality is preserved for those using schemas up to and including
    spring-context-3.0.  For 3.1, system-properties-mode is no longer
    supported as it conflicts with the idea of managing a set of property
    sources within the context's Environment object. See Javadoc in
    PropertyPlaceholderConfigurer, AbstractPropertyPlaceholderConfigurer
    and PropertySourcesPlaceholderConfigurer for details.

Introduced CollectionUtils.toArray(Enumeration<E>, A[])

Work items remaining for 3.1 M2:

    Consider repackaging PropertySource* types; eliminate internal use
    of SystemPropertyUtils and deprecate

    Further work on composition of Environment interface; consider
    repurposing existing PlaceholderResolver interface to obviate need
    for resolve[Required]Placeholder() methods currently in Environment.

    Ensure configurability of placeholder prefix, suffix, and value
    separator when working against an AbstractPropertyResolver

    Add JNDI-based Environment / PropertySource implementatinos

    Consider support for @Profile at the @Bean level

    Provide consistent logging for the entire property resolution
    lifecycle; consider issuing all such messages against a dedicated
    logger with a single category.

    Add reference documentation to cover the featureset.
2011-01-03 09:04:34 +00:00
Sam Brannen b130a36af7 [SPR-7850][SPR-7851] Upgraded to JUnit 4.8.1 and TestNG 5.12.1; added changelog entries for 3.1.0.M1. 2010-12-30 08:00:58 +00:00
Costin Leau 01e79cfedd SPR-7703
- minor performance improvements to servlet and portlet handlers
2010-10-31 17:46:15 +00:00
Arjen Poutsma 7cc3f49910 SPR-7695 - Add ETag version of WebRequest.checkNotModified() 2010-10-29 10:28:47 +00:00
Chris Beams f480333d31 Merge 3.1.0 development branch into trunk
Branch in question is 'env' branch from git://git.springsource.org/sandbox/cbeams.git; merged into
git-svn repository with:

    git merge -s recursive -Xtheirs --no-commit env

No merge conflicts, but did need to

    git rm spring-build

prior to committing.

With this change, Spring 3.1.0 development is now happening on SVN
trunk. Further commits to the 3.0.x line will happen in an as-yet
uncreated SVN branch.  3.1.0 snapshots will be available
per the usual nightly CI build from trunk.
2010-10-25 19:48:20 +00:00
Juergen Hoeller 40fa8afce4 DispatcherPortlet's default resource serving explicitly prevents access to WEB-INF and META-INF (SPR-7540) 2010-10-02 00:03:09 +00:00
Juergen Hoeller 668207d59d fixed Portlet UnavailableException tests (SPR-7542) 2010-09-29 13:45:50 +00:00
Juergen Hoeller 803b336354 fixed Portlet UnavailableException tests (SPR-7542) 2010-09-29 13:31:53 +00:00
Juergen Hoeller bf90a2ddb6 DispatcherPortlet throws custom NoHandlerFoundException instead of misleading UnavailableException (SPR-7542) 2010-09-14 06:43:53 +00:00
Juergen Hoeller 88e0dcfa06 added MockMultipartFile to web-portlet module 2010-09-06 23:22:03 +00:00
Juergen Hoeller bd05b046d0 reverted shortening of action exception parameter value; fixed multipart test (SPR-7495) 2010-09-06 23:11:11 +00:00
Juergen Hoeller 7e5215b5d4 fixed typo 2010-09-06 22:56:18 +00:00
Juergen Hoeller ba946c08dd copy event parameters to render parameters in case of an action exception as well (SPR-7495) 2010-09-06 22:56:05 +00:00
Juergen Hoeller 3eda5144ae DispatcherPortlet copies all action parameters to render parameters in case of an action exception (SPR-7495); shortened Portlet MVC's action exception render parameter value to "true" 2010-09-06 22:45:31 +00:00
Juergen Hoeller e68f2f0a5f removed unused HandlerExecutionChain caching 2010-09-06 21:44:06 +00:00
Juergen Hoeller 45d9b0cb2d allow for writing the response directly in a Portlet @ExceptionHandler method (like in the Servlet equivalent) 2010-09-06 21:43:26 +00:00
Juergen Hoeller 66b4499973 polishing 2010-09-06 21:20:03 +00:00
Juergen Hoeller e035477e6a extended synchronization for methodResolverCache (SPR-7525) 2010-09-06 20:41:50 +00:00
Ben Hale 7730e76c06 Publishing license and notice files 2010-08-23 13:17:31 +00:00
Arjen Poutsma dbfa049e1e Prepping for 3.0.5 2010-08-19 11:04:04 +00:00
Juergen Hoeller d1afb29074 Servlet/PortletContextResource inherit isReadable, contentLength and lastModified from AbstractFileResolvingResource 2010-08-15 22:57:37 +00:00