Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions website/src/pages/en/indexing/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ The `queryFeeCut` and `indexingRewardCut` values are delegation parameters that

Indexers may differentiate themselves by applying advanced techniques for making Subgraph indexing decisions but to give a general idea we'll discuss several key metrics used to evaluate Subgraphs in the network:

- **Curation signal** - The proportion of network curation signal applied to a particular Subgraph is a good indicator of the interest in that Subgraph, especially during the bootstrap phase when query voluming is ramping up.
- **Curation signal** - The proportion of network curation signal applied to a particular Subgraph is a good indicator of the interest in that Subgraph, especially during the bootstrap phase when query volume is ramping up.

- **Query fees collected** - The historical data for volume of query fees collected for a specific Subgraph is a good indicator of future demand.

Expand Down Expand Up @@ -784,7 +784,7 @@ Once an Indexer has staked GRT in the protocol, the [Indexer components](/indexi

7. (Optional) Indexers may approve another address to be the operator for their Indexer infrastructure in order to separate the keys that control the funds from those that are performing day to day actions such as allocating on Subgraphs and serving (paid) queries. In order to set the operator call `setOperator()` with the operator address.

8. (Optional) In order to control the distribution of rewards and strategically attract Delegators Indexers can update their delegation parameters by updating their indexingRewardCut (parts per million), queryFeeCut (parts per million), and cooldownBlocks (number of blocks). To do so call `setDelegationParameters()`. The following example sets the queryFeeCut to distribute 95% of query rebates to the Indexer and 5% to Delegators, set the indexingRewardCutto distribute 60% of indexing rewards to the Indexer and 40% to Delegators, and set `thecooldownBlocks` period to 500 blocks.
8. (Optional) In order to control the distribution of rewards and strategically attract Delegators Indexers can update their delegation parameters by updating their `indexingRewardCut` (parts per million), `queryFeeCut` (parts per million), and `cooldownBlocks` (number of blocks). To do so call `setDelegationParameters()`. The following example sets the `queryFeeCut` to distribute 95% of query rebates to the Indexer and 5% to Delegators, set the `indexingRewardCut` to distribute 60% of indexing rewards to the Indexer and 40% to Delegators, and set the `cooldownBlocks` period to 500 blocks.

```
setDelegationParameters(950000, 600000, 500)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ title: Supported Network Requirements
| --- | --- | --- | :-: |
| Arbitrum | [Baremetal Guide](https://docs.infradao.com/archive-nodes-101/arbitrum/baremetal)<br /> [Docker Guide](https://docs.infradao.com/archive-nodes-101/arbitrum/docker) | 4+ core CPU<br /> Ubuntu 22.04<br /> 16GB+ RAM<br /> >= 8 TiB NVMe SSD<br /> _last updated August 2023_ | ✅ |
| Avalanche | [Docker Guide](https://docs.infradao.com/archive-nodes-101/avalanche/docker) | 4 core / 8 threads CPU<br /> Ubuntu 22.04<br /> 16GB+ RAM<br /> >= 5 TiB NVMe SSD<br /> _last updated August 2023_ | ✅ |
| Base | [Erigon Baremetal Guide](https://docs.infradao.com/archive-nodes-101/base/erigon/baremetal)<br /><br /> [GETH Baremetal Guide](https://docs.infradao.com/archive-nodes-101/base/geth/baremetal)<br /> [GETH Docker Guide](https://docs.infradao.com/archive-nodes-101/base/geth/docker) | 8+ core CPU<br /> Debian 12/Ubuntu 22.04<br /> 16 GB RAM<br /> >= 4.5TB (NVME preffered)<br /> _last updated 14th May 2024_ | ✅ |
| Base | [Erigon Baremetal Guide](https://docs.infradao.com/archive-nodes-101/base/erigon/baremetal)<br /><br /> [GETH Baremetal Guide](https://docs.infradao.com/archive-nodes-101/base/geth/baremetal)<br /> [GETH Docker Guide](https://docs.infradao.com/archive-nodes-101/base/geth/docker) | 8+ core CPU<br /> Debian 12/Ubuntu 22.04<br /> 16 GB RAM<br /> >= 4.5TB (NVME preferred)<br /> _last updated 14th May 2024_ | ✅ |
| Binance | [Erigon Baremetal Guide](https://docs.infradao.com/archive-nodes-101/binance/erigon/baremetal) | 8 core / 16 threads CPU<br /> Ubuntu 22.04<br /> >=32 GB RAM<br /> >= 14 TiB NVMe SSD<br /> _last updated 22nd June 2024_ | ✅ |
| Celo | [Docker Guide](https://docs.infradao.com/archive-nodes-101/celo/docker) | 4 core / 8 threads CPU<br /> Ubuntu 22.04<br /> 16GB+ RAM<br /> >= 2 TiB NVMe SSD<br /> _last updated August 2023_ | ✅ |
| Ethereum | [Docker Guide](https://docs.infradao.com/archive-nodes-101/ethereum/erigon/docker) | Higher clock speed over core count<br /> Ubuntu 22.04<br /> 16GB+ RAM<br /> >=3TB (NVMe recommended)<br /> _last updated August 2023_ | ✅ |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@ This guide is applicable for anyone using `graph-cli`/`graph-ts` below version `

## How to upgrade?

1. Change your mappings `apiVersion` in `subgraph.yaml` to `0.0.6`:
1. Change your mappings `apiVersion` in `subgraph.yaml` to `0.0.9`:

```yaml
...
dataSources:
...
mapping:
...
apiVersion: 0.0.6
apiVersion: 0.0.9
...
```

Expand Down
2 changes: 1 addition & 1 deletion website/src/pages/en/sps/tutorial.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ dataSources:
moduleName: map_spl_transfers # Module defined in the substreams.yaml
file: ./my-project-sol-v0.1.0.spkg
mapping:
apiVersion: 0.0.7
apiVersion: 0.0.9
kind: substreams/graph-entities
file: ./src/mappings.ts
handler: handleTriggers
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Suppose you have a Subgraph tracking a smart contract that has stopped indexing
1. **Failed Subgraph Manifest (subgraph.yaml)**

```yaml
specVersion: 1.0.0
specVersion: 1.3.0
schema:
file: ./schema.graphql
dataSources:
Expand All @@ -75,7 +75,7 @@ Suppose you have a Subgraph tracking a smart contract that has stopped indexing
startBlock: 5000000
mapping:
kind: ethereum/events
apiVersion: 0.0.7
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Withdrawal
Expand All @@ -90,7 +90,7 @@ Suppose you have a Subgraph tracking a smart contract that has stopped indexing

2. **New Grafted Subgraph Manifest (subgraph.yaml)**
```yaml
specVersion: 1.0.0
specVersion: 1.3.0
schema:
file: ./schema.graphql
dataSources:
Expand All @@ -103,7 +103,7 @@ Suppose you have a Subgraph tracking a smart contract that has stopped indexing
startBlock: 6000001 # Block after the last indexed block
mapping:
kind: ethereum/events
apiVersion: 0.0.7
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Withdrawal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Add a section called `indexerHints` in the manifest.
We can add `indexerHints` to our Subgraphs by updating our `subgraph.yaml`:

```yaml
specVersion: 1.0.0
specVersion: 1.3.0
schema:
file: ./schema.graphql
indexerHints:
Expand Down
4 changes: 2 additions & 2 deletions website/src/pages/en/subgraphs/cookbook/arweave.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ $ graph build # generates Web Assembly from the AssemblyScript files, and prepar
The Subgraph manifest `subgraph.yaml` identifies the data sources for the Subgraph, the triggers of interest, and the functions that should be run in response to those triggers. See below for an example Subgraph manifest for an Arweave Subgraph:

```yaml
specVersion: 0.0.5
specVersion: 1.3.0
description: Arweave Blocks Indexing
schema:
file: ./schema.graphql # link to the schema file
Expand All @@ -70,7 +70,7 @@ dataSources:
owner: 'ID-OF-AN-OWNER' # The public key of an Arweave wallet
startBlock: 0 # set this to 0 to start indexing from chain genesis
mapping:
apiVersion: 0.0.5
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/blocks.ts # link to the file with the Assemblyscript mappings
entities:
Expand Down
4 changes: 2 additions & 2 deletions website/src/pages/en/subgraphs/cookbook/grafting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Building Subgraphs is an essential part of The Graph, described more in depth [h
The Subgraph manifest `subgraph.yaml` identifies the data sources for the Subgraph, the triggers of interest, and the functions that should be run in response to those triggers. See below for an example Subgraph manifest that you will use:

```yaml
specVersion: 0.0.4
specVersion: 1.3.0
schema:
file: ./schema.graphql
dataSources:
Expand All @@ -66,7 +66,7 @@ dataSources:
startBlock: 5955690
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Withdrawal
Expand Down
4 changes: 2 additions & 2 deletions website/src/pages/en/subgraphs/cookbook/near.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ $ graph build # generates Web Assembly from the AssemblyScript files, and prepar
The Subgraph manifest (`subgraph.yaml`) identifies the data sources for the Subgraph, the triggers of interest, and the functions that should be run in response to those triggers. See below for an example Subgraph manifest for a NEAR Subgraph:

```yaml
specVersion: 0.0.2
specVersion: 1.3.0
schema:
file: ./src/schema.graphql # link to the schema file
dataSources:
Expand All @@ -61,7 +61,7 @@ dataSources:
account: app.good-morning.near # This data source will monitor this account
startBlock: 10662188 # Required for NEAR
mapping:
apiVersion: 0.0.5
apiVersion: 0.0.9
language: wasm/assemblyscript
blockHandlers:
- handler: handleNewBlock # the function name in the mapping file
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Tranfer to The Graph
title: Transfer to The Graph
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, funny how we never noticed that before.

---

Quickly upgrade your Subgraphs from any platform to [The Graph's decentralized network](https://thegraph.com/networks/).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Starting from `specVersion` `0.0.4`, Subgraph features must be explicitly declar
For instance, if a Subgraph uses the **Full-Text Search** and the **Non-fatal Errors** features, the `features` field in the manifest should be:

```yaml
specVersion: 0.0.4
specVersion: 1.3.0
description: Gravatar for Ethereum
features:
- fullTextSearch
Expand Down Expand Up @@ -104,7 +104,7 @@ Indexing errors on already synced Subgraphs will, by default, cause the Subgraph
Enabling non-fatal errors requires setting the following feature flag on the Subgraph manifest:

```yaml
specVersion: 0.0.4
specVersion: 1.3.0
description: Gravatar for Ethereum
features:
- nonFatalErrors
Expand Down Expand Up @@ -221,7 +221,7 @@ templates:
- name: TokenMetadata
kind: file/ipfs
mapping:
apiVersion: 0.0.7
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/mapping.ts
handler: handleMetadata
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ The full specification for Subgraph manifests can be found [here](https://github
For the example Subgraph listed above, `subgraph.yaml` is:

```yaml
specVersion: 0.0.4
specVersion: 1.3.0
description: Gravatar for Ethereum
repository: https://github.com/graphprotocol/graph-tooling
schema:
Expand All @@ -54,7 +54,7 @@ dataSources:
data: 'bar'
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Gravatar
Expand Down Expand Up @@ -83,7 +83,7 @@ dataSources:

The important entries to update for the manifest are:

- `specVersion`: a semver version that identifies the supported manifest structure and functionality for the Subgraph. The latest version is `1.2.0`. See [specVersion releases](#specversion-releases) section to see more details on features & releases.
- `specVersion`: a semver version that identifies the supported manifest structure and functionality for the Subgraph. The latest version is `1.3.0`. See [specVersion releases](#specversion-releases) section to see more details on features & releases.

- `description`: a human-readable description of what the Subgraph is. This description is displayed in Graph Explorer when the Subgraph is deployed to Subgraph Studio.

Expand Down Expand Up @@ -131,7 +131,7 @@ dataSources:
abi: Gravity
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Gravatar
Expand Down Expand Up @@ -169,7 +169,7 @@ dataSources:
abi: Gravity
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Gravatar
Expand Down Expand Up @@ -232,7 +232,7 @@ dataSources:
abi: Gravity
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
entities:
- Gravatar
Expand Down Expand Up @@ -360,7 +360,7 @@ dataSources:
abi: Factory
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/mappings/factory.ts
entities:
Expand Down Expand Up @@ -390,7 +390,7 @@ templates:
abi: Exchange
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/mappings/exchange.ts
entities:
Expand Down Expand Up @@ -467,7 +467,7 @@ dataSources:
startBlock: 6627917
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/mappings/factory.ts
entities:
Expand Down Expand Up @@ -537,12 +537,13 @@ indexerHints:

| Version | Release notes |
| :-: | --- |
| 1.2.0 | Added support for [Indexed Argument Filtering](/#indexed-argument-filters--topic-filters) & declared `eth_call` |
| 1.1.0 | Supports [Timeseries & Aggregations](#timeseries-and-aggregations). Added support for type `Int8` for `id`. |
| 1.0.0 | Supports [`indexerHints`](/developing/creating-a-subgraph/#indexer-hints) feature to prune Subgraphs |
| 1.3.0 | Added support for [Subgraph Composition](/cookbook/subgraph-composition-three-sources) |
| 1.2.0 | Added support for [Indexed Argument Filtering](/developing/creating/advanced/#indexed-argument-filters--topic-filters) & declared `eth_call` |
| 1.1.0 | Supports [Timeseries & Aggregations](/developing/creating/advanced/#timeseries-and-aggregations). Added support for type `Int8` for `id`. |
| 1.0.0 | Supports [`indexerHints`](/developing/creating/subgraph-manifest/#indexer-hints) feature to prune Subgraphs |
| 0.0.9 | Supports `endBlock` feature |
| 0.0.8 | Added support for polling [Block Handlers](/developing/creating-a-subgraph/#polling-filter) and [Initialisation Handlers](/developing/creating-a-subgraph/#once-filter). |
| 0.0.7 | Added support for [File Data Sources](/developing/creating-a-subgraph/#file-data-sources). |
| 0.0.8 | Added support for polling [Block Handlers](/developing/creating/subgraph-manifest/#polling-filter) and [Initialisation Handlers](/developing/creating/subgraph-manifest/#once-filter). |
| 0.0.7 | Added support for [File Data Sources](/developing/creating/advanced/#ipfsarweave-file-data-sources). |
| 0.0.6 | Supports fast [Proof of Indexing](/indexing/overview/#what-is-a-proof-of-indexing-poi) calculation variant. |
| 0.0.5 | Added support for event handlers having access to transaction receipts. |
| 0.0.4 | Added support for managing subgraph features. |
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ Also you can check out the video series on ["How to use Matchstick to write unit

## Tests structure

_**IMPORTANT: The test structure described below depens on `matchstick-as` version >=0.5.0**_
_**IMPORTANT: The test structure described below depends on `matchstick-as` version >=0.5.0**_

### describe()

Expand Down Expand Up @@ -756,7 +756,7 @@ createMockedFunction(contractAddress, 'getGravatar', 'getGravatar(address):(stri

Users can mock IPFS files by using `mockIpfsFile(hash, filePath)` function. The function accepts two arguments, the first one is the IPFS file hash/path and the second one is the path to a local file.

NOTE: When testing `ipfs.map/ipfs.mapJSON`, the callback function must be exported from the test file in order for matchstck to detect it, like the `processGravatar()` function in the test example bellow:
NOTE: When testing `ipfs.map/ipfs.mapJSON`, the callback function must be exported from the test file in order for matchstick to detect it, like the `processGravatar()` function in the test example bellow:

`.test.ts` file:

Expand All @@ -765,7 +765,7 @@ import { assert, test, mockIpfsFile } from 'matchstick-as/assembly/index'
import { ipfs } from '@graphprotocol/graph-ts'
import { gravatarFromIpfs } from './utils'

// Export ipfs.map() callback in order for matchstck to detect it
// Export ipfs.map() callback in order for matchstick to detect it
export { processGravatar } from './utils'

test('ipfs.cat', () => {
Expand Down Expand Up @@ -1172,7 +1172,7 @@ templates:
network: mainnet
mapping:
kind: ethereum/events
apiVersion: 0.0.6
apiVersion: 0.0.9
language: wasm/assemblyscript
file: ./src/token-lock-wallet.ts
handler: handleMetadata
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ All `fetch` strategies can be combined to create the ultimate execution flow.

The `retry` mechanism allow you to specify the retry attempts for a single GraphQL endpoint/source.

The retry flow will execute in both conditions: a netword error, or due to a runtime error (indexing issue/inavailability of the indexer).
The retry flow will execute in both conditions: a network error, or due to a runtime error (indexing issue/unavailability of the indexer).

```yaml
sources:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@ query ExampleQuery @live(interval: 5000) {

## Integrations

Since the entire network layer (along with the `@live` mechanism) is implemented inside `graph-client` core, you can use Live queries with every GraphQL client (such as Urql or Apollo-Client), as long as it supports streame responses (`AsyncIterable`).
Since the entire network layer (along with the `@live` mechanism) is implemented inside `graph-client` core, you can use Live queries with every GraphQL client (such as Urql or Apollo-Client), as long as it supports stream responses (`AsyncIterable`).

No additional setup is required for GraphQL clients cache updates.
2 changes: 1 addition & 1 deletion website/src/pages/en/substreams/publishing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ A Substreams package is a precompiled binary file that defines the specific data

![confirm](/img/4_confirm.png)

That's it! You have succesfully published a package in the Substreams registry.
That's it! You have successfully published a package in the Substreams registry.

![success](/img/5_success.png)

Expand Down