GithubHelp home page GithubHelp logo

cafernel / sudograph Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sudograph/sudograph

0.0 0.0 0.0 3 MB

GraphQL database for the Internet Computer

License: MIT License

Rust 40.17% HTML 53.87% CSS 1.56% JavaScript 2.67% TypeScript 1.43% Shell 0.31%

sudograph's Introduction

Sudograph

Sudograph is a GraphQL database for the Internet Computer (IC).

Its goal is to become the simplest way to develop applications for the IC. Developers start by defining a GraphQL schema using the GraphQL SDL. Once the schema is defined, it can be included within a canister and deployed to the IC. An entire relational database is generated from the schema, with GraphQL queries and mutations enabling a variety of CRUD operations, including advanced querying over relational data.

Sudograph should be considered somewhere between alpha and beta software.

Documentation

For full documentation, see The Sudograph Book, which is hosted entirely on the IC by the way.

Super quick start

mkdir my-new-project
cd my-new-project
npx sudograph
dfx start --background
dfx deploy

Once deployed, you can visit the following canisters from a Chromium browser:

If the above didn't work, try The Sudograph Book.

Major limitations

  • No custom scalars, only Blob, Boolean, Date, Float, ID, Int, JSON, and String are available
  • No custom input objects, only custom input scalars allowed in custom resolvers
  • Each schema is limited to a single canister with ~4 GB of storage
  • Very inneficient querying
  • No automatic migrations, once you deploy the schema is final unless you implement your own migrations
  • No authorization at the schema level, deal with it through your own custom authorization at the canister function level
  • No automated tests
  • No subscriptions
  • No transactions

Concrete roadmap

The following are very likely to be implemented by Sudograph in the short to medium term future:

  • Robust automated tests
  • Efficient querying i.e. indexes
  • Automatic migrations
  • Single canister transactions
  • Custom scalars
  • Schema authorization directives e.g. something like @auth(role: OWNER) for individual fields

Tentative roadmap

The following may or may not be implemented by Sudograph, but they seem like good ideas:

  • Unbounded scaling through a multi-canister architecture
  • upsert
  • create, update, delete many
  • create, update, delete, update/upsert within mutation inputs
  • order by multiple fields
  • Statistics within relation results (for example total counts, averages, sums, etc)
  • subscriptions
  • unique constraints and capabilities

Projects using Sudograph

Inspiration

Sudograph was inspired by many previous projects:

sudograph's People

Contributors

lastmjs avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.