Skip to content

fix(query): Do not execute filters if there are no source uids #7962

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

Merged
merged 1 commit into from
Jul 29, 2021

Conversation

ahsanbarkati
Copy link
Contributor

@ahsanbarkati ahsanbarkati commented Jul 28, 2021

No need to execute filter subgraph if there are no source UIDs.


This change is Reviewable

Copy link
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like a generally reasonable change. :lgtm:

Reviewable status: 0 of 1 files reviewed, all discussions resolved

@manishrjain manishrjain changed the base branch from release/v21.03-slash to master July 29, 2021 02:31
@manishrjain manishrjain requested a review from danielmai as a code owner July 29, 2021 02:31
@manishrjain manishrjain changed the base branch from master to release/v21.03-slash July 29, 2021 02:31
@manishrjain manishrjain merged commit 849b587 into release/v21.03-slash Jul 29, 2021
@NamanJain8 NamanJain8 deleted the ahsan/fix-filters branch July 29, 2021 12:49
ahsanbarkati added a commit that referenced this pull request Aug 2, 2021
No need to execute filter subgraph if there are no source UIDs.

(cherry picked from commit 849b587)
ahsanbarkati added a commit that referenced this pull request Aug 2, 2021
#7969)

No need to execute filter subgraph if there are no source UIDs.

(cherry picked from commit 849b587)
all-seeing-code pushed a commit that referenced this pull request Nov 23, 2022
#7969)

No need to execute filter subgraph if there are no source UIDs.

(cherry picked from commit 849b587)
all-seeing-code pushed a commit that referenced this pull request Nov 28, 2022
#7969)

No need to execute filter subgraph if there are no source UIDs.

(cherry picked from commit 849b587)
all-seeing-code added a commit that referenced this pull request Nov 29, 2022
#8452)

No need to execute filter subgraph if there are no source UIDs.

(cherry picked from commit 849b587)

## Description
The original PR adds a fail fast methodology, where it doesn't expand on
a filter subgraph if the srcUid is nil. The current cherry-pick PR
brings that change in and adds a test case that scenario.

## Test
`TestFilterWithNoSrcUid`

Co-authored-by: Ahsan Barkati <ahsan@dgraph.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants