Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import snapshot meets ERROR: value too long for type character varying(65536) #810

Open
lcgogo opened this issue Feb 7, 2023 · 5 comments
Labels
question Further information is requested

Comments

@lcgogo
Copy link

lcgogo commented Feb 7, 2023

Ask a question

docker logs -f --tail 20 cardano-graphql_postgres_1

2023-02-07 03:48:05.851 UTC [20] LOG:  checkpoints are occurring too frequently (25 seconds apart)
2023-02-07 03:48:05.851 UTC [20] HINT:  Consider increasing the configuration parameter "max_wal_size".
2023-02-07 03:53:26.919 UTC [73823] ERROR:  value too long for type character varying(65536)
2023-02-07 03:53:26.919 UTC [73823] STATEMENT:  WITH "Asset__mutation_result_alias" AS (UPDATE "public"."Asset" SET "decimals" = ($1)::integer,"description" = ($2)::text,"logo" = ($3)::text,"metadataHash" = ($4)::bpchar,"name" = ($5)::text,"ticker" = ($6)::text,"url" = ($7)::text  WHERE (('true') AND ((((("public"."Asset"."assetId") = (($8)::bytea)) AND ('true')) AND ('true')) AND ('true'))) RETURNING * , CASE WHEN 'true' THEN NULL ELSE "hdb_catalog"."check_violation"('update check constraint failed')  END ), "Asset__all_columns_alias" AS (SELECT  "assetId" , "assetName" , "decimals" , "description" , "fingerprint" , "firstAppearedInSlot" , "logo" , "metadataHash" , "name" , "policyId" , "ticker" , "url"  FROM "Asset__mutation_result_alias"      ) SELECT  json_build_object('affected_rows', (SELECT  COUNT(*)  FROM "Asset__all_columns_alias"      ), 'returning', (SELECT  coalesce(json_agg("root" ), '[]' ) AS "root" FROM  (SELECT  row_to_json((SELECT  "_1_e"  FROM  (SELECT  "_0_root.base"."assetId" AS "assetId"       ) AS "_1_e"      ) ) AS "root" FROM  (SELECT  *  FROM "Asset__all_columns_alias" WHERE ('true')     ) AS "_0_root.base"      ) AS "_2_root"      ) )
2023-02-07 03:53:49.313 UTC [20] LOG:  checkpoints are occurring too frequently (29 seconds apart)
2023-02-07 03:53:49.313 UTC [20] HINT:  Consider increasing the configuration parameter "max_wal_size".
2023-02-07 03:56:51.173 UTC [74405] ERROR:  value too long for type character varying(65536)
2023-02-07 03:56:51.173 UTC [74405] STATEMENT:  WITH "Asset__mutation_result_alias" AS (UPDATE "public"."Asset" SET "decimals" = NULL,"description" = ($1)::text,"logo" = ($2)::text,"metadataHash" = ($3)::bpchar,"name" = ($4)::text,"ticker" = ($5)::text,"url" = ($6)::text  WHERE (('true') AND ((((("public"."Asset"."assetId") = (($7)::bytea)) AND ('true')) AND ('true')) AND ('true'))) RETURNING * , CASE WHEN 'true' THEN NULL ELSE "hdb_catalog"."check_violation"('update check constraint failed')  END ), "Asset__all_columns_alias" AS (SELECT  "assetId" , "assetName" , "decimals" , "description" , "fingerprint" , "firstAppearedInSlot" , "logo" , "metadataHash" , "name" , "policyId" , "ticker" , "url"  FROM "Asset__mutation_result_alias"      ) SELECT  json_build_object('affected_rows', (SELECT  COUNT(*)  FROM "Asset__all_columns_alias"      ), 'returning', (SELECT  coalesce(json_agg("root" ), '[]' ) AS "root" FROM  (SELECT  row_to_json((SELECT  "_1_e"  FROM  (SELECT  "_0_root.base"."assetId" AS "assetId"       ) AS "_1_e"      ) ) AS "root" FROM  (SELECT  *  FROM "Asset__all_columns_alias" WHERE ('true')     ) AS "_0_root.base"      ) AS "_2_root"      ) )
@lcgogo lcgogo added the question Further information is requested label Feb 7, 2023
@rhyslbw
Copy link
Contributor

rhyslbw commented Feb 7, 2023

What version are you running? Is this a fresh database? What snapshot are you pointing to?

@lcgogo
Copy link
Author

lcgogo commented Feb 8, 2023

What version are you running? Is this a fresh database? What snapshot are you pointing to?

I use cardano-graphql 7.0.2 with cardano-node-ogmios:v5.5.7_1.35.5-mainnet

Fresh database? Yes, I clean the old data.

snapshot I use RESTORE_SNAPSHOT=https://update-cardano-mainnet.iohk.io/cardano-db-sync/13/db-sync-snapshot-schema-13-block-8291499-x86_64.tgz

# docker ps
CONTAINER ID   IMAGE                                                                COMMAND                  CREATED      STATUS                PORTS                                                                                                           NAMES
a7df5a578127   inputoutput/cardano-db-sync:13.0.5                                   "/nix/store/3zay06dl…"   2 days ago   Up 2 days                                                                                                                             cardano-graphql_cardano-db-sync_1
421a39d36b50   inputoutput/cardano-graphql-hasura:7.0.2                             "docker-entrypoint.s…"   2 days ago   Up 2 days             0.0.0.0:8090->8080/tcp, :::8090->8080/tcp                                                                       cardano-graphql_hasura_1
7526328aaa3b   postgres:11.5-alpine                                                 "docker-entrypoint.s…"   2 days ago   Up 2 days             0.0.0.0:5432->5432/tcp, :::5432->5432/tcp                                                                       cardano-graphql_postgres_1
0335ba66579e   inputoutput/cardano-graphql:7.0.2-mainnet                            "node index.js"          2 days ago   Up 2 days             62044/tcp, 0.0.0.0:62044->3100/tcp, :::62044->3100/tcp                                                          ada_7.0.2
82a7cb30dfd9   cardanosolutions/cardano-node-ogmios:v5.5.7_1.35.5-mainnet           "/tini -g -- /root/c…"   2 days ago   Up 2 days (healthy)   3000/tcp, 12788/tcp, 12798/tcp, 0.0.0.0:62046->1337/tcp, :::62046->1337/tcp                                     cardano-graphql_cardano-node-ogmios_1

@lcgogo
Copy link
Author

lcgogo commented Feb 8, 2023

I see the 8.0.0 has been released. Will try to use 8.0.0 for a fresh init.

@rhyslbw
Copy link
Contributor

rhyslbw commented Feb 8, 2023

Yes, I suspect there was just a mismatch with the hosted database snapshot. We're planning to move to the latest version of cardano-db-sync once the impact of removing indexes is better understood and handled.

@timurgum
Copy link

timurgum commented Feb 9, 2023

on the recommended versions specified in the cardano GraphQL update, exactly the same error occurs, we tried to raise it from the cardano-db-sync snapshot and the error still occurs. What could be the reason? finally tried cardano-db-sync 13.1.0.0 same problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants