Skip to content

Commit

Permalink
Adds next steps of installing a node (#547)
Browse files Browse the repository at this point in the history
* Adds next steps of installing a node

* Minor improvements?

* Update maximise apy content

* Update RPC section

* Updates to Operators rewards

* Update of descriptions

* Review improvements

* Node Operator Improvements

* Minor clarification

---------

Co-authored-by: seandotau <[email protected]>
Co-authored-by: James Bayly <[email protected]>
  • Loading branch information
3 people authored Aug 4, 2024
1 parent 0a38ba6 commit 52195ed
Show file tree
Hide file tree
Showing 9 changed files with 185 additions and 13 deletions.
1 change: 1 addition & 0 deletions docs/.vuepress/sidebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -661,6 +661,7 @@ export const getSidebar = (locale: string) =>
},
`${locale}/subquery_network/node_operators/stake.md`,
`${locale}/subquery_network/node_operators/plans.md`,
`${locale}/subquery_network/node_operators/maximise-apy.md`,
],
},
{
Expand Down
12 changes: 11 additions & 1 deletion docs/subquery_network/community.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SubQuery Network Community

The key focus of the [SubQuery Foundation](./foundation.md) and community is to ensure that there is enough support that anyone, from an expert blockchain team to a new hobbyist developer, can build their own Project. Together we can pave the way to a more decentralised future!
The key focus of the [SubQuery Foundation](./governance/foundation.md) and community is to ensure that there is enough support that anyone, from an expert blockchain team to a new hobbyist developer, can build their own Project. Together we can pave the way to a more decentralised future!

## Developer Guild

Expand All @@ -18,6 +18,16 @@ Discord is our main community for talking about SubQuery and learning more. You

When the conversation is deeper and requires more thought, we move the conversation to [our Forum](https://forum.subquery.network/). Here you will find longer topics, a history of all announcements to Network, and deeper conversation about the direction of the network. Feel free to join and start posting at [forum.subquery.network](https://forum.subquery.network/)!

### Join the Node Operator community

If you're a Node Operator on the Network, we strongly suggest that you keep up with the latest news, announcements, and tips by joining the following Discord channels:

- `#network-announcements`
- `#network-general`
- `#network-services-release`
- `#network-indexer-announcements`
- `#network-indexer-general`

## Contributing to Codebases

SubQuery is open source and open to the community, if you want to contribute (e.g. add a feature, fix a bug, suggest an improvement, or even just fix a typo in our documentation), please review our [contributing guide](../miscellaneous/contributing.md).
Expand Down
10 changes: 8 additions & 2 deletions docs/subquery_network/delegators/rewards.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,15 @@ If a Node Operator wishes to increase the Node Operator Commission Rate that the

![Token economic flow](/assets/img/network/token_economy.png)

## How to select what Node Operators to delegate to
## How to select what Node Operators to delegate to?

You need to assess a few things when deciding on what Node Operator to choose.
You might assess a few things when deciding on what Node Operator to choose. For instance you might consider:

- Having SSL enabled
- Having an ENS domain (aka social credibility is enabled)
- Having a frequent Era Reward Collection period
- Being active in the Discord community
- Having a lower NOCR (a lower Node Operator Commission Rate means more rewards will be shared amongst Delegators)

Node Operators set a Node Operator’s Commission Rate (NOCR) which is the percentage Node Operators earn. Therefore, a lower NOCR will be more attractive for Delegators as a larger percentage of rewards is shared between Delegators.

Expand Down
10 changes: 5 additions & 5 deletions docs/subquery_network/introduction/reward-distribution.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,19 @@ There is a reward pool for each deployments Node Operator runs where the adjustm

![Reward Pools](/assets/img/network/reward_pools.png)

## Network Inflation Rewards
## Stake Rewards

Some projects in our network are considered “Public Good” projects, for example; network dictionaries and the various SubQuery projects that the [official Network app](https://app.subquery.network) runs on. In these cases, we need to ensure Node Operators will run and host them, but generally there will be no single customer that will take the lead in financing these requests

Additionally, for Node Operators, running projects incurs significant costs. Without clear demand, Node Operators might not want to risk the time and resources to setup a new project.

The solution to this comes from network inflation as a reward source for Indexer rewards, in addition to rewards for productive work. We allow Consumers to use [Boosting](../consumers/boosting.md) to direct Network Inflation Rewards, which distributed to Node Operators proportionally based on the total boosted SQT on their projects.
The solution to this comes from network inflation as a reward source for Stake Rewards, in addition to rewards for productive work. We allow Consumers to use [Boosting](../consumers/boosting.md) to direct Stake Rewards, which distributed to Node Operators proportionally based on the total boosted SQT on their projects.

In order to receive network inflation rewards, Node Operators must be running a project that has a non-zero amount of consumer boosting, and be online/available to the public with a sync progress of 100%. Node Operators will not receive all of the network inflation rewards, some rewards are distributed to the Consumers that boosted the project, as described in [Consumer Boosting](../consumers/boosting.md#how-are-boosters-rewarded).
In order to receive Stake Rewards, Node Operators must be running a project that has a non-zero amount of consumer boosting, and be online/available to the public with a sync progress of 100%. Node Operators will not receive all of the Stake Rewards, some rewards are distributed to the Consumers that boosted the project, as described in [Consumer Boosting](../consumers/boosting.md#how-are-boosters-rewarded).

Network inflation rewards are allocated to all project types supported by the SubQuery Network, e.g data indexing projects and RPC endpoints. The split of network inflation rewards between the Consumer that boosted the project, and the Node Operator may vary by project type.
Stake Rewards are allocated to all project types supported by the SubQuery Network, e.g data indexing projects and RPC endpoints. The split of network inflation rewards between the Consumer that boosted the project, and the Node Operator may vary by project type.

The current inflation rate on the SubQuery Network can be found on our [network parameters page](../parameters.md). The majority of network inflation acts as network inflation rewards, while the remainder is allocated to the SubQuery Treasury to fund various programmes.
The current inflation rate on the SubQuery Network can be found on our [network parameters page](../parameters.md). The majority of network inflation acts as Stake Rewards, while the remainder is allocated to the SubQuery Treasury to fund various programmes.

## Cobb-Douglas Production Function

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ You have successfully started Indexing. Next we need to get our project online o

For a brand new project, the project status will be `Offline`.

Once the project has started indexing, you can Go Online so that the Network knows that you are running the project. When the indexing progress reaches the minimum required block height the network can now start to distribute requests to the Node Operator's project deployment.
Once the project has finished indexing, you should mark it as `online` so that the Network knows that you are running the project. The network will then start to distribute requests to the Node Operator's project deployment.

Select the `Go Online` button and send a transaction.

Expand Down
145 changes: 145 additions & 0 deletions docs/subquery_network/node_operators/maximise-apy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
# Maximising Your APY

After you have joined the SubQuery Network, completed indexing of your first project, and announced ready to the network, you might have questions on how to maximise your APY and attract as much delegation as possible.

### Join the Node Operator community

If you're a Node Operator on the Network, we strongly suggest that you keep up with the latest news, announcements, and tips by joining our Discord. Read more about the [Node Operator community here](../community.md#join-the-node-operator-community).

## Quick Checks

- We strongly recommend that you enable [Auto Reduce Over Allocation](./stake.md#automatically-reduce-over-allocation) to prevent being over allocated.
- Ensure you have at least one flex plan enabled for each project deployment so we can send requests to you from our gateway.
- Ensure projects are able to fetch metadata from deployment’s Query Service. An error will appear in the status column if there is an issue.
- Ensure that you are online. `GET:{your_indexer_service_url}/healthy` should return a 200 with something like

```json
{
"autoReduceAllocation": true,
"controller": "",
"coordinatorVersion": "v2.2.3",
"indexer": "",
"os": "Debian GNU/Linux 10 4-CPU",
"proxyVersion": "v2.4.2",
"uptime": 8066
}
```

## Weekly Tasks

You may have already setup a Grafana dashboard to monitor metrics from your `indexer-coordinator` and `indexer-proxy` services, but there are important notifications and settings you should monitor in the [Network App](https://app.subquery.network/).

We strongly suggest that you log in at the start of each new Era (as close as possible to the start - set a calendar reminder), to resolve any warnings or notifications, as well complete the following key tasks.

### Weekly tasks - Claim rewards

If you don't frequently claim your rewards (e.g. once a week), Delegators can see this and may decide against delegating to support you. Make sure you claim your rewards frequently (e.g. once a week), and ideally as soon as they become available after the end of the past Era.

If you are running v2.2.1 or later, rewards are collected automatically. This will result in an Era Reward Collection status of “Frequent” on the [All Node Operators](https://app.subquery.network/indexer/all-indexers) dashboard meaning that your Delegators can also receive their rewards. Be sure though that enough ETH balance is in your Controller Account for automatic collection.

### Weekly tasks - Check for new project versions

Project creators might deploy new versions of their project codebases each time. We strongly suggest following their release notes and updating your project to match the recommended versions. In some cases you wont need to reindex, just update the project version.

Since [Project Boost affects the amount of Stake rewards distributed](../introduction/reward-distribution.md#stake-rewards) for running a project, you may want to consider what project deployment version has the highest boost to maximise your Stake rewards.

### Weekly tasks - Update SQT allocation

- Avoid having tokens allocated to outdated deployment versions. An “Outdated Allocation Projects” pop up will appear if this occurs. This means that you should adjust your allocation to the latest version (and update to the new version).
- Avoid having “Unallocated Stake”. To maximise rewards, ensure all tokens are allocated. An “Unallocated Stake” pop up will appear if this occurs.

### Weekly tasks - Check Project health
- Ensure your project is online. Appending “/healthy” to the end of your http URL should return:
```
{
"autoReduceAllocation": true,
"controller": "",
"coordinatorVersion": "v2.2.3",
"indexer": "",
"os": "Debian GNU/Linux 10 4-CPU",
"proxyVersion": "v2.4.2",
"uptime": 8066
}
```
- Ensure you have at least one flexplan enabled for each project.
- Ensure projects are able to fetch metadata from deployment’s Query Service. An error will appear in the status column if there is an issue.

## Selecting what projects to run.

As a node operator, two types of endpoints (or nodes) can be run: SubQuery Indexers endpoints or RPC endpoints. See [here](https://app.subquery.network/explorer/home) for a complete list.

- Indexer endpoints typically receive a higher portion of their rewards via stake rewards which is relatively stable era-to-era.
- RPC endpoints typically receive more query rewards which can produce a higher overall APY but with more volatility as query demand changes.

These endpoints then index various projects. Project rewards come from a combination of its Stake Rewards and Query Rewards. They are generated by each project based on the amount of boost allocated to a project and then shared proportionally between the number of operators (for that project).

- Stake rewards are measured in stake APY, the Annual Percentage Yield you can expect from allocating SQT to a project. It is a function of the boost applied to a project, which sets the size of its total stake reward pool, divided by the stake allocated to the project.
- Query Rewards are generated when people pay for queries against a project.

To maximise rewards:
- look for projects which have high boost, but low allocated stake. (for stake rewards)
- look for projects that have high average query rewards per Node Operator (for query rewards)
- low competition (in general)
- low project complexity (in general)

Also, project database size is a good indicator of cost

## Node Operator Rewards FAQs

### How can I attract more indexing & RPC requests?

The public gateway will allocate requests based on your:
- Reliability: Improve your uptime to increase queries.
- Block height: Keep your nodes fully synced to receive queries.
- Latency: Reduce latency by keeping your Node CPU usage healthy with good network connection.
- Price: Lower pricing can receive more requests.

### Should I run all projects or focus on a select few

For indexer projects, use the stake APY and the cost of running the project to determine the viability of running a project.

For RPC projects, if you are already running RPC nodes for other networks and have capacity to serve more requests, it may be beneficial to add SubQuery as an extra source of requests to maximise your return from the node with very little added cost.

### Do I need to allocate stake to earn query rewards?

No. Your query rewards are only slightly impacted by your total stake, but are not impacted by which project you allocate the stake to, unlike indexer projects. For example, you can allocate 1 SQT to an RPC project and still receive query rewards.

### So when would I allocate stake to my RPC projects?

RPC Projects do also earn stake APY. You should allocate stake if it makes competitive stake APY compared to your other projects.

### Can you add support for the other RPCs I run?

We are planning to expand our RPC projects. [Letting us know](https://subquery.network/contact) which other nodes you run can help us to onboard new networks faster.

### Why did I get 0 query rewards last era?

Projects may receive 0 or low query rewards if:
- Your project is not competitive at price v performance (see [How can I attract more RPC requests?](#how-can-i-attract-more-rpc-requests))
- Your project was offline
- Your project was unhealthy
- Your project is not fully synced
- You did not have Flex Plan pricing enabled
- Your indexer version does not automatically claim query rewards (must be v2.2.1 or later)
- Your indexer controller account does not have balance to claim query rewards


### How can I attract more Delegators

Understand [what Delegators are looking](./rewards.md#how-to-select-what-node-operators-to-delegate-to) for in Node Operators

### My delegation increased. Is it more profitable to add more projects, or to increase stake in my existing projects?

If your current projects continue to earn competitive stake APY after adding additional stake, you may just continue to serve a smaller number of projects.

However, if you don't increase your APY after allocating new delegation to an existing project, you may want to consider expanding operations with the new Delegation and adding other new projects that are returning higher stake APY and rebalancing your stake.

### Why do some Node Operators have >100% APY

Node Operator APY compares their total returns to the amount they have personally staked (self stake)

Node Operators can achieve high Node Operator APY when:
- They have large delegation relative to their own self stake, meaning they earn extra rewards in commission off somebody else's delegation.
- They prioritise projects with high query rewards so are less dependent on the size of their stake.

High node operator APY does not necessarily mean that they make more overall rewards or profit.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ An RPC Provider is a SubQuery network participant who is responsible for serving

RPC Providers play a very important role within the SubQuery network, they act as the main interface between dApps, indexers, and other consumers to the underlying data on the blockchain, and are also responsible for submitting transactions.

Running RPCs is also very easy if you are already familiar with them or already running one. You can quickly connect an existing RPC endpoint to the SubQuery Network if you are already running an RPC for another usecase (the RPC node does not need to be dedicated to the SubQuery Network).

## Requirements to be an RPC Provider

To become an RPC Provider on the SubQuery Network, the RPC Provider must possess the necessary hardware, run the required SubQuery services, have a publicly accessible network via a static IP or a domain name, and register as an RPC Provider.
Expand Down
4 changes: 4 additions & 0 deletions docs/subquery_network/node_operators/setup/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ If the indexing node is unhealthy, first visit the service log to determine if a

The other option is to restart the service and/or servers involved.

## When should I mark my new project as Online?

You should mark your project as online when they are fully synced.

## Can the same Node Operator run 2 services on different platforms?

The same Node Operator can index 2 **different** projects on 2 **different** hosting providers.
Expand Down
Loading

0 comments on commit 52195ed

Please sign in to comment.