You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/pages/en/cookbook/cosmos.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ This guide is an introduction on building subgraphs indexing [Cosmos](https://co
6
6
7
7
## What are Cosmos subgraphs?
8
8
9
-
The Graph allows developers to process blockchain events and make the resulting data easily available via an open GraphQL API, known as a subgraph. [Graph Node](https://github.com/graphprotocol/graph-node) is now able to process Cosmos events, which means Cosmos developers can now build subgraphs to easily index on-chain events.
9
+
The Graph allows developers to process blockchain events and make the resulting data easily available via an open GraphQL API, known as a subgraph. [Graph Node](https://github.com/graphprotocol/graph-node) is now able to process Cosmos events, which means Cosmos developers can now build subgraphs to easily index onchain events.
10
10
11
11
There are four types of handlers supported in Cosmos subgraphs:
Copy file name to clipboardExpand all lines: website/pages/en/cookbook/near.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ This guide is an introduction to building subgraphs indexing smart contracts on
12
12
13
13
The Graph gives developers tools to process blockchain events and make the resulting data easily available via a GraphQL API, known individually as a subgraph. [Graph Node](https://github.com/graphprotocol/graph-node) is now able to process NEAR events, which means that NEAR developers can now build subgraphs to index their smart contracts.
14
14
15
-
Subgraphs are event-based, which means that they listen for and then process on-chain events. There are currently two types of handlers supported for NEAR subgraphs:
15
+
Subgraphs are event-based, which means that they listen for and then process onchain events. There are currently two types of handlers supported for NEAR subgraphs:
16
16
17
17
- Block handlers: these are run on every new block
18
18
- Receipt handlers: run every time a message is executed at a specified account
Copy file name to clipboardExpand all lines: website/pages/en/deploying/deploy-using-subgraph-studio.mdx
+2-2
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ title: Deploy Using Subgraph Studio
4
4
5
5
Learn how to deploy your subgraph to Subgraph Studio.
6
6
7
-
> Note: When you deploy a subgraph, you push it to Subgraph Studio, where you'll be able to test it. It's important to remember that deploying is not the same as publishing. When you publish a subgraph, you're publishing it on-chain.
7
+
> Note: When you deploy a subgraph, you push it to Subgraph Studio, where you'll be able to test it. It's important to remember that deploying is not the same as publishing. When you publish a subgraph, you're publishing it onchain.
8
8
9
9
## Subgraph Studio Overview
10
10
@@ -124,7 +124,7 @@ If you want to update your subgraph, you can do the following:
124
124
- Once you're happy with it, you can publish your new deployment to [Graph Explorer](https://thegraph.com/explorer).
125
125
- This action will create a new version of your subgraph that Curators can start signaling on and Indexers can index.
126
126
127
-
You can also update your subgraph's metadata without publishing a new version. You can update your subgraph details in Studio (under the profile picture, name, description, etc.) by checking an option called **Update Details** in [Graph Explorer](https://thegraph.com/explorer). If this is checked, an on-chain transaction will be generated that updates subgraph details in Explorer without having to publish a new version with a new deployment.
127
+
You can also update your subgraph's metadata without publishing a new version. You can update your subgraph details in Studio (under the profile picture, name, description, etc.) by checking an option called **Update Details** in [Graph Explorer](https://thegraph.com/explorer). If this is checked, an onchain transaction will be generated that updates subgraph details in Explorer without having to publish a new version with a new deployment.
128
128
129
129
> Note: There are costs associated with publishing a new version of a subgraph to the network. In addition to the transaction fees, you must also fund a part of the curation tax on the auto-migrating signal. You cannot publish a new version of your subgraph if Curators have not signaled on it. For more information, please read more [here](/network/curating/).
Copy file name to clipboardExpand all lines: website/pages/en/developing/creating-a-subgraph/subgraph-manifest.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -348,7 +348,7 @@ The addresses of these sub-contracts may or may not be known upfront and many of
348
348
349
349
### Data Source for the Main Contract
350
350
351
-
First, you define a regular data source for the main contract. The snippet below shows a simplified example data source for the [Uniswap](https://uniswap.org) exchange factory contract. Note the `NewExchange(address,address)` event handler. This is emitted when a new exchange contract is created on-chain by the factory contract.
351
+
First, you define a regular data source for the main contract. The snippet below shows a simplified example data source for the [Uniswap](https://uniswap.org) exchange factory contract. Note the `NewExchange(address,address)` event handler. This is emitted when a new exchange contract is created onchain by the factory contract.
Copy file name to clipboardExpand all lines: website/pages/en/developing/graph-ts/api.mdx
+2-2
Original file line number
Diff line number
Diff line change
@@ -274,7 +274,7 @@ As the entity may not exist in the store yet, the `load` method returns a value
274
274
275
275
As of `graph-node` v0.31.0, `@graphprotocol/graph-ts` v0.30.0 and `@graphprotocol/graph-cli` v0.49.0 the `loadInBlock` method is available on all entity types.
276
276
277
-
The store API facilitates the retrieval of entities that were created or updated in the current block. A typical situation for this is that one handler creates a transaction from some on-chain event, and a later handler wants to access this transaction if it exists.
277
+
The store API facilitates the retrieval of entities that were created or updated in the current block. A typical situation for this is that one handler creates a transaction from some onchain event, and a later handler wants to access this transaction if it exists.
278
278
279
279
- In the case where the transaction does not exist, the subgraph will have to go to the database simply to find out that the entity does not exist. If the subgraph author already knows that the entity must have been created in the same block, using `loadInBlock` avoids this database roundtrip.
280
280
- For some subgraphs, these missed lookups can contribute significantly to the indexing time.
@@ -666,7 +666,7 @@ export function handleSomeEvent(event: SomeEvent): void {
666
666
import { ipfs } from'@graphprotocol/graph-ts'
667
667
```
668
668
669
-
Smart contracts occasionally anchor IPFS files on chain. This allows mappings to obtain the IPFS hashes from the contract and read the corresponding files from IPFS. The file data will be returned as `Bytes`, which usually requires further processing, e.g. with the `json` API documented later on this page.
669
+
Smart contracts occasionally anchor IPFS files onchain. This allows mappings to obtain the IPFS hashes from the contract and read the corresponding files from IPFS. The file data will be returned as `Bytes`, which usually requires further processing, e.g. with the `json` API documented later on this page.
670
670
671
671
Given an IPFS hash or path, reading a file from IPFS is done as follows:
Copy file name to clipboardExpand all lines: website/pages/en/developing/substreams-powered-subgraphs-faq.mdx
+2-2
Original file line number
Diff line number
Diff line change
@@ -16,9 +16,9 @@ If you are already familiar with subgraph development, then note that Substreams
16
16
17
17
## How are Substreams-powered subgraphs different from subgraphs?
18
18
19
-
Subgraphs are made up of datasources which specify on-chain events, and how those events should be transformed via handlers written in Assemblyscript. These events are processed sequentially, based on the order in which events happen on-chain.
19
+
Subgraphs are made up of datasources which specify onchain events, and how those events should be transformed via handlers written in Assemblyscript. These events are processed sequentially, based on the order in which events happen onchain.
20
20
21
-
By contrast, substreams-powered subgraphs have a single datasource which references a substreams package, which is processed by the Graph Node. Substreams have access to additional granular on-chain data compared to conventional subgraphs, and can also benefit from massively parallelised processing, which can mean much faster processing times.
21
+
By contrast, substreams-powered subgraphs have a single datasource which references a substreams package, which is processed by the Graph Node. Substreams have access to additional granular onchain data compared to conventional subgraphs, and can also benefit from massively parallelised processing, which can mean much faster processing times.
22
22
23
23
## What are the benefits of using Substreams-powered subgraphs?
Copy file name to clipboardExpand all lines: website/pages/en/glossary.mdx
+2-2
Original file line number
Diff line number
Diff line change
@@ -42,7 +42,7 @@ title: Glossary
42
42
43
43
-**Allocation**: An Indexer can allocate their total GRT stake (including Delegators' stake) towards subgraphs that have been published on The Graph's decentralized network. Allocations can have different statuses:
44
44
45
-
1.**Active**: An allocation is considered active when it is created on-chain. This is called opening an allocation, and indicates to the network that the Indexer is actively indexing and serving queries for a particular subgraph. Active allocations accrue indexing rewards proportional to the signal on the subgraph, and the amount of GRT allocated.
45
+
1.**Active**: An allocation is considered active when it is created onchain. This is called opening an allocation, and indicates to the network that the Indexer is actively indexing and serving queries for a particular subgraph. Active allocations accrue indexing rewards proportional to the signal on the subgraph, and the amount of GRT allocated.
46
46
47
47
2.**Closed**: An Indexer may claim the accrued indexing rewards on a given subgraph by submitting a recent, and valid, Proof of Indexing (POI). This is known as closing an allocation. An allocation must have been open for a minimum of one epoch before it can be closed. The maximum allocation period is 28 epochs. If an Indexer leaves an allocation open beyond 28 epochs, it is known as a stale allocation. When an allocation is in the **Closed** state, a Fisherman can still open a dispute to challenge an Indexer for serving false data.
48
48
@@ -64,7 +64,7 @@ title: Glossary
64
64
65
65
-**Graph Node**: Graph Node is the component that indexes subgraphs and makes the resulting data available to query via a GraphQL API. As such it is central to the Indexer stack, and correct operation of Graph Node is crucial to running a successful Indexer.
66
66
67
-
-**Indexer agent**: The Indexer agent is part of the Indexer stack. It facilitates the Indexer's interactions on-chain, including registering on the network, managing subgraph deployments to its Graph Node(s), and managing allocations.
67
+
-**Indexer agent**: The Indexer agent is part of the Indexer stack. It facilitates the Indexer's interactions onchain, including registering on the network, managing subgraph deployments to its Graph Node(s), and managing allocations.
68
68
69
69
-**The Graph Client**: A library for building GraphQL-based dapps in a decentralized way.
Copy file name to clipboardExpand all lines: website/pages/en/network/curating.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -68,7 +68,7 @@ Finding high-quality subgraphs is a complex task, but it can be approached in ma
68
68
69
69
### 3. What’s the cost of updating a subgraph?
70
70
71
-
Migrating your curation shares to a new subgraph version incurs a curation tax of 1%. Curators can choose to subscribe to the newest version of a subgraph. When curator shares get auto-migrated to a new version, Curators will also pay half curation tax, ie. 0.5%, because upgrading subgraphs is an on-chain action that costs gas.
71
+
Migrating your curation shares to a new subgraph version incurs a curation tax of 1%. Curators can choose to subscribe to the newest version of a subgraph. When curator shares get auto-migrated to a new version, Curators will also pay half curation tax, ie. 0.5%, because upgrading subgraphs is an onchain action that costs gas.
Copy file name to clipboardExpand all lines: website/pages/en/network/indexing.mdx
+5-5
Original file line number
Diff line number
Diff line change
@@ -137,7 +137,7 @@ At the center of an Indexer's infrastructure is the Graph Node which monitors th
137
137
138
138
-**Indexer service** - Handles all required external communications with the network. Shares cost models and indexing statuses, passes query requests from gateways on to a Graph Node, and manages the query payments via state channels with the gateway.
139
139
140
-
-**Indexer agent** - Facilitates the Indexers interactions on chain including registering on the network, managing subgraph deployments to its Graph Node/s, and managing allocations.
140
+
-**Indexer agent** - Facilitates the Indexers interactions onchain including registering on the network, managing subgraph deployments to its Graph Node/s, and managing allocations.
141
141
142
142
-**Prometheus metrics server** - The Graph Node and Indexer components log their metrics to the metrics server.
143
143
@@ -367,7 +367,7 @@ docker-compose up
367
367
368
368
To successfully participate in the network requires almost constant monitoring and interaction, so we've built a suite of Typescript applications for facilitating an Indexers network participation. There are three Indexer components:
369
369
370
-
-**Indexer agent** - The agent monitors the network and the Indexer's own infrastructure and manages which subgraph deployments are indexed and allocated towards on chain and how much is allocated towards each.
370
+
-**Indexer agent** - The agent monitors the network and the Indexer's own infrastructure and manages which subgraph deployments are indexed and allocated towards onchain and how much is allocated towards each.
371
371
372
372
-**Indexer service** - The only component that needs to be exposed externally, the service passes on subgraph queries to the graph node, manages state channels for query payments, shares important decision making information to clients like the gateways.
The indexer-cli provides an `actions` module for manually working with the action queue. It uses the **Graphql API** hosted by the indexer management server to interact with the actions queue.
619
619
620
-
The action execution worker will only grab items from the queue to execute if they have `ActionStatus = approved`. In the recommended path actions are added to the queue with ActionStatus = queued, so they must then be approved in order to be executed on-chain. The general flow will look like:
620
+
The action execution worker will only grab items from the queue to execute if they have `ActionStatus = approved`. In the recommended path actions are added to the queue with ActionStatus = queued, so they must then be approved in order to be executed onchain. The general flow will look like:
621
621
622
622
- Action added to the queue by the 3rd party optimizer tool or indexer-cli user
623
623
- Indexer can use the `indexer-cli` to view all queued actions
@@ -812,8 +812,8 @@ To set the delegation parameters using Graph Explorer interface, follow these st
812
812
813
813
After being created by an Indexer a healthy allocation goes through two states.
814
814
815
-
-**Active** - Once an allocation is created on-chain ([allocateFrom()](https://github.com/graphprotocol/contracts/blob/main/packages/contracts/contracts/staking/Staking.sol#L316)) it is considered **active**. A portion of the Indexer's own and/or delegated stake is allocated towards a subgraph deployment, which allows them to claim indexing rewards and serve queries for that subgraph deployment. The Indexer agent manages creating allocations based on the Indexer rules.
815
+
-**Active** - Once an allocation is created onchain ([allocateFrom()](https://github.com/graphprotocol/contracts/blob/main/packages/contracts/contracts/staking/Staking.sol#L316)) it is considered **active**. A portion of the Indexer's own and/or delegated stake is allocated towards a subgraph deployment, which allows them to claim indexing rewards and serve queries for that subgraph deployment. The Indexer agent manages creating allocations based on the Indexer rules.
816
816
817
817
-**Closed** - An Indexer is free to close an allocation once 1 epoch has passed ([closeAllocation()](https://github.com/graphprotocol/contracts/blob/main/packages/contracts/contracts/staking/Staking.sol#L335)) or their Indexer agent will automatically close the allocation after the **maxAllocationEpochs** (currently 28 days). When an allocation is closed with a valid proof of indexing (POI) their indexing rewards are distributed to the Indexer and its Delegators ([learn more](/network/indexing/#how-are-indexing-rewards-distributed)).
818
818
819
-
Indexers are recommended to utilize offchain syncing functionality to sync subgraph deployments to chainhead before creating the allocation on-chain. This feature is especially useful for subgraphs that may take longer than 28 epochs to sync or have some chances of failing undeterministically.
819
+
Indexers are recommended to utilize offchain syncing functionality to sync subgraph deployments to chainhead before creating the allocation onchain. This feature is especially useful for subgraphs that may take longer than 28 epochs to sync or have some chances of failing undeterministically.
Copy file name to clipboardExpand all lines: website/pages/en/subgraphs.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -55,7 +55,7 @@ Once defined, a subgraph can be [deployed to Subgraph Studio](/deploying/deployi
55
55
56
56
When you're happy with your subgraph, you can [publish it](/publishing/publishing-a-subgraph/) to The Graph Network.
57
57
58
-
- This is an on-chain action, which registers the subgraph and makes it discoverable by Indexers.
58
+
- This is an onchain action, which registers the subgraph and makes it discoverable by Indexers.
59
59
- Published subgraphs have a corresponding NFT, which defines the ownership of the subgraph. You can [transfer the subgraph's ownership](/managing/transfer-a-subgraph/) by sending the NFT.
60
60
- Published subgraphs have associated metadata, which provides other network participants with useful context and information.
Copy file name to clipboardExpand all lines: website/pages/en/tap.mdx
+1-1
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ Learn about The Graph’s new payment system, **Timeline Aggregation Protocol, T
9
9
[TAP](https://docs.rs/tap_core/latest/tap_core/index.html) is a drop-in replacement to the Scalar payment system currently in place. It provides the following key features:
10
10
11
11
- Efficiently handles micropayments.
12
-
- Adds a layer of consolidations to on-chain transactions and costs.
12
+
- Adds a layer of consolidations to onchain transactions and costs.
13
13
- Allows Indexers control of receipts and payments, guaranteeing payment for queries.
14
14
- It enables decentralized, trustless gateways and improves `indexer-service` performance for multiple senders.
0 commit comments