feat(entities): add cursor pagination for entity search - #1429
feat(entities): add cursor pagination for entity search#1429pranav-new-relic wants to merge 1 commit into
Conversation
EntitySearch responses include a nextCursor but the existing methods had no way to feed it back in, so callers could only ever see the first page. Adds GetEntitySearchByQueryWithCursor and GetEntitySearchWithCursor (with WithContext variants) that accept a cursor argument alongside the existing parameters; the derived query strings inject $cursor: String and forward it into results(cursor: $cursor). Reported by Scott Dewitt in #help-obs-as-code.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1429 +/- ##
===========================================
+ Coverage 32.39% 65.38% +32.98%
===========================================
Files 148 148
Lines 6923 6979 +56
===========================================
+ Hits 2243 4563 +2320
+ Misses 4467 2004 -2463
- Partials 213 412 +199
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Trying this out before mergeIf you'd like to consume this branch to test the cursor-pagination fix, you can point your Option 1:
|
EntitySearch responses include a nextCursor but the existing methods had no way to feed it back in, so callers could only ever see the first page. Adds GetEntitySearchByQueryWithCursor and GetEntitySearchWithCursor (with WithContext variants) that accept a cursor argument alongside the existing parameters; the derived query strings inject $cursor: String and forward it into results(cursor: $cursor).