Developers Forum for XinFin XDC Network

SubQuery Network
SubQuery Network

Posted on • Updated on

[Informative] SubQuery’s Decentralised Data Indexer now supports XDC Network

We are thrilled to announce our integration support for XDC Network. SubQuery's indexing capabilities empower developers on XDC Network to efficiently manage and query on-chain data, expediting development processes and facilitating rapid iterations, ultimately advancing the goal of onboarding the next billion users to the blockchain.

Developers building on XDC Network can now harness SubQuery's versatile, high-speed, open, and decentralised data indexing solution. This empowers blockchain developers with crucial tools to efficiently manage and query on-chain data for their protocols and applications. Make sure to refer to the XDC Apothem quickstart guide to understand how to develop your first SubQuery indexer.

SubQuery simplifies the intricacies of backend operations, providing developers with a tailor-made API. This enables them to focus on product development and enhancing user experiences, without the need to allocate resources towards constructing their indexing solutions.

There are three hosting options when using SubQuery: you can use our open-sourced SDK and run it locally for free, you can used our enterprise level Managed Service, or you can truly decentralise your tech stack by running it on the SubQuery Network.

Discussion (3)

Collapse
shadabakhtar profile image
Shadab Akhtar

SubQuery Indexer Not Advancing Beyond Block 74655418 on Apothem Network (RPC 502/503 Errors)

We're currently running a SubQuery project to index data on the XDC Apothem network. However, we've hit a blocker where the indexer is stuck around block height ~74655418 and not progressing further. Here's some of the relevant logs:

<WorkerBlockDispatcherService> INFO Enqueueing blocks 74654819...74654918, total 100 blocks
...
<WorkerBlockDispatcherService> INFO Enqueueing blocks 74655419...74655518, total 100 blocks

Enter fullscreen mode Exit fullscreen mode

After this, the indexer doesn’t move forward. We’ve tried switching between different RPC endpoints:

earpc.apothem.network

erpc.apothem.network

rpc.apothem.network

But we consistently get 502 Bad Gateway or 503 Service Unavailable errors when SubQuery attempts to fetch blocks:

<FetchService> ERROR Having a problem when getting finalized block Error: bad response (status=502)
...
<title>502 Bad Gateway</title>

Enter fullscreen mode Exit fullscreen mode

We also attempted using the --unfinalized-block=true flag, and it prints:

<UnfinalizedBlocks> INFO Unfinalized blocks is enabled
Enter fullscreen mode Exit fullscreen mode

However, it eventually fails with:

<subql-node> ERROR undefined Error: Node failed to start
Cause: Error: Value at height 74654719 was undefined

Enter fullscreen mode Exit fullscreen mode

We even tried updating startBlock to a higher value (e.g., 75000000), but that caused a fatal error due to undefined block height.


What we've tried:

  • Switching between all public Apothem RPCs

  • Adding --unfinalized-block=true

  • Changing startBlock

  • Restarting the indexer container

Collapse
ncode profile image
ncode

Hi, Facing the below issue on doing subql init
Image

Collapse
sean_ profile image
Sean • Edited on

Can you try again?

Image description