Bug #3070
Content type not set appropriately for content retrieved from PISCO
100%
Description
E.g. doi:10.6085/AA/pisco_smr_synthesis.4.1
https://data.piscoweb.org/catalog/d1/mn/v1/object/doi:10.6085%2FAA%2Fpisco_smr_synthesis.4.1
is a jpg image as specified by the object format.
The content type header in the GET response is text/xml, and so is not handled correctly by http clients such as a web browser.
Note that this is probably a larger issue than just Metacat - the mime type should really be specified in the system metadata so that the correct response can be provided by a server when the content is requested.
History
#1 Updated by Ben Leinfelder over 12 years ago
- Status changed from New to In Progress
Right now we are handlings only a few format types and defaulting the rest to text/xml:
"Content-Disposition" --> "inline; filename=" + id.getValue() + ".xml"
Not sure if this is really appropriate.
#2 Updated by Ben Leinfelder over 12 years ago
- Status changed from In Progress to Closed
Until we have MIME type in the ObjectFormat list, we will use this alg:
-default to application/octet-stream
-use any "text/" formats as is
-use any "image/" formats as is
-use any "application/*" formats as is
- use "text/xml" for all METADATA typed object formats