Skip to content

Commit

Permalink
refactor: AutoRelay → RelayClient
Browse files Browse the repository at this point in the history
  • Loading branch information
lidel committed Nov 15, 2021
1 parent 51834c3 commit 2d64785
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions config/swarm.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ type SwarmConfig struct {
// `Swarm.AutoRelay.Enabled` if specified.
EnableAutoRelay bool `json:",omitempty"`

// AutoRelay controls the "auto relay service" feature.
// RelayClient controls the client side of "auto relay" feature.
// When enabled, the node will use relays if it is not publicly reachable.
AutoRelay AutoRelay
RelayClient RelayClient

// RelayService.* controls the "relay service".
// When enabled, node will provide a limited relay service to other peers.
Expand All @@ -42,8 +42,8 @@ type SwarmConfig struct {
ConnMgr ConnMgr
}

type AutoRelay struct {
// Enables the AutoRelay.
type RelayClient struct {
// Enables the auto relay feature: will use relays if it is not publicly reachable.
Enabled Flag `json:",omitempty"`

// StaticRelays configures static relays to use when this node is not
Expand All @@ -55,7 +55,7 @@ type AutoRelay struct {
// RelayService configures the resources of the circuit v2 relay.
// For every field a reasonable default will be defined in go-ipfs.
type RelayService struct {
// Enables the limited relay (circuit v2 relay).
// Enables the limited relay service for other peers (circuit v2 relay).
Enabled Flag `json:",omitempty"`

// ConnectionDurationLimit is the time limit before resetting a relayed connection.
Expand Down

0 comments on commit 2d64785

Please sign in to comment.