From the JavaDocs:
The @MultipartConfig annotation supports the following optional attributes:
location: An absolute path to a directory on the file system. The location attribute does not support a path relative to the application context. This location is used to store files temporarily while the parts are processed or when the size of the file exceeds the specified fileSizeThreshold setting. The default location is "".
However, when
location="\Temp"
the file being uploaded is placed under:
\Servers\IBM\wlp\usr\servers\app\workarea\org.eclipse.osgi\113\data\temp\default_node\SMF_WebContainer\app-ear\app-1.0-SNAPSHOT\Temp\upload__4529d7ce_15f90e11b66__7ff3_00000002.tmp
which is not the absolute path given in the configuration.
How can we specify the correct folder?
UPDATE:
See Paul's answer below. Specifying 'C:/Temp' as location did the trick.