Leszek Wiesner 356a23d3ee Versioning il y a 3 ans
..
bootstrap 7886c8d5bd Upgrade apps to @polkadot/api 4.2.1 (unfinished) il y a 3 ans
mappings 08b5b84981 query-node: fix isCurated value casting il y a 4 ans
scripts f9e9c8826b query-node: fix integration tests il y a 4 ans
.gitignore 76916dfdd6 query-node: do not check in generated code il y a 4 ans
README.md fe235ebd3f query-node: configure with two separate databases il y a 4 ans
build.sh 04df68c182 query-node: point processor at correct database and do typeorm migrations for both DBs il y a 4 ans
db-migrate.sh 6e8c457127 query-node: factor out db:migrate to script il y a 4 ans
indexer-tsconfig.json bdb01a7d87 add esModuleInterop flag to indexer-tsconfig.json il y a 4 ans
package.json 356a23d3ee Versioning il y a 3 ans
processor-start.sh 29c98cb97b do not reload .env in processor-start.sh il y a 4 ans
run-tests.sh c55e6808ad query-node: initialize db with script & fix integration test il y a 4 ans
schema.graphql 874999c584 query-node: add default schema to all newly created entities il y a 4 ans
tsconfig.json 94e8fb7ae8 Query node - fix @joystream/types issue il y a 4 ans

README.md

query-node

The query-node project contains an input schema (schema.graphql) and mappings for the Joystream content-directory runtime module.

Code generation

We use Hydra-cli to generate a graphql server and a block indexer for joystream chain:

$ cd query-node
$ yarn build

Starting services

To start services defined in the project docker-compose.yml, you should run docker-compose from the project root folder to use the correct .env file

Run mapping processor

Before running mappings make sure indexer(yarn indexer:start) and indexer-api-server (mappings get the chain data from this graphql server) are both running:

yarn processor:start

Query data

Once processor start to store event data you will be able to query this data from http://localhost:4002/graphql.

query {
  channels {
    handle
  }
}