[Bug] Very short retry timeout on 'Subgraph failed with non-deterministic error'

オープン
#5,664 コメント 1 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
25/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
postgresql, rust
領域
backend, databases

調査の方向性

レポートでは SubgraphInstanceManager、NotificationListener、EthereumPollingBlockIngestor、および PostgreSQL HA の failover エラーが挙げられています。まず、報告された非決定的な失敗に対する retry 処理を追跡してください。完了の条件は、retry ウィンドウを設定できるか、または説明されている failover の期間中それ以外の方法で維持でき、報告されたエラーに対して動作が検証されていることです。

索引モデルが issue の本文から書いたものです。

説明

bug Stale
Bug report

Hello!

subgraph version: 0.35.1

I see some of our subgraphs stop with the following error logs. The crux is that it stops retrying after 6 seconds!

As I understand, it is caused by HA Postgres doing a leader change or going through a fail-over.

Is there a way to make subgraph to retry for a larger time span? I have not found a setting for that. I think it should try for several hours.

Thank you!

Relevant log output
Oct 14 02:31:02.795 ERRO Subgraph failed with non-deterministic error: Failed to transact block operations: store error: cannot execute UPDATE in a read-only transaction, retry_delay_s: 135, attempt: 0, sgd: 39, subgraph_id: QmRLj4v8iRGBYfRaGPan45QzehUQxQzwrKBU514nEqNZSA, component: SubgraphInstanceManager
Oct 14 02:30:51.304 ERRO Failed to connect notification listener: error connecting to server: failed to lookup address information: Name or service not known, retry_delay_s: 8, attempt: 3, channel: store_events, component: NotificationListener
Oct 14 02:30:51.278 ERRO Failed to connect notification listener: error connecting to server: failed to lookup address information: Name or service not known, retry_delay_s: 8, attempt: 3, channel: chain_head_updates, component: ChainHeadUpdateListener > NotificationListener
Oct 14 02:30:51.086 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:50.341 ERRO Vacuum of subgraphs.subgraph_deployment failed: store error: cannot execute VACUUM during recovery, job: Vacuum subgraphs.subgraph_deployment, component: JobRunner
Oct 14 02:30:49.979 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:48.875 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:47.768 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:47.289 ERRO Failed to connect notification listener: db error: ERROR: cannot execute LISTEN during recovery, retry_delay_s: 4, attempt: 2, channel: store_events, component: NotificationListener
Oct 14 02:30:47.263 ERRO Failed to connect notification listener: db error: ERROR: cannot execute LISTEN during recovery, retry_delay_s: 4, attempt: 2, channel: chain_head_updates, component: ChainHeadUpdateListener > NotificationListener
Oct 14 02:30:46.651 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:45.524 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:45.228 ERRO Failed to connect notification listener: db error: ERROR: cannot execute LISTEN during recovery, retry_delay_s: 2, attempt: 1, channel: store_events, component: NotificationListener
Oct 14 02:30:45.199 ERRO Failed to connect notification listener: db error: ERROR: cannot execute LISTEN during recovery, retry_delay_s: 2, attempt: 1, channel: chain_head_updates, component: ChainHeadUpdateListener > NotificationListener
Oct 14 02:30:44.407 ERRO Trying again after block polling failed: Ingestor error: store error: cannot execute INSERT in a read-only transaction, provider: mainnet, component: EthereumPollingBlockIngestor
Oct 14 02:30:44.392 ERRO Subgraph instance failed to run: Failed to set subgraph status to `failed`: store error: cannot execute INSERT in a read-only transaction, sgd: 1, subgraph_id: QmP16jdXsZHFHgaxqUAVoTzHb5dhpfY83Tx2WfU3tvh3uo, component: SubgraphInstanceManager
IPFS hash

No response

Subgraph name or link to explorer

No response

Some information to help us out
  • Tick this box if this bug is caused by a regression found in the latest release.
  • Tick this box if this bug is specific to the hosted service.
  • I have searched the issue tracker to make sure this issue is not a duplicate.
OS information

Linux

主要言語
Rust
スター
3.2k
フォーク
1.1k
平均マージ
4日 1時間
マージ済み PR(30日)
1

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

graphprotocol/graph-node のほかの issue

graphprotocol/graph-node の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。