swarm/storage: improve instrumentation

swarm/storage/localstore: fix broken metric (#1373)

p2p/protocols: count different messages (#1374)

cmd/swarm: disable snapshot create test due to constant flakes (#1376)

swarm/network: remove redundant goroutine (#1377)
This commit is contained in:
Anton Evangelatov
2019-05-07 13:46:26 +02:00
parent 7f753461ca
commit 3e9ba57669
6 changed files with 30 additions and 40 deletions

View File

@@ -73,7 +73,7 @@ type DB struct {
pullTriggers map[uint8][]chan struct{}
pullTriggersMu sync.RWMutex
// binIDs stores the latest chunk serial ID for very
// binIDs stores the latest chunk serial ID for every
// proximity order bin
binIDs shed.Uint64Vector

View File

@@ -47,7 +47,7 @@ func (db *DB) Get(ctx context.Context, mode chunk.ModeGet, addr chunk.Address) (
defer func() {
if err != nil {
metrics.GetOrRegisterCounter(fmt.Sprintf(metricName+".error", mode), nil).Inc(1)
metrics.GetOrRegisterCounter(metricName+".error", nil).Inc(1)
}
}()

View File

@@ -36,7 +36,7 @@ import (
// Pull syncing index can be only subscribed to a particular proximity order bin. If since
// is not 0, the iteration will start from the first item stored after that id. If until is not 0,
// only chunks stored up to this id will be sent to the channel, and the returned channel will be
// closed. The since-until interval is closed on the both sides [since,until]. Returned stop
// closed. The since-until interval is open on since side, and closed on until side: (since,until] <=> [since+1,until]. Returned stop
// function will terminate current and further iterations without errors, and also close the returned channel.
// Make sure that you check the second returned parameter from the channel to stop iteration when its value
// is false.