docs: fix typos
Alejandro Criado-Pérez committed
Sep 22, 2023 at 13:08 UTC
cc3c224c6278c4c62b8d732fefc54cf7246308d2
6 files changed
+11
-11
core/commands/block.go
+1
-1
@@ -169,7 +169,7 @@ only for backward compatibility when a legacy CIDv0 is required (--format=v0).
169
cidCodec, _ := req.Options[blockCidCodecOptionName].(string)
170
format, _ := req.Options[blockFormatOptionName].(string) // deprecated
171
172
- // use of legacy 'format' needs to supress 'cid-codec'
172
+ // use of legacy 'format' needs to suppress 'cid-codec'
173
if format != "" {
174
if cidCodec != "" && cidCodec != "raw" {
175
return fmt.Errorf("unable to use %q (deprecated) and a custom %q at the same time", blockFormatOptionName, blockCidCodecOptionName)
core/node/libp2p/rcmgr.go
+1
-1
@@ -181,7 +181,7 @@ func LimitConfig(cfg config.SwarmConfig, userResourceOverrides rcmgr.PartialLimi
181
182
// This effectively overrides the computed default LimitConfig with any non-"useDefault" values from the userResourceOverrides file.
183
// Because of how how Build works, any rcmgr.Default value in userResourceOverrides
184
- // will be overriden with a computed default value.
184
+ // will be overridden with a computed default value.
185
limitConfig = userResourceOverrides.Build(limitConfig)
186
187
return limitConfig, msg, nil
core/node/libp2p/rcmgr_defaults.go
+3
-3
@@ -32,7 +32,7 @@ func createDefaultLimitConfig(cfg config.SwarmConfig) (limitConfig rcmgr.Concret
32
// At least as of 2023-01-25, it's possible to open a connection that
33
// doesn't ask for any memory usage with the libp2p Resource Manager/Accountant
34
// (see https://github.com/libp2p/go-libp2p/issues/2010#issuecomment-1404280736).
35
- // As a result, we can't curretly rely on Memory limits to full protect us.
35
+ // As a result, we can't currently rely on Memory limits to full protect us.
36
// Until https://github.com/libp2p/go-libp2p/issues/2010 is addressed,
37
// we take a proxy now of restricting to 1 inbound connection per MB.
38
// Note: this is more generous than go-libp2p's default autoscaled limits which do
@@ -114,7 +114,7 @@ func createDefaultLimitConfig(cfg config.SwarmConfig) (limitConfig rcmgr.Concret
114
// Anything in scalingLimitConfig that wasn't defined in partialLimits above will be added (e.g., libp2p's default service limits).
115
partialLimits = partialLimits.Build(scalingLimitConfig.Scale(int64(maxMemory), maxFD)).ToPartialLimitConfig()
116
117
- // Simple checks to overide autoscaling ensuring limits make sense versus the connmgr values.
117
+ // Simple checks to override autoscaling ensuring limits make sense versus the connmgr values.
118
// There are ways to break this, but this should catch most problems already.
119
// We might improve this in the future.
120
// See: https://github.com/ipfs/kubo/issues/9545
@@ -140,7 +140,7 @@ Computed default go-libp2p Resource Manager limits based on:
140
- 'Swarm.ResourceMgr.MaxMemory': %q
141
- 'Swarm.ResourceMgr.MaxFileDescriptors': %d
142
143
-Theses can be inspected with 'ipfs swarm resources'.
143
+These can be inspected with 'ipfs swarm resources'.
144
145
`, maxMemoryString, maxFD)
146
docs/config.md
+2
-2
@@ -1450,7 +1450,7 @@ However the latency of individual read/write operations should be ~10x faster
1450
and the provide throughput up to 6 million times faster on larger datasets!
1451
1452
This is not compatible with `Routing.Type` `custom`. If you are using composable routers
1453
-you can configure this individualy on each router.
1453
+you can configure this individually on each router.
1454
1455
When it is enabled:
1456
- Client DHT operations (reads and writes) should complete much faster
@@ -2146,7 +2146,7 @@ Type: `priority`
2146
Mplex is deprecated, this is because it is unreliable and
2147
randomly drop streams when sending data *too fast*.
2148
2149
-New pieces of code rely on backpressure, that means the stream will dynamicaly
2149
+New pieces of code rely on backpressure, that means the stream will dynamically
2150
slow down the sending rate if data is getting backed up.
2151
Backpressure is provided by **Yamux** and **QUIC**.
2152
docs/libp2p-resource-management.md
+3
-3
@@ -83,7 +83,7 @@ since we assume libp2p knows best here.
83
Source: [core/node/libp2p/rcmgr_defaults.go](https://github.com/ipfs/kubo/blob/master/core/node/libp2p/rcmgr_defaults.go)
84
85
### User Supplied Override Limits
86
-A user who wants fine control over the limits used by the go-libp2p resoure manager can specify overrides to the [computed default limits](#computed-default-limits).
86
+A user who wants fine control over the limits used by the go-libp2p resource manager can specify overrides to the [computed default limits](#computed-default-limits).
87
This is done by defining limits in ``$IPFS_PATH/libp2p-resource-limit-overrides.json``.
88
These values trump anything else and are parsed directly by go-libp2p.
89
(See the [go-libp2p Resource Manager README](https://github.com/libp2p/go-libp2p/blob/master/p2p/host/resource-manager/README.md) for formatting.)
@@ -98,7 +98,7 @@ As an example:
98
> Protected from exceeding resource limits 2 times: "system: cannot reserve inbound connection: resource limit exceeded"
99
100
This means that there were 2 recent occurrences where the libp2p resource manager prevented an inbound connection at the "system" [scope](https://github.com/libp2p/go-libp2p/tree/master/p2p/host/resource-manager#resource-scopes).
101
-Specificaly the ``System.ConnsInbound`` limit was hit.
101
+Specifically the ``System.ConnsInbound`` limit was hit.
102
103
This can be analyzed by viewing the limit and current usage with `ipfs swarm resources`.
104
`System.ConnsInbound` is likely close or at the limit value.
@@ -136,7 +136,7 @@ If `Swarm.ConnMgr.HighWater` is greater than resource manager's `System.ConnsInb
136
existing low priority idle connections can prevent new high priority connections from being established.
137
The ResourceMgr doesn't know that the new connection is high priority and simply blocks it because of the limit its enforcing.
138
139
-To ensure the ConnMgr and ResourceMgr are congruent, the ResourceMgr [computed default limts](#computed-default-limits) are adjusted such that:
139
+To ensure the ConnMgr and ResourceMgr are congruent, the ResourceMgr [computed default limits](#computed-default-limits) are adjusted such that:
140
1. `System.ConnsInbound` >= `max(Swarm.ConnMgr.HighWater * 2, DefaultResourceMgrMinInboundConns)` AND
141
2. `System.StreamsInbound` is greater than any new/adjusted `Swarm.ResourceMgr.Limits.System.ConnsInbound` value so that there's enough streams per connection.
142
peering/peering.go
+1
-1
@@ -44,7 +44,7 @@ func (s State) String() string {
44
case StateStopped:
45
return "stopped"
46
default:
47
- return "unkown peering state: " + strconv.FormatUint(uint64(s), 10)
47
+ return "unknown peering state: " + strconv.FormatUint(uint64(s), 10)
48
}
49
}
50