Swoorup / dgraph-rs

A dgraph client driver written in rust ⛺
https://crates.io/crates/dgraph
MIT License
98 stars 10 forks source link

Add support for Dgraph 1.1 #12

Closed ondrowan closed 4 years ago

ondrowan commented 5 years ago

This patch adds support for Dgraph 1.1 through a feature flag. By default, installed crate supports Dgraph 1.0 out of the box. If user needs 1.1 support, they have to disable default feature flags and provide "dgraph-1-1" one. This is most likely just a temporary solution while Dgraph 1.0 is supported and this library catches up with its official counterparts feature-wise.

ondrowan commented 5 years ago

This is not finished yet. I still need to set up Travis, polish tests and document new features. I'll potentially also implement version of query that uses new do_request API.

I decided to go the harder, but IMO more user friendly way. This PR gives users support for both Dgraph 1.0 and 1.1, depending on what they choose via a feature flag. I'm still not sure if using default feature flag or explicit one is a better idea in case of Dgraph 1.0.

If someone could test this, I'd be grateful.

@martinmr @Pepeye Since you two showed interest in #10, I'm tagging you just FYI.

Swoorup commented 5 years ago

I will have a bit more look at this weekend.

On this occasion, I prefer keeping only the latest stable rather than keeping both versions at any given time and thus providing a migration guide. However does Dgraph have plans to keep supporting 1.0?

ondrowan commented 5 years ago

I'd prefer that as well, but I saw that there are still releases for Dgraph 1.0 as well. But maybe @martinmr would have an answer for this.

martinmr commented 5 years ago

We might release new versions of 1.0 but they will only contain bugfixes. So the current release of the rust client should work.

d0nutptr commented 4 years ago

Any idea on when this might get merged in? I'm currently unable to use this library due to a lack of 1.1 support :(

ondrowan commented 4 years ago

@d0nutptr I'll try to fix everything there's left and merge the PR this weekend.