GraphQL
Query speed optimization (timeout)
By default, all queries have timeout. If you have timeout error - try to implement speedup strategy.
We use clickhouse with partition by gen_utime, shard, workchain.
- Always use time filters: gen_utime__gt and gen_utime__lt, use your business logic to find the right numbers. Do not run search on all TON transactions
- Use more filters. If you know that it's NFT item - use get method filter, for example. More filter = fewer results = faster search.
- Use less columns - query not all columns in database, just only needed ones.
Or you can buy a paid grade with longer calculation time here
- Omega: 2sec
- Gamma: 5sec
- Beta: 10sec
- Alpha: 15sec