-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(pagination): Fix after for regexp, match functions #7700
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 5 files reviewed, 1 unresolved discussion (waiting on @manishrjain, @pawanrawal, @rohanprasad, and @vvbalaji-dgraph)
worker/task.go, line 1547 at r1 (raw file):
} var tv pb.TaskValue err = pl.Iterate(arg.q.ReadTs, 0, func(p *pb.Posting) error {
The second argument in Iterate()
function is for afterUid. You can just pass it there, so no need for the if block below.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see a bunch of places where we are setting AfterUid to 0
. Can you check what might be the reason for that? Or do we actually need to add this AfterUid
check over there as well.
worker/task.go, line 1547 at r1 (raw file): Previously, ahsanbarkati (Ahsan Barkati) wrote…
Verified, this works fine without the change. |
* fix(pagination): Fix after for regexp, match functions * Add test for pagination with other functions (cherry picked from commit c11a607)
* fix(pagination): Fix after for regexp, match functions * Add test for pagination with other functions (cherry picked from commit c11a607)
Match, Compare, Regexp and Geo functions didn't work with `after` attribute. The PR fixes that. With this PR, the following type of queries are possible: ``` { q(func: match(name, Ali, 5), after: 0x2710) { uid name } } ``` (cherry picked from commit c11a607) Co-authored-by: Rohan Prasad <[email protected]>
This change fixes the pagination functioning that used "after" to specify a UID as offset.
Fixes DGRAPH-3222
This change is