You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "David Smiley (Jira)" <ji...@apache.org> on 2025/06/15 22:53:00 UTC

[jira] [Commented] (SOLR-17787) CborResponseWriter should use content-type: application/cbor

    [ https://issues.apache.org/jira/browse/SOLR-17787?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17977653#comment-17977653 ] 

David Smiley commented on SOLR-17787:
-------------------------------------

The change should be here https://github.com/apache/solr/blob/e17078a98a8ebea1a28853d02527f4dc81da4d6b/solr/core/src/java/org/apache/solr/response/CborResponseWriter.java#L54

> CborResponseWriter should use content-type: application/cbor
> ------------------------------------------------------------
>
>                 Key: SOLR-17787
>                 URL: https://issues.apache.org/jira/browse/SOLR-17787
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Yohei Kishimoto
>            Priority: Minor
>
> Currently, when Solr returns a response in CBOR format, the {{Content-Type}} header is {{{}application/octet-stream{}}}, the same as it is for javabin.
> However, the RFC for the CBOR format ([RFC 8949|https://datatracker.ietf.org/doc/html/rfc8949#name-media-types-registry]) specifies that {{application/cbor}} should be used as the {{{}Content-Type{}}}.
> Modern HTTP client implementations (for example, Spring's {{{}RestClient{}}}) have a feature that automatically switches the response deserializer based on the {{{}Content-Type{}}}. Due to Solr's current implementation, this feature cannot be used, requiring the deserializer to be switched manually.
> By using {{Content-Type: application/cbor}} when returning CBOR-formatted responses, Solr would comply with internet standards and potentially reduce the implementation cost for HTTP clients.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org