Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RequestData ¶
type RequestData struct { UUID string Version string LicenseType string Internal string RawReportBody string diagnosticspb.DiagnosticReport }
RequestData stores the data provided by a diagnostics request.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is a http server that implements a diagnostics endpoint. Its URL can be used as the updates or reporting URL (see diagonsticspb.TestingKnobs).
func NewServer ¶
func NewServer() *Server
NewServer creates and starts a new server. The server must be closed.
func (*Server) Close ¶
func (s *Server) Close()
Close shuts down the server and blocks until all outstanding requests on this server have completed.
func (*Server) LastRequestData ¶
func (s *Server) LastRequestData() *RequestData
LastRequestData returns the data from last request received by the server. Returns nil if there were no requests.
func (*Server) NumRequests ¶
NumRequests returns the total number of requests received by this server.
Click to show internal directories.
Click to hide internal directories.