newrelic-client-go icon indicating copy to clipboard operation
newrelic-client-go copied to clipboard

High latency when querying thousands of Applications or Application Metrics

Open kminehart opened this issue 4 years ago • 6 comments

Description

In the rest implementation of the ApplicationsInterface, and in the APM struct, queries that are paginated traverse through every page before returning anything. Users of this package should have the ability to traverse through the pages themselves to avoid high latency requests.

This is happening a lot in the Grafana NewRelic datasource.

I'll be opening a pull request soon that ought to maintain backwards compatibility and add functions for retrieving individual pages, if that's ok. :)

kminehart avatar Nov 13 '20 23:11 kminehart

This issue has been automatically marked as stale because it has not had any recent activity. It will be closed if no further activity occurs.

stale[bot] avatar Nov 28 '20 00:11 stale[bot]

This issue has been automatically closed due to a lack of activity for an extended period of time.

stale[bot] avatar Dec 05 '20 03:12 stale[bot]

@kminehart Hello! This issue actually went stale, so apologies we didn't get back to you sooner, did you go ahead an open a PR for this change?

jpvajda avatar Dec 07 '20 17:12 jpvajda

No actually I did not.

I started to, and then quickly realized that doing a change like this in a backwards compatible way that doesn't affect existing signatures that people are already using is really difficult.

I guess I needed to step away from it for a little bit because I realize now that it's totally doable. I'm not sure I'll have the time to make this change, but what I'd like to see if anyone is willing to pick this up is a function that allows us to control when the next page is requested when listing APM metrics.

kminehart avatar Dec 07 '20 17:12 kminehart

Any chance we could get this reopened?

kminehart avatar Dec 07 '20 18:12 kminehart

This issue has been automatically marked as stale because it has not had any recent activity. It will be closed if no further activity occurs.

stale[bot] avatar Dec 21 '20 20:12 stale[bot]