cardano-foundation / cardano-graphql

GraphQL API for Cardano
Apache License 2.0
262 stars 104 forks source link

Migrating for Chang HF: Is this a Db-Sync or a Cardano GraphQL issue? #889

Closed zxpectre closed 3 months ago

zxpectre commented 3 months ago

Ask a question

Hope guys you can help me spot the cause, our minimum viable Chang wallet update is getting very delayed because of this.

Could this db-sync issue actually been caused by newer config files provided by this setup to dbsync?

Latest update is that postgresdb container volume growed up to 1.2TB of size crashing one of our servers.
Or maybe could be the case that hasura/background are populating DB with wrong data in a loop?

Kammerlo commented 3 months ago

Hi, could you describe how you started the GraphQL Stack? (So what you changed from the default files) The only time I saw that the db size crashed were due to a db-sync bug, which hindered using snapshots.

zxpectre commented 3 months ago

cardano-graphql leads our backend design as is the most complex dependency there.

Only significative change is that we are using cardano-node-ogmios with its built-in configuration files and that due to the hardcoded values on Dockerfile I had to override the server and background entrypoints this way on docker-compose.yaml:

    entrypoint: >
      /bin/sh -c "
      echo \"Applying patch to provide env vars: \" ;
      echo \"   OGMIOS_HOST='${OGMIOS_HOST}'\" ;
      echo \"   OGMIOS_PORT='1337'\" ;
      OGMIOS_HOST=${OGMIOS_HOST} && OGMIOS_PORT=1337 && node background.js;
      " 

DB-Sync config files were taken from latest version of cardano-graphql

This is the start procedure that makes it all work with the volume size bomb getting triggered somehow

zxpectre commented 3 months ago

Update: https://github.com/IntersectMBO/cardano-db-sync/issues/1822#issuecomment-2314026775

Closing for now!

Kammerlo commented 3 months ago

Perfect, thanks for updating this issue as well!