Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var HttpTimeout = 5 * time.Second
View Source
var ParallelPosters = 5
Functions ¶
This section is empty.
Types ¶
type EventDetailsError ¶ added in v0.3.0
type EventDetailsError struct {
Error string `json:"error"`
}
eventDetailsError is for the EventDetails in the case of a query or retrieval failure
type EventDetailsIndexer ¶ added in v0.4.3
type EventDetailsSuccess ¶ added in v0.3.0
type EventDetailsSuccess struct { ReceivedSize uint64 `json:"receivedSize"` ReceivedCids uint64 `json:"receivedCids"` Duration uint64 `json:"durationMs"` }
eventDetailsSuccess is for the EventDetails in the case of a retrieval success
type EventRecorder ¶
type EventRecorder struct {
// contains filtered or unexported fields
}
EventRecorder receives events from the retrieval manager and posts event data to a given endpoint as POSTs with JSON bodies
func NewEventRecorder ¶
func NewEventRecorder(ctx context.Context, cfg EventRecorderConfig) *EventRecorder
NewEventRecorder creates a new event recorder with the ID of this instance and the URL to POST to
func (*EventRecorder) RecordEvent ¶ added in v0.3.0
func (er *EventRecorder) RecordEvent(event types.RetrievalEvent)
type EventRecorderConfig ¶ added in v0.4.3
type MultiEventReport ¶ added in v0.3.0
type MultiEventReport struct {
Events []eventReport `json:"events"`
}
Directories ¶
Path | Synopsis |
---|---|
A simple HTTP server that receives EventRecorder events and writes them, as line-delimited JSON to an output file.
|
A simple HTTP server that receives EventRecorder events and writes them, as line-delimited JSON to an output file. |
Click to show internal directories.
Click to hide internal directories.