mirror of
https://github.com/tendermint/tendermint.git
synced 2026-06-03 12:56:22 +00:00
Add more comments about the hard-coded limits (#4100)
* crypto: expose MaxAunts for documentation purposes * types: update godoc for new maxes * docs: make hard-coded limits more explicit * wal: add todo to clarify max size * shorten lines in test
This commit is contained in:
@@ -434,6 +434,8 @@ All votes must have a valid signature from the corresponding validator.
|
||||
The sum total of the voting power of the validators that voted
|
||||
must be greater than 2/3 of the total voting power of the complete validator set.
|
||||
|
||||
The number of votes in a commit is limited to 10000 (see `types.MaxVotesCount`).
|
||||
|
||||
### Vote
|
||||
|
||||
A vote is a signed message broadcast in the consensus for a particular block at a particular height and round.
|
||||
|
||||
@@ -155,7 +155,9 @@ See details of SimpleProof, below.
|
||||
### MakeParts
|
||||
|
||||
Encode an object using Amino and slice it into parts.
|
||||
Tendermint uses a part size of 65536 bytes.
|
||||
Tendermint uses a part size of 65536 bytes, and allows a maximum of 1601 parts
|
||||
(see `types.MaxBlockPartsCount`). This corresponds to the hard-coded block size
|
||||
limit of 100MB.
|
||||
|
||||
```go
|
||||
func MakeParts(block Block) []Part
|
||||
@@ -288,7 +290,9 @@ func computeHashFromAunts(index, total int, leafHash []byte, innerHashes [][]byt
|
||||
}
|
||||
```
|
||||
|
||||
The number of aunts is limited to 100 (`maxAunts`) to protect the node against DOS attacks.
|
||||
The number of aunts is limited to 100 (`MaxAunts`) to protect the node against DOS attacks.
|
||||
This limits the tree size to 2^100 leaves, which should be sufficient for any
|
||||
conceivable purpose.
|
||||
|
||||
### IAVL+ Tree
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@ type State struct {
|
||||
}
|
||||
```
|
||||
|
||||
Note there is a hard-coded limit of 10000 validators. This is inherited from the
|
||||
limit on the number of votes in a commit.
|
||||
|
||||
### Result
|
||||
|
||||
```go
|
||||
|
||||
Reference in New Issue
Block a user