You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "pengding-stripe (via GitHub)" <gi...@apache.org> on 2025/12/05 19:37:30 UTC

[I] Pinot returns 200 http response even when the underlying query failed [pinot]

pengding-stripe opened a new issue, #17329:
URL: https://github.com/apache/pinot/issues/17329

   Pinot today returns 200 http response code even though the query failed, it has an exceptions field with detailed errors + Pinot error code. This design doesn't work well with some cases that depend on the http response code returned from Pinot broker.
   
   There was another [ask](https://github.com/apache/pinot/issues/12190) for adding a response header to reflect the Pinot error code but that doesn't solve the problem when there's need depending on the http response code only to tell if the query succeeds or not.
   
   To make the changes backward-compatible, I think we can introduce a request header like `X-PINOT-STRICT-ERROR` and Pinot should return a 4xx or 5xx depending on the Pinot error code if it's set to true. This way users need this feature can configure the upstream accordingly without affecting use cases that do not care about the http response code. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [I] Pinot returns 200 http response even when the underlying query failed [pinot]

Posted by "pengding-stripe (via GitHub)" <gi...@apache.org>.
pengding-stripe commented on issue #17329:
URL: https://github.com/apache/pinot/issues/17329#issuecomment-3618416185

   @Jackie-Jiang 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [I] Pinot returns 200 http response even when the underlying query failed [pinot]

Posted by "Jackie-Jiang (via GitHub)" <gi...@apache.org>.
Jackie-Jiang commented on issue #17329:
URL: https://github.com/apache/pinot/issues/17329#issuecomment-3618501969

   The proposal looks good to me. I'd probably make the header more concise, something indicating using the response code to represent error


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [I] Pinot returns 200 http response even when the underlying query failed [pinot]

Posted by "pengding-stripe (via GitHub)" <gi...@apache.org>.
pengding-stripe closed issue #17329: Pinot returns 200 http response even when the underlying query failed
URL: https://github.com/apache/pinot/issues/17329


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [I] Pinot returns 200 http response even when the underlying query failed [pinot]

Posted by "Jackie-Jiang (via GitHub)" <gi...@apache.org>.
Jackie-Jiang commented on issue #17329:
URL: https://github.com/apache/pinot/issues/17329#issuecomment-3629922910

   Let's try to generate a mapping from each pinot error code to http response code, and let the team review it


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Re: [I] Pinot returns 200 http response even when the underlying query failed [pinot]

Posted by "pengding-stripe (via GitHub)" <gi...@apache.org>.
pengding-stripe commented on issue #17329:
URL: https://github.com/apache/pinot/issues/17329#issuecomment-3618553509

   thanks @Jackie-Jiang, I can change to `X-PINOT-HTTP-RESPONSE-CODE-REPRESENT-PINOT-ERROR-CODE` to be more clear
   
   do you have preference on http response code <> pinot error code mapping?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org