Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-32673

Fallback to application/octet-stream if ??? is the detected MIME type

    XMLWordPrintable

    Details

    • Release Notes Summary:
      The MIME type of a document file is set to "application/octet-stream" if undefined.
    • Backlog priority:
      650
    • Team:
      PLATFORM
    • Sprint:
      nxplatform #120
    • Story Points:
      3

      Description

      Steps to reproduce:

      1. Log in as Administrator and navigate to the personal workspace
      2. Click on the + button and go to the Import tab
      3. Select the OPJ file who link is provided in the first comment
      4. Push the Create button
      5. Get the JSON export of the newly created document
      6. Observe that the file:content/mime-type property is set to ???
            "file:content":{
              "name":"Approval Figure A.2.opj",
              "mime-type":"???",
              "encoding":null,
              "digestAlgorithm":"MD5",
              "digest":"c648c5380e37539d5844722bf2f942cc",
              "length":"127335",1%20-%20id.86054%20Approval%20Figure%20A.2.opj?changeToken=2-0"
            },
        

      Observed behavior: the customer reports that this MIME type prevents from downloading the binary though an integration point with another Java application, because Jersey http client (and probably others) chokes when parsing the response headers containing the invalid Content-Type header

      Expected behavior: If MimetypeRegistryService#getMimetypeFromFile set the blob MIME type to ???, there should be a fallback on application/octet-stream to avoid any issue with the download of the binary

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: