flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLINK-6530) Unclosed Response in DatadogHttpClient#validateApiKey()
Date Sat, 13 May 2017 16:17:04 GMT

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

ASF GitHub Bot commented on FLINK-6530:
---------------------------------------

Github user zentol commented on the issue:

    https://github.com/apache/flink/pull/3892
  
    merging.


> Unclosed Response in DatadogHttpClient#validateApiKey()
> -------------------------------------------------------
>
>                 Key: FLINK-6530
>                 URL: https://issues.apache.org/jira/browse/FLINK-6530
>             Project: Flink
>          Issue Type: Bug
>            Reporter: Ted Yu
>            Assignee: Chesnay Schepler
>            Priority: Minor
>
> Here is related code:
> {code}
>     try {
>       Response response = client.newCall(r).execute();
>       if (!response.isSuccessful()) {
>         throw new IllegalArgumentException(
>           String.format("API key: %s is invalid", apiKey));
>       }
>     } catch(IOException e) {
>       throw new IllegalStateException("Failed contacting Datadog to validate API key",
e);
> {code}
> If execute() throws exception, the Response instance would be left unclosed.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message