Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-11266

V2 API returning wrong content-type

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Done
    • None
    • 9.0
    • v2 API
    • None

    Description

      The content-type of the returned value is wrong in many places. It should return "application/json", but instead returns "application/text-plan".

      Here's an example:

      [ishan@t430 ~] $ curl -v "http://localhost:8983/api/collections/products/select?q=*:*&rows=0"
      *   Trying 127.0.0.1...
      * TCP_NODELAY set
      * Connected to localhost (127.0.0.1) port 8983 (#0)
      > GET /api/collections/products/select?q=*:*&rows=0 HTTP/1.1
      > Host: localhost:8983
      > User-Agent: curl/7.51.0
      > Accept: */*
      > 
      < HTTP/1.1 200 OK
      < Content-Type: text/plain;charset=utf-8
      < Content-Length: 184
      < 
      {
        "responseHeader":{
          "zkConnected":true,
          "status":0,
          "QTime":1,
          "params":{
            "q":"*:*",
            "rows":"0"}},
        "response":{"numFound":260,"start":0,"docs":[]
        }}
      * Curl_http_done: called premature == 0
      * Connection #0 to host localhost left intact
      

      Attachments

        1. SOLR-11266.patch
          3 kB
          Munendra S N
        2. SOLR-11266.patch
          3 kB
          Munendra S N

        Issue Links

          Activity

            People

              munendrasn Munendra S N
              ichattopadhyaya Ishan Chattopadhyaya
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: