Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

fix(GraphQL): Ensure that a list of scalars remain sorted #76

Merged
merged 14 commits into from
Aug 21, 2022

Conversation

manishrjain
Copy link
Contributor

@manishrjain manishrjain commented Aug 19, 2022

If we have a list of strings, currently Outserv stores them sorted by their fingerprints. Instead, as per the GraphQL spec, we need to maintain their order. This PR achieves that outcome with a new ListType. The list values are binary encoded and stored together as one value. This ensures correct ordering. This means a posting list can only have a maximum of one posting for values (UIDs are stored in bitmaps anyway).

This PR also removes the type func from DQL. Instead, now we use has func for resolving queries with no filters. More work is needed to clean up dgraph.type predicate.

chunker interface is now replaced with jsonChunker. That's the only chunker we have after RDF chunker was removed.


This change is Reviewable

@manishrjain manishrjain mentioned this pull request Aug 20, 2022
4 tasks
@manishrjain manishrjain merged commit a774450 into main Aug 21, 2022
@manishrjain manishrjain deleted the mrjn/list-order branch August 21, 2022 21:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant