Hello Joakim,
One further question about the file upload issue - we previously used Jetty Runner version 8.x to launch our application and the file upload feature worked correctly.
Can you clarify whether the earlier version of Jetty Runner behaved differently with respect to file uploads - for example, it presumably implemented the Servlet 2.5 specification rather than than Servlet 3.0 specification, but I don’t know if this would make any difference?
Also, to clarify something in my earlier email, I said that the problem had been fixed in Spring 5.0 but not back ported to Spring 4.3.9. In fact, the patch was applied to Spring 4.3.8, but I believe it doesn’t fix the problem.
Thanks again for your help with this issue.
Best wishes,
Robert
Hello Joakim,
Thank you for the additional explanation - the difference between the Tomcat behaviour and the official behaviour is the underlying cause of our problem.
Apparently, the Spring MultipartFile abstraction has always allowed files to be uploaded to an absolute path location, but assumed that the underlying Servlet Container behaved like Tomcat:
This has apparently been fixed in Spring 5.0 but doesn’t seem to have been back ported to Spring 4.3.9, which is the version we are using.
Best wishes,
Robert
Tomcat implemented their version based on commons-fileupload, and an early version of their own javadoc for the servlet spec.
> fileName - The location into which the uploaded part should be stored. Relative locations are relative to MultipartConfigElement.getLocation()
vs
> fileName - the name of the file to which the stream will be written. The file is created relative to the location as specified in the MultipartConfig
Notice the difference in documentation? The Tomcat implementation isn't based on the actual final Servlet 3.0 spec.
_______________________________________________ jetty-users mailing list jetty-users@xxxxxxxxxxxTo change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/jetty-users
|