From 71d9713f25d3843a4331aaed7840fbbe428587e8 Mon Sep 17 00:00:00 2001 From: Daniel Werner Date: Wed, 30 Oct 2024 10:41:30 -0700 Subject: [PATCH 1/4] all: version bump for 0.21.6 --- docs/networks/arbitrum-sepolia.md | 4 ++-- lerna.json | 2 +- packages/indexer-agent/package.json | 2 +- packages/indexer-cli/package.json | 4 ++-- packages/indexer-common/package.json | 2 +- packages/indexer-native/package.json | 2 +- packages/indexer-service/package.json | 6 +++--- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/docs/networks/arbitrum-sepolia.md b/docs/networks/arbitrum-sepolia.md index 37bc1c2c2..128551e10 100644 --- a/docs/networks/arbitrum-sepolia.md +++ b/docs/networks/arbitrum-sepolia.md @@ -7,8 +7,8 @@ The Graph Network's testnet is on Arbitrum Sepolia (eip155:421614). Sepolia netw | Component | Release | | ------------------ | ------------------------------------------------------------------------------------ | | contracts | [5.3.3](https://github.com/graphprotocol/contracts/releases/tag/v5.3.3) | -| indexer-agent | [0.21.5](https://github.com/graphprotocol/indexer/releases/tag/v0.21.5) | -| indexer-cli | [0.21.5](https://github.com/graphprotocol/indexer/releases/tag/v0.21.5) | +| indexer-agent | [0.21.6](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6) | +| indexer-cli | [0.21.6](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6) | | indexer-service-rs | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) | | tap-agent | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) | | graph-node | [0.35.1](https://github.com/graphprotocol/graph-node/releases/tag/v0.35.1) | diff --git a/lerna.json b/lerna.json index 2c19e7d9d..1b5ccac41 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ ], "npmClient": "yarn", "useWorkspaces": true, - "version": "0.21.5" + "version": "0.21.6" } diff --git a/packages/indexer-agent/package.json b/packages/indexer-agent/package.json index 499ac5cc4..167079e46 100644 --- a/packages/indexer-agent/package.json +++ b/packages/indexer-agent/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-agent", - "version": "0.21.5", + "version": "0.21.6", "description": "Indexer agent", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/indexer-cli/package.json b/packages/indexer-cli/package.json index a116bb020..0c0d3a663 100644 --- a/packages/indexer-cli/package.json +++ b/packages/indexer-cli/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-cli", - "version": "0.21.5", + "version": "0.21.6", "description": "Indexer CLI for The Graph Network", "main": "./dist/cli.js", "files": [ @@ -27,7 +27,7 @@ }, "dependencies": { "@graphprotocol/common-ts": "2.0.10", - "@graphprotocol/indexer-common": "^0.21.5", + "@graphprotocol/indexer-common": "^0.21.6", "@iarna/toml": "2.2.5", "@thi.ng/iterators": "5.1.74", "@urql/core": "3.1.0", diff --git a/packages/indexer-common/package.json b/packages/indexer-common/package.json index dbf0052e4..e199ecb97 100644 --- a/packages/indexer-common/package.json +++ b/packages/indexer-common/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-common", - "version": "0.21.5", + "version": "0.21.6", "description": "Common library for Graph Protocol indexer components", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/indexer-native/package.json b/packages/indexer-native/package.json index c9aadcc14..9e3210a39 100644 --- a/packages/indexer-native/package.json +++ b/packages/indexer-native/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-native", - "version": "0.21.5", + "version": "0.21.6", "description": "Performance sensitive indexer code", "main": "./lib/index.js", "types": "./lib/index.d.ts", diff --git a/packages/indexer-service/package.json b/packages/indexer-service/package.json index 0c4b7f026..72d6af524 100644 --- a/packages/indexer-service/package.json +++ b/packages/indexer-service/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-service", - "version": "0.21.5", + "version": "0.21.6", "description": "Indexer service", "main": "./dist/index.js", "types": "./dist/index.d.ts", @@ -33,8 +33,8 @@ "dependencies": { "@google-cloud/profiler": "6.0.1", "@graphprotocol/common-ts": "2.0.10", - "@graphprotocol/indexer-common": "^0.21.5", - "@graphprotocol/indexer-native": "0.21.5", + "@graphprotocol/indexer-common": "^0.21.6", + "@graphprotocol/indexer-native": "0.21.6", "@graphql-tools/load": "8.0.0", "@graphql-tools/url-loader": "8.0.0", "@graphql-tools/wrap": "10.0.1", From 1bf144e0f23e9c60fdd597ac3cf334e401351ef9 Mon Sep 17 00:00:00 2001 From: Daniel Werner Date: Wed, 30 Oct 2024 13:27:36 -0700 Subject: [PATCH 2/4] Revert "common: remove paused workaround (perf)" This reverts commit f2cd527532534b2bcf237c711f76e7d89e2bd624. --- packages/indexer-common/src/graph-node.ts | 33 +++++++++++++++++++++-- 1 file changed, 31 insertions(+), 2 deletions(-) diff --git a/packages/indexer-common/src/graph-node.ts b/packages/indexer-common/src/graph-node.ts index ca0995b12..9e47d6616 100644 --- a/packages/indexer-common/src/graph-node.ts +++ b/packages/indexer-common/src/graph-node.ts @@ -153,14 +153,16 @@ export class GraphNode { ): Promise { try { this.logger.debug('Fetch subgraph deployment assignments') - const result = await this.status + + // FIXME: remove this initial check for just node when graph-node releases + // https://github.com/graphprotocol/graph-node/pull/5551 + const nodeOnlyResult = await this.status .query( gql` { indexingStatuses { subgraphDeployment: subgraph node - paused } } `, @@ -168,6 +170,33 @@ export class GraphNode { ) .toPromise() + if (nodeOnlyResult.error) { + throw nodeOnlyResult.error + } + + const withAssignments: string[] = nodeOnlyResult.data.indexingStatuses + .filter((result: QueryResult) => { + return result.node !== null && result.node !== undefined + }) + .map((result: QueryResult) => { + return result.subgraphDeployment + }) + + const result = await this.status + .query( + gql` + query indexingStatuses($subgraphs: [String!]!) { + indexingStatuses(subgraphs: $subgraphs) { + subgraphDeployment: subgraph + node + paused + } + } + `, + { subgraphs: withAssignments }, + ) + .toPromise() + if (result.error) { throw result.error } From c0c117c05d09ab5e2873125c5be7f76dde59f19b Mon Sep 17 00:00:00 2001 From: Daniel Werner Date: Wed, 30 Oct 2024 13:38:26 -0700 Subject: [PATCH 3/4] Version bump for v0.21.6-2 --- lerna.json | 2 +- packages/indexer-agent/package.json | 4 ++-- packages/indexer-cli/package.json | 4 ++-- packages/indexer-common/package.json | 2 +- packages/indexer-service/package.json | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lerna.json b/lerna.json index 1b5ccac41..bff2576e3 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ ], "npmClient": "yarn", "useWorkspaces": true, - "version": "0.21.6" + "version": "0.21.6-2" } diff --git a/packages/indexer-agent/package.json b/packages/indexer-agent/package.json index 167079e46..5d1216d34 100644 --- a/packages/indexer-agent/package.json +++ b/packages/indexer-agent/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-agent", - "version": "0.21.6", + "version": "0.21.6-2", "description": "Indexer agent", "main": "./dist/index.js", "types": "./dist/index.d.ts", @@ -30,7 +30,7 @@ }, "dependencies": { "@graphprotocol/common-ts": "2.0.10", - "@graphprotocol/indexer-common": "^0.21.4", + "@graphprotocol/indexer-common": "^0.21.6-2", "@thi.ng/heaps": "^1.3.1", "@uniswap/sdk": "3.0.3", "axios": "0.26.1", diff --git a/packages/indexer-cli/package.json b/packages/indexer-cli/package.json index 0c0d3a663..d0ab4e7f2 100644 --- a/packages/indexer-cli/package.json +++ b/packages/indexer-cli/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-cli", - "version": "0.21.6", + "version": "0.21.6-2", "description": "Indexer CLI for The Graph Network", "main": "./dist/cli.js", "files": [ @@ -27,7 +27,7 @@ }, "dependencies": { "@graphprotocol/common-ts": "2.0.10", - "@graphprotocol/indexer-common": "^0.21.6", + "@graphprotocol/indexer-common": "^0.21.6-2", "@iarna/toml": "2.2.5", "@thi.ng/iterators": "5.1.74", "@urql/core": "3.1.0", diff --git a/packages/indexer-common/package.json b/packages/indexer-common/package.json index e199ecb97..3cf75f218 100644 --- a/packages/indexer-common/package.json +++ b/packages/indexer-common/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-common", - "version": "0.21.6", + "version": "0.21.6-2", "description": "Common library for Graph Protocol indexer components", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/indexer-service/package.json b/packages/indexer-service/package.json index 72d6af524..8a7bb879a 100644 --- a/packages/indexer-service/package.json +++ b/packages/indexer-service/package.json @@ -1,6 +1,6 @@ { "name": "@graphprotocol/indexer-service", - "version": "0.21.6", + "version": "0.21.6-2", "description": "Indexer service", "main": "./dist/index.js", "types": "./dist/index.d.ts", @@ -33,7 +33,7 @@ "dependencies": { "@google-cloud/profiler": "6.0.1", "@graphprotocol/common-ts": "2.0.10", - "@graphprotocol/indexer-common": "^0.21.6", + "@graphprotocol/indexer-common": "^0.21.6-2", "@graphprotocol/indexer-native": "0.21.6", "@graphql-tools/load": "8.0.0", "@graphql-tools/url-loader": "8.0.0", From a65420969fe983b194d746a65151d5922e3a4035 Mon Sep 17 00:00:00 2001 From: Daniel Werner Date: Wed, 30 Oct 2024 13:42:51 -0700 Subject: [PATCH 4/4] update docs for 0.21.6-2 --- docs/networks/arbitrum-sepolia.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/networks/arbitrum-sepolia.md b/docs/networks/arbitrum-sepolia.md index 128551e10..14c010454 100644 --- a/docs/networks/arbitrum-sepolia.md +++ b/docs/networks/arbitrum-sepolia.md @@ -7,8 +7,8 @@ The Graph Network's testnet is on Arbitrum Sepolia (eip155:421614). Sepolia netw | Component | Release | | ------------------ | ------------------------------------------------------------------------------------ | | contracts | [5.3.3](https://github.com/graphprotocol/contracts/releases/tag/v5.3.3) | -| indexer-agent | [0.21.6](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6) | -| indexer-cli | [0.21.6](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6) | +| indexer-agent | [0.21.6-2](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6-2) | +| indexer-cli | [0.21.6-2](https://github.com/graphprotocol/indexer/releases/tag/v0.21.6-2) | | indexer-service-rs | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) | | tap-agent | [1.0.0](https://github.com/graphprotocol/indexer-rs/releases/tag/v1.0.0) | | graph-node | [0.35.1](https://github.com/graphprotocol/graph-node/releases/tag/v0.35.1) |