Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for defining a list of full node peers to connect to #17369

Merged

Conversation

felixbrucker
Copy link
Contributor

Purpose:

Allow the full node to connect to a list of full nodes configured via config.yaml and automatically reconnect should the connection be interrupted/disconnected.

Current Behavior:

Currently this is not supported, a workaround is to add peers manually via cli, but once not connected anymore they will not automatically reconnect.

New Behavior:

A list of full nodes can be configured via full_node_peers in the config.yaml, the same way other peers are already configured.

@felixbrucker felixbrucker requested a review from a team as a code owner January 20, 2024 08:30
@xearl4
Copy link
Contributor

xearl4 commented Jan 20, 2024

I am very much looking forward to this! We (spacefarmers.io) operate several meshes of full nodes to support pool needs. At the moment, we use a script to interconnect the nodes and keep them connected. I'll be happy to abandon that script :)

@emlowe emlowe added the Added Required label for PR that categorizes merge commit message as "Added" for changelog label Jan 23, 2024
@emlowe
Copy link
Contributor

emlowe commented Jan 23, 2024

Well, that seems simple enough.

@TheLastCicada
Copy link
Contributor

This will also be very useful if running a small private testnet where all peers are known. Can skip running an introducer potentially.

@Starttoaster Starttoaster merged commit 82f3b06 into Chia-Network:main Jan 23, 2024
259 of 260 checks passed
@felixbrucker felixbrucker deleted the add-full-node-peers-config-option branch January 23, 2024 18:18
@danieljperry
Copy link
Contributor

What is the expected syntax when adding a full node peer to the config? For example, something like this?

full_node_peers:
    host: 12.34.56.78
    port: 8444

@felixbrucker
Copy link
Contributor Author

felixbrucker commented Feb 9, 2024

Almost:

full_node_peers:
  - host: 12.34.56.78
    port: 8444

For multiple:

full_node_peers:
  - host: 12.34.56.78
    port: 8444
  - host: <another host>
    port: 8444

@danieljperry
Copy link
Contributor

I previously tried using a hyphen, but I didn't indent the port initially. Now I have it working. Thanks!

@LCG22
Copy link

LCG22 commented Mar 17, 2024

Does this wallet support these settings?

@felixbrucker
Copy link
Contributor Author

@LCG22 this PR only affects the full node service, not the wallet service

@LCG22
Copy link

LCG22 commented Mar 17, 2024

此 PR 仅影响全节点服务,不影响钱包服务

Can you let it support the wallet ?

@felixbrucker
Copy link
Contributor Author

As far as i know this is already possible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Added Required label for PR that categorizes merge commit message as "Added" for changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants