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

Can we use the a modified version of the existing Graph Protocol node? #5

Closed
yourheropaul opened this issue Aug 5, 2019 · 2 comments

Comments

@yourheropaul
Copy link
Contributor

yourheropaul commented Aug 5, 2019

This is The Graph's version of the indexing node: https://github.com/graphprotocol/graph-cli. They also have a mapping-creator: https://github.com/graphprotocol/graph-ts and it seems like they have forked Substrate.

Advantages

The Graph nodes already feature scalable GraphQL APIs, self-hosted setups, and are continually maintained by a dedicated team.

Perhaps this is an off-the-shelf solution? It turns out this is only for Ethereum chains initially, and uses web3 as its interface.

Problems and solutions

The Graph's project goal is to support any blockchain, but it currently only supports Ethereum. There is a concept of multiple datasources and in theory any WASM runtime is supported.

In order to make this system compatible with a Substrate/Joystream node, we'd need to:

  1. Fork the main graph node
  2. Implement a Substrate data source
  3. (optionally) create a runtime for non-Ethereum smart contracts (which should be possible)
  4. Make sure that the graph node serves proofs via GraphQL

Questions

  1. How tightly coupled is the Ethereum datasource?
  2. Are there any other implications of changing the datasource?
@yourheropaul
Copy link
Contributor Author

The main issues here would be:

  1. Modifying a complex Rust application
  2. Making sure proofs are provided for the web API (see Proposal in update handle validation method to limit to: ^[a-z0-9_]+$ joystream#17)

@yourheropaul yourheropaul changed the title Can we use the a modified version of the existing Graph Protocol? Can we use the a modified version of the existing Graph Protocol node? Aug 5, 2019
@yourheropaul
Copy link
Contributor Author

This isn't really feasible.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant