| 36 | } |
| 37 | |
| 38 | type memBuffer struct { |
| 39 | next []byte |
| 40 | pending chan qentry |
| 41 | |
| 42 | dropMu syncs.Mutex |
| 43 | dropCount int |
| 44 | |
| 45 | // Metrics (see [memBuffer.ExpVar] for details). |
| 46 | writeCalls expvar.Int |
| 47 | readCalls expvar.Int |
| 48 | writeBytes expvar.Int |
| 49 | readBytes expvar.Int |
| 50 | droppedBytes expvar.Int |
| 51 | storedBytes expvar.Int |
| 52 | } |
| 53 | |
| 54 | // ExpVar returns a [metrics.Set] with metrics about the buffer. |
| 55 | // |
nothing calls this directly
no outgoing calls
no test coverage detected