Project

General

Profile

Task #2553

GMN returns an incorrect Content-Type header for XML content

Added by Chris Jones over 12 years ago. Updated almost 11 years ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
d1_mn_GMN
Start date:
2012-03-30
Due date:
% Done:

100%

Milestone:
CCI-1.0.0
Product Version:
Story Points:
Sprint:

Description

When trying to get() an object with XML content on a GMN instance, the Content-Type returned is 'text/html; charset=utf-8' rather than 'text/xml'. An example is below, but if that identifier has been scrubbed, any XML object would show this:

cjones@cn-sandbox-orc-1:~$ curl -k -I -s "https://mn-stage-ucsb-1.dataone.org/knb/d1/mn/v1/object/knb-lter-gce.11.13"
HTTP/1.1 200 OK
Date: Thu, 29 Mar 2012 17:58:10 GMT
Server: Apache/2.2.14 (Ubuntu)
DataONE-Checksum: MD5,8b2beb2c22b4a1e4bc6fd1df1f60256a
Last-Modified: Thu, 01 Jan 1970 00:00:00 GMT
DataONE-ObjectFormat: eml://ecoinformatics.org/eml-2.0.0
DataONE-SerialVersion: 1
Content-Length: 32492
Vary: Accept-Encoding
Content-Type: text/xml

cjones@cn-sandbox-orc-1:~$ curl -k -I -s "https://mn-stage-orc-1.dataone.org/mn/v1/object/knb-lter-gce.11.13"
HTTP/1.1 200 OK
Date: Thu, 29 Mar 2012 17:58:39 GMT
Server: Apache/2.2.14 (Ubuntu)
Content-Length: 32492
DataONE-SerialVersion: 7
DataONE-Checksum: MD5,8b2beb2c22b4a1e4bc6fd1df1f60256a
DataONE-formatId: eml://ecoinformatics.org/eml-2.0.0
Last-Modified: 2012-03-29T17:38:26.194000
Vary: Accept-Encoding
Content-Type: text/html; charset=utf-8

History

#1 Updated by Roger Dahl almost 11 years ago

  • Status changed from New to Closed
  • translation missing: en.field_remaining_hours set to 0.0

GMN now sets the Content-Type header based on a mapping from FormatID to mimetype.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 14.8 MB)