diff options
| author | Will Hawkins <[email protected]> | 2022-06-04 05:49:07 -0400 |
|---|---|---|
| committer | Will Hawkins <[email protected]> | 2022-06-04 05:49:07 -0400 |
| commit | de7a7bf994a020049eca89098aab9d13ff81f361 (patch) | |
| tree | 25137addcf1ee9cc0c68c05d33481bcd050046ac /lgc/lgc.go | |
| parent | d38bea818a90a0ca2bfc17e96c00b9896e2c61ca (diff) | |
[Feature] Access TCP_INFO about underlying TCP connections
This will only work on *nix systems. Code that displays information
in this PR is only exemplary -- I am sure that there are better
places in the code to display it!
Diffstat (limited to 'lgc/lgc.go')
| -rw-r--r-- | lgc/lgc.go | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -38,6 +38,7 @@ type LoadGeneratingConnection interface { Client() *http.Client IsValid() bool ClientId() uint64 + Stats() *stats.TraceStats } // TODO: All 64-bit fields that are accessed atomically must @@ -284,6 +285,10 @@ func (lbd *LoadGeneratingConnectionDownload) IsValid() bool { return lbd.valid } +func (lbd *LoadGeneratingConnectionDownload) Stats() *stats.TraceStats { + return &lbd.stats +} + func (lbd *LoadGeneratingConnectionDownload) doDownload(ctx context.Context) { var request *http.Request = nil var get *http.Response = nil @@ -420,3 +425,7 @@ func (lgu *LoadGeneratingConnectionUpload) Start( go lgu.doUpload(ctx) return true } + +func (lbd *LoadGeneratingConnectionUpload) Stats() *stats.TraceStats { + return nil +} |
