diff options
| author | Will Hawkins <[email protected]> | 2022-05-11 14:35:26 -0400 |
|---|---|---|
| committer | Will Hawkins <[email protected]> | 2022-05-11 14:37:55 -0400 |
| commit | 49301ae7f6ef1c479fe3b23cba29d74a815d15ee (patch) | |
| tree | c9a2b6aa4b2abfde3b41c0ba9d5057c922fd4208 /stats/stats.go | |
| parent | e184c0808b980e81ee87791264a7fa030f52e962 (diff) | |
[Bugfix] Support reused connections in calculating RPM
There was an error in prior versions when calculating the RPM in the
presence of reused connections because invalid time values were being
compared. This patch fixes that error.
Diffstat (limited to 'stats/stats.go')
| -rw-r--r-- | stats/stats.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/stats/stats.go b/stats/stats.go index a636326..f5ae4cb 100644 --- a/stats/stats.go +++ b/stats/stats.go @@ -22,6 +22,7 @@ type TraceStats struct { TLSDoneTime utilities.Optional[time.Time] ConnectStartTime time.Time ConnectDoneTime time.Time + ConnectionReused bool GetConnectionStartTime time.Time GetConnectionDoneTime time.Time HttpWroteRequestTime time.Time @@ -44,6 +45,7 @@ func (s *TraceStats) String() string { fmt.Sprintf("TLSDoneTime: %v\n", s.TLSDoneTime) + fmt.Sprintf("ConnectStartTime: %v\n", s.ConnectStartTime) + fmt.Sprintf("ConnectDoneTime: %v\n", s.ConnectDoneTime) + + fmt.Sprintf("ConnectionReused: %v\n", s.ConnectionReused) + fmt.Sprintf("GetConnectionStartTime: %v\n", s.GetConnectionStartTime) + fmt.Sprintf("GetConnectionDoneTime: %v\n", s.GetConnectionDoneTime) + fmt.Sprintf("HttpResponseReadyTime: %v\n", s.HttpResponseReadyTime) |
