[go: up one dir, main page]

Skip to content

Use correct cursor pattern

What does this MR do and why?

Use correct cursor pattern

This commit fixes cursor for keyset pagination in groups and projects audit event finder

EE: true Changelog: added

References

Screenshots or screen recordings

Before After

How to set up and validate locally

  1. Disable Feature.disable(:read_audit_events_from_new_tables)
  2. Call audit events API: base_url/api/v4/groups/flightjs/audit_events?pagination=keyset&per_page=1
  3. Get next page link from response headers
  4. Enable Feature.enable(:read_audit_events_from_new_tables)
  5. Call API via next page link
  6. Check error: RuntimeError (Incorrect cursor values were given. Missing items: created_at):

To solve this we need to exclude created_at in order_by clause when using keyset pagination.

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #493723

Edited by Harsimar Sandhu

Merge request reports

Loading