You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "Elkhan Eminov (Jira)" <ji...@apache.org> on 2022/06/21 11:11:00 UTC
[jira] [Commented] (KAFKA-13702) Connect RestClient overrides response status code on request failure
[ https://issues.apache.org/jira/browse/KAFKA-13702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17556826#comment-17556826 ]
Elkhan Eminov commented on KAFKA-13702:
---------------------------------------
[~corlobin] since your PR went stale, I've spun out [https://github.com/apache/kafka/pull/12320] with the suggested changes, I hope you don't mind
> Connect RestClient overrides response status code on request failure
> --------------------------------------------------------------------
>
> Key: KAFKA-13702
> URL: https://issues.apache.org/jira/browse/KAFKA-13702
> Project: Kafka
> Issue Type: Bug
> Components: KafkaConnect
> Reporter: Elkhan Eminov
> Assignee: Elkhan Eminov
> Priority: Major
>
> In case the submitted request status is >=400, the connect RestClient [throws|https://github.com/apache/kafka/blob/8047ba3800436d6162d0f8eb707e28857ab9eb68/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/rest/RestClient.java#L133] a ConnectRestException with the proper response code, but it gets intercepted and [rethrown with 500 status code|https://github.com/apache/kafka/blob/8047ba3800436d6162d0f8eb707e28857ab9eb68/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/rest/RestClient.java#L147], effectively overriding the actual failure status.
--
This message was sent by Atlassian Jira
(v8.20.7#820007)