cardano-graphql
cardano-graphql copied to clipboard
Refactor Asset Table and Background Service + GraphQL Schema Enhancements
Context:
The DB Sync already contains all token related in the in the multi_asset and associated tables.
A separate background service currently reprocesses this data (acting as a chain follower), fetches off-chain metadata from the Token Metadata Registry API, and populates the asset table used by GraphQL.
This results in data duplication and unnecessary complexity.
Proposal:
Eliminate the background service and asset table by directly joining multiasset and metadata tables from tokenregistry schema in Hasura.
Explore use of Hasura views or join query, with caution due to potential performance hits (views cannot be indexed).
Next steps:
-
Investigate if the background service is still required.
-
Prototype direct multiasset + metadata join in Hasura and benchmark performance.
-
Ensure data accuracy and validation during query response testing.