Feature Idea: Support OkHttp 3 on Java

As far as i know NewRelic supports OkHttp for Android agent (Support OkHttp 3 on Android). Is it possible to have support also in the Java agent?

New Relic edit

  • I want this, too
  • I have more info to share (reply below)
  • I have a solution for this

0 voters

We take feature ideas seriously and our product managers review every one when plotting their roadmaps. However, there is no guarantee this feature will be implemented. This post ensures the idea is put on the table and discussed though. So please vote and share your extra details with our team.

1 Like

Thanks @fgaule - thanks for this idea! I added a poll so that others can chime in to support this idea. If you have any implementation details you can share (what is important to you, what is the use case?) those are always very helpful for our engineers.

This is already done for Android, can the same change be made here? Support OkHttp 3 on Android

I’d really like to see OkHTTP/Retrofit support in the Java agent as well. We run some services developed at Netflix that use Retrofit and OkHttp to talk to each other and we’d really like to be able to get those service to service calls instrumented.

We are also using OkHTTP/Retrofit for more and more of our services, and would really like to see support for this added to the Java Agent. Any update on this?

@hross Correct me if I’m wrong, but isn’t this a bug, not a feature request? The android agent supports okhttp3, and the Java agent claims to in the documentation: https://docs.newrelic.com/docs/agents/java-agent/getting-started/compatibility-requirements-java-agent#frameworks. It would be good if you could just apply the fix from the android agent, or remove okhttp3 from the Java agent supported frameworks till this is fixed.


Hey @Andrew.Potter—I can’t thank you enough for pointing out that possible discrepancy in our documentation. Either it’s wrong, or this thread is wrong and I am going to get to the bottom of it!

Check back here for updates and in the meantime, keep the votes comin’! :blush:


I didn’t find this thread when I searched originally, so I’ll leave it here for others: OKHttp 3 not tracking external service correctly

1 Like

Good find, @Andrew.Potter! Thanks—you are not alone. :wink:

is there an update on this topic ??

Hi all, the New Relic Java Agent supports OKHttp 3.

There was a bug fix for this instrumentation in version 4.5.0.


Please give 4.5.0 or a later version a try.

Thank you.

1 Like