github.com/altipla-consulting/ravendb-go-client@v0.1.3/response_time_information.go (about) 1 package ravendb 2 3 import "time" 4 5 // ResponseTimeInformation describes timing information of server requests 6 type ResponseTimeInformation struct { 7 totalServerDuration time.Duration 8 totalClientDuration time.Duration 9 10 durationBreakdown []ResponseTimeItem 11 } 12 13 func (i *ResponseTimeInformation) computeServerTotal() { 14 var total time.Duration 15 for _, rti := range i.durationBreakdown { 16 total += rti.Duration 17 } 18 i.totalServerDuration = total 19 } 20 21 // ResponseTimeItem represents a duration for executing a given url 22 type ResponseTimeItem struct { 23 URL string 24 Duration time.Duration 25 }