Save bootstrap trace events in a circular buffer (#16823)

This commit is contained in:
Krishnan Parthasarathi
2023-03-17 16:01:03 -07:00
committed by GitHub
parent 280442e533
commit 31fba6f434
5 changed files with 189 additions and 0 deletions

View File

@@ -1526,6 +1526,11 @@ func (a adminAPIHandlers) TraceHandler(w http.ResponseWriter, r *http.Request) {
return
}
// Publish bootstrap events that have already occurred before client could subscribe.
if traceOpts.TraceTypes().Contains(madmin.TraceBootstrap) {
go globalBootstrapTracer.Publish(ctx, globalTrace)
}
for _, peer := range peers {
if peer == nil {
continue