Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-12152

create cluster REST endpoint does not respect content-type header

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 2.0.0
    • None
    • ambari-server

    Description

      Summary
      If the JSON request payload is sent with content type "application/json", it needs to be string-encapsulated JSON, not bare JSON.

      this works:
      "{\"Clusters\": { \"version\": \"HDP-2.2\" }}"

      this does not:
      {"Clusters": { "version": "HDP-2.2" }}

      If the JSON request payload is sent with content type "text/plain", string-encapsulation is not required.

      Why require a JSON payload with application/json content type be string-encapsulated?

      Attachments

        Activity

          People

            Unassigned Unassigned
            clarkbreyman Clark Breyman
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: