JamesRay
d0bb1ab2b0
Filter out empty addresses in persistent_peers/seeds lists ( #2323 )
Fixes #2320
6 years ago
Anton Kaliaev
166fd82b70
max-bytes PR follow-up ( #2318 )
* ReapMaxTxs: return all txs if max is negative
this mirrors ReapMaxBytes behavior
See https://github.com/tendermint/tendermint/pull/2184#discussion_r214439950
* increase MaxAminoOverheadForBlock
tested with:
```
func TestMaxAminoOverheadForBlock(t *testing.T) {
maxChainID := ""
for i := 0; i < MaxChainIDLen; i++ {
maxChainID += "𠜎"
}
h := Header{
ChainID: maxChainID,
Height: 10,
Time: time.Now().UTC(),
NumTxs: 100,
TotalTxs: 200,
LastBlockID: makeBlockID(make([]byte, 20), 300, make([]byte, 20)),
LastCommitHash: tmhash.Sum([]byte("last_commit_hash")),
DataHash: tmhash.Sum([]byte("data_hash")),
ValidatorsHash: tmhash.Sum([]byte("validators_hash")),
NextValidatorsHash: tmhash.Sum([]byte("next_validators_hash")),
ConsensusHash: tmhash.Sum([]byte("consensus_hash")),
AppHash: tmhash.Sum([]byte("app_hash")),
LastResultsHash: tmhash.Sum([]byte("last_results_hash")),
EvidenceHash: tmhash.Sum([]byte("evidence_hash")),
ProposerAddress: tmhash.Sum([]byte("proposer_address")),
}
b := Block{
Header: h,
Data: Data{Txs: makeTxs(10000, 100)},
Evidence: EvidenceData{},
LastCommit: &Commit{},
}
bz, err := cdc.MarshalBinary(b)
require.NoError(t, err)
assert.Equal(t, MaxHeaderBytes+MaxAminoOverheadForBlock-2, len(bz)-1000000-20000-1)
}
```
* fix MaxYYY constants calculation
by using math.MaxInt64
See https://github.com/tendermint/tendermint/pull/2184#discussion_r214444244
* pass mempool filter as an option
See https://github.com/tendermint/tendermint/pull/2184#discussion_r214445869
* fixes after Dev's comments
6 years ago
Anton Kaliaev
d73c5cbdb1
reap max bytes from the mempool & check transaction size
See ADR 020: Limiting txs size inside a block docs/architecture/adr-020-block-size.md
Refs #2035
6 years ago
bradyjoestar
5446452b01
pass in NodeKey to NewNode ( #2212 )
Fixes #1544
6 years ago
Dev Ojha
2756be5a59
libs: Remove usage of custom Fmt, in favor of fmt.Sprintf ( #2199 )
* libs: Remove usage of custom Fmt, in favor of fmt.Sprintf
Closes #2193
* Fix bug that was masked by custom Fmt!
6 years ago
ValarDragon
f903947ff3
crypto: Remove interface from crypto.Signature
Signatures are now []byte, which saves on the number of bytes after
amino encoding
(squash this) address Ismail's comment
6 years ago
Anton Kaliaev
75a26ebd6d
do not overwrite metrics provider in node#NewNode
also, make running Prometheus server optional.
Closes #2019
6 years ago
ValarDragon
c798702764
crypto: Remove Ed25519 and Secp256k1 suffix on GenPrivKey
6 years ago
ValarDragon
99e582d79a
crypto: Refactor to move files out of the top level directory
Currently the top level directory contains basically all of the code
for the crypto package. This PR moves the crypto code into submodules
in a similar manner to what `golang/x/crypto` does. This improves code
organization.
Ref discussion: https://github.com/tendermint/tendermint/pull/1966
Closes #1956
6 years ago
Jeremiah Andrews
6c4ca140ed
Add private peer ID tracking to AddrBook ( #1989 )
* Add private peer ID tracking to AddrBook
* Remove private peer tracking/blocking from pex
* debug level msg when we fail to add private address
6 years ago
Ethan Buchman
d903057011
fix stopping pubsub
6 years ago
Anton Kaliaev
3ffda994c2
Revert "rename privval#GetAddress and GetPubKey to Address and PubKey"
This reverts commit 58d0c8de89
.
6 years ago
Anton Kaliaev
ff8ddee708
rename privval#GetAddress and GetPubKey to Address and PubKey
6 years ago
Zach Ramsay
44dad6d70b
Revert "detele everything"
This reverts commit d02c5d1e30
.
6 years ago
Zach Ramsay
d02c5d1e30
detele everything
6 years ago
Anton Kaliaev
4de9d42e4c
limit the number of requests in flights for Prometheus server ( #1927 )
* limit the number of requests in flights for Prometheus server
Closes #1804
Default to 1 because usually there's just one collector.
* config: Up default for prom connections
6 years ago
Ethan Buchman
737c5c065d
fixes from review
6 years ago
Ethan Buchman
1c018d3fd2
p2p: external address
* new config option for external address to advertise
* if blank, defaults to best guess from listener
* if laddr ip address is also blank, default to IPv4
6 years ago
Ethan Buchman
d55243f0e6
fix import paths
6 years ago
Anton Kaliaev
ada5ef0669
[p2p] add godoc comments to Listener ( #1828 )
* update changelog
* document p2p/listener
* do not expose underlying net.Listener
* add a TODO
* replace todo with a comment
6 years ago
kph7
e556e3336e
Adding IPv6 support to peering ( #1818 )
6 years ago
Dev Ojha
b1d6deaf0b
config: rename skip_upnp to upnp ( #1827 )
* config: rename skip_upnp to upnp
Change default option to enable upnp.
Closes #1806
* doc updates
- fix comment and set UPNP to false in TestP2PConfig
- add UPNP to config template
- update changelog
6 years ago
Anton Kaliaev
936a655990
limit number of open connections
Refs #1740
also, expose limit option for number concurrent streams for gRPC
(unlimited by default)
6 years ago
Alexander Simmerl
a605b66c5a
Move abci imports
6 years ago
Liamsi
d2c05bc5b9
Revert "delete everything" (includes everything non-go-crypto)
This reverts commit 96a3502
6 years ago
Liamsi
96a3502126
delete everything
6 years ago
Anton Kaliaev
205d8b8062
fixes after @xla review
- move prometheus metrics into internal packages
- *Option structs
- misc. format changes
7 years ago
Anton Kaliaev
e4bb3566a0
move metrics constructors to a separate package
7 years ago
Anton Kaliaev
829342a82d
make StartPrometheusServer func private
we don't really need to export it
7 years ago
Anton Kaliaev
84812145cb
friendly apis for constructors
7 years ago
Anton Kaliaev
d8fea3ec9d
separate http server for metrics
7 years ago
Anton Kaliaev
e90cb4f5fa
add docs
7 years ago
Anton Kaliaev
1bdff076ad
add config option
7 years ago
Anton Kaliaev
7efb73aa18
mempool size metric
7 years ago
Anton Kaliaev
19699d644f
p2p metric, make height and totalTxs gauges
7 years ago
Anton Kaliaev
0cb50c05fc
add rounds metric
7 years ago
Anton Kaliaev
e58d674f4c
add validators power gauges
7 years ago
Anton Kaliaev
fad76e103b
extract metrics to provider, remove height label
7 years ago
Anton Kaliaev
489d9b9184
more metrics
7 years ago
Anton Kaliaev
3cdf3b670d
serve metrics under /metrics
7 years ago
Anton Kaliaev
5c869b5888
validator metrics
7 years ago
Anton Kaliaev
5c7093cc9f
go-kit metrics plus prometheus: one metric
7 years ago
Ethan Buchman
89925501f3
p2p/filter/pubkey -> p2p/filter/id
7 years ago
Ethan Buchman
7606b7595f
compiles
7 years ago
Alexander Simmerl
bf370d36c2
Extract priv_validator into first class package
This is a maintenance change to move the private validator package out
of the types and to a top-level location. There is no good reason to
keep it under the types and it will more clearly coommunicate where
additions related to the privval belong. It leaves the interface and the
mock in types for now as it would introduce circular dependency between
privval and types, this should be resolved eventually.
* mv priv_validator to privval pkg
* use consistent `privval` as import
Follow-up to #1255
7 years ago
Alexander Simmerl
3255c076e5
Remove auth_enc config option
As we didn't hear any voices requesting this feature, we removed the
option to disable it and always have peer connection auth encrypted.
closes #1518
follow-up #1325
7 years ago
Ethan Buchman
ee4eb59355
update comments
7 years ago
Anton Kaliaev
5e3a23df6d
simplify indexer service main loop
7 years ago
Ethan Buchman
cae31157b1
fix lint
7 years ago
Ethan Buchman
f395b82f73
node: remove commented out trustMetric
7 years ago