Skip to content

Commit

Permalink
start creating proposal as soon as signer session is initialized (#6317)
Browse files Browse the repository at this point in the history
## Motivation

Speed up creating and publishing a proposal in 1:N setups.
  • Loading branch information
poszu committed Sep 6, 2024
1 parent bec09a9 commit 5d5a8b7
Show file tree
Hide file tree
Showing 4 changed files with 372 additions and 112 deletions.
12 changes: 7 additions & 5 deletions miner/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ type latencyTracker struct {
start time.Time
end time.Time

data time.Duration
tortoise time.Duration
hash time.Duration
txs time.Duration
publish time.Duration
data time.Duration
tortoise time.Duration
hash time.Duration
activeSet time.Duration
txs time.Duration
publish time.Duration
}

func (lt *latencyTracker) total() time.Duration {
Expand All @@ -34,6 +35,7 @@ func (lt *latencyTracker) total() time.Duration {

func (lt *latencyTracker) MarshalLogObject(encoder zapcore.ObjectEncoder) error {
encoder.AddDuration("data", lt.data)
encoder.AddDuration("active set", lt.activeSet)
encoder.AddDuration("tortoise", lt.tortoise)
encoder.AddDuration("hash", lt.hash)
encoder.AddDuration("txs", lt.txs)
Expand Down
62 changes: 62 additions & 0 deletions miner/mocks/mocks.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 5d5a8b7

Please sign in to comment.