Uploaded image for project: 'Red Hat Fuse'
  1. Red Hat Fuse
  2. ENTESB-15286

json bindingMode in RestConfiguration overrides the existing content-type header and unable to set charset:utf-8

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • fuse-7.8-GA
    • fuse-7.7-GA
    • Camel
    • False
    • False
    • % %
    • Undefined
    • Hide
      • Download and unzip reproducer.zip
      • Import the bindingModel_json project to CodeReadyStuio, and run project
      • execute "curl -X GET http://localhost:8082/test -v"
      • check content-type header

      expected value: 

        Content-Type: application/json;charset:utf-8

      actual result:

        Content-Type: application/json

      Show
      Download and unzip reproducer.zip Import the bindingModel_json project to CodeReadyStuio, and run project execute "curl -X GET http://localhost:8082/test -v" check content-type header expected value:    Content-Type: application/json;charset:utf-8 actual result:   Content-Type: application/json

    Description

      org.apache.camel.component.jackson.JacksonDataFormal.marshal() method sets content-type, "application/json", even there is an existing value, "application/json;charset:utf-8".
      In this method, please consider not to delete the existing value "application/json;charset:utf-8". Or please add an extra option for user to specify the charset in the content-type too.

      Attachments

        Activity

          People

            ldemasi Luigi De Masi
            rhn-support-hfuruich Hisao Furuichi
            Tomas Turek Tomas Turek
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: