Skip to content
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(multi-tenancy): fix live loader for case when namespace does not exist for data #7505

Merged
merged 8 commits into from
Mar 4, 2021

Conversation

NamanJain8
Copy link
Contributor

@NamanJain8 NamanJain8 commented Mar 2, 2021

Fixes DGRAPH-3075

Earlier, when live-loading data through Guardians of Galaxy, the NQuads make their way to the DB even if the namespace does not exist for them. This might lead to very interesting bugs.

This PR fixes it by extracting the namespaces by querying the schema. If we encounter a Nquad or schema for which namespace does not exist, we error out and live loader stops.


This change is Reviewable

@github-actions github-actions bot added area/live-loader Issues related to live loading. area/testing Testing related issues labels Mar 2, 2021
dgraph/cmd/live/run.go Outdated Show resolved Hide resolved
dgraph/cmd/live/run.go Outdated Show resolved Hide resolved
@NamanJain8 NamanJain8 merged commit 720048a into master Mar 4, 2021
@NamanJain8 NamanJain8 deleted the naman/live-loader branch March 4, 2021 12:42
aman-bansal pushed a commit that referenced this pull request Mar 9, 2021
…exist for data (#7505)

Earlier, when live-loading data through Guardians of Galaxy, the NQuads make their way to the DB even if the namespace does not exist for them. This might lead to very interesting bugs.

Fixed by extracting the namespaces by querying the schema. If we encounter a Nquad or schema for which namespace does not exist, we error out and live loader stops.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/live-loader Issues related to live loading. area/testing Testing related issues
Development

Successfully merging this pull request may close these issues.

2 participants