Good afternoon,
I have a process with an output variable of type Document: this document has a defined filename. When invoking the process, instead of downloading the file with the defined filename, I was receiving a file with a name that looks like an MD5 hash.
The fault for this lies with the DocumentManager application: it does not emit the content disposition header that would suggest to the browser what the real name of the octet-stream is. As such, without this header, the user agent will assume that the file-name is the endpoint name.
The trace of the HTTP exchange is below:
GET http://HOST:8080/rest/services/APP/SERVICE:1.0?q=83
Cache-Control no-cache, must-revalidate
Date Wed, 17 Nov 2010 12:54:29 GMT
Pragma no-cache
Transfer-Encoding chunked
Location http://HOST:8080/DocumentManager/docm$(NUMBER)/$(HASH)?type=$(TYPE)
X-Powered-By Servlet/2.5 JSP/2.1
GET http://HOST:8080/DocumentManager/docm$(NUMBER)/$(HASH)?type=$(TYPE)
Date Wed, 17 Nov 2010 12:54:35 GMT
Transfer-Encoding chunked
Content-Type application/vnd.ms-excel
X-Powered-By Servlet/2.5 JSP/2.1
The 2nd HTTP request should have included the specified header, like so:
Content-Disposition: attachment; filename=MyExcel.xls
Best regards,