materialized view and a bit better ui
This commit is contained in:
1 parent
26b677154b
commit
49f9bb3458
30 files changed
+2184
-106
No files matched your search
@@ -360,7 +360,14 @@ func (c *Collector) HandleTraceByID(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
entries, err := c.SearchHistory(r.Context(), storage.SearchOptions{Query: traceID}, parseLimit(r, 1000))
|
||||
var entries []websocket.HistoryEntry
|
||||
var err error
|
||||
if c.traceQuerier != nil {
|
||||
// Indexed lookup, payloads trimmed to this trace's spans/logs.
|
||||
entries, err = c.traceQuerier.TraceEntries(r.Context(), traceID, parseLimit(r, 1000))
|
||||
} else {
|
||||
entries, err = c.SearchHistory(r.Context(), storage.SearchOptions{Query: traceID}, parseLimit(r, 1000))
|
||||
}
|
||||
if err != nil {
|
||||
log.Printf("failed to fetch trace %s: %v", traceID, err)
|
||||
http.Error(w, "failed to fetch trace", http.StatusInternalServerError)
|
||||
|
||||
Reference in new issue
Block a user