org.codehaus.groovy.grails.web.multipart
Class ContentLengthAwareCommonsMultipartResolver

java.lang.Object
  extended by org.springframework.web.multipart.commons.CommonsFileUploadSupport
      extended by org.springframework.web.multipart.commons.CommonsMultipartResolver
          extended by org.codehaus.groovy.grails.web.multipart.ContentLengthAwareCommonsMultipartResolver
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.web.context.ServletContextAware, org.springframework.web.multipart.MultipartResolver

public class ContentLengthAwareCommonsMultipartResolver
extends org.springframework.web.multipart.commons.CommonsMultipartResolver

Safari includes the multipart packet inside an HTTP redirect without the Content-Length header. This causes CommonsMultipartResolver to blow up. We extend it here to catch this exception, printing a warning.

Since:
1.0

Nested Class Summary
 
Nested classes/interfaces inherited from class org.springframework.web.multipart.commons.CommonsFileUploadSupport
org.springframework.web.multipart.commons.CommonsFileUploadSupport.MultipartParsingResult
 
Field Summary
 
Fields inherited from class org.springframework.web.multipart.commons.CommonsFileUploadSupport
logger
 
Constructor Summary
ContentLengthAwareCommonsMultipartResolver()
           
 
Method Summary
protected  org.springframework.web.multipart.commons.CommonsFileUploadSupport.MultipartParsingResult parseRequest(javax.servlet.http.HttpServletRequest request)
           
 
Methods inherited from class org.springframework.web.multipart.commons.CommonsMultipartResolver
cleanupMultipart, determineEncoding, isMultipart, newFileUpload, resolveMultipart, setResolveLazily, setServletContext
 
Methods inherited from class org.springframework.web.multipart.commons.CommonsFileUploadSupport
cleanupFileItems, getDefaultEncoding, getFileItemFactory, getFileUpload, isUploadTempDirSpecified, newFileItemFactory, parseFileItems, prepareFileUpload, setDefaultEncoding, setMaxInMemorySize, setMaxUploadSize, setUploadTempDir
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContentLengthAwareCommonsMultipartResolver

public ContentLengthAwareCommonsMultipartResolver()
Method Detail

parseRequest

protected org.springframework.web.multipart.commons.CommonsFileUploadSupport.MultipartParsingResult parseRequest(javax.servlet.http.HttpServletRequest request)
                                                                                                          throws org.springframework.web.multipart.MultipartException
Overrides:
parseRequest in class org.springframework.web.multipart.commons.CommonsMultipartResolver
Throws:
org.springframework.web.multipart.MultipartException