flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Elias Levy (JIRA)" <j...@apache.org>
Subject [jira] [Created] (FLINK-10390) DataDog metric reporter leak warning
Date Fri, 21 Sep 2018 22:19:00 GMT
Elias Levy created FLINK-10390:

             Summary: DataDog metric reporter leak warning
                 Key: FLINK-10390
                 URL: https://issues.apache.org/jira/browse/FLINK-10390
             Project: Flink
          Issue Type: Improvement
          Components: Metrics
    Affects Versions: 1.6.1
            Reporter: Elias Levy

After upgrading to 1.6.1 from 1.4.2 we starting observing in the log warnings associated with
the DataDog metrics reporter:
{quote}Sep 21, 2018 9:43:20 PM org.apache.flink.shaded.okhttp3.internal.platform.Platform
log WARNING: A connection to https://app.datadoghq.com/ was leaked. Did you forget to close
a response body? To see where this was allocated, set the OkHttpClient logger level to FINE:
The metric reporter's okhttp dependency version (3.7.0) has not changed, so that does not
appear to be the source of the warning.

I believe the issue is the changed made in [FLINK-8553|https://github.com/apache/flink/commit/ae3d547afe7ec44d37beeee38222a3ea40d9181e#diff-fc396ba6772815fc05efc1310760cd4b].
 The HTTP calls were made async.  The previous code called {{client.newCall(r).execute().close()}}.
 The new call does nothing in the callback, even thought the [Callback.onResponse documentation|https://square.github.io/okhttp/3.x/okhttp/okhttp3/Callback.html#onResponse-okhttp3.Call-okhttp3.Response-]

bq. Called when the HTTP response was successfully returned by the remote server. The callback
may proceed to read the response body with Response.body. The response is still live until
its response body is closed. 


This message was sent by Atlassian JIRA

View raw message