feat(backend): added missing sessionID to log in start request + batch info
This commit is contained in:
parent
e5929e9818
commit
75ccacf576
1 changed files with 6 additions and 0 deletions
|
|
@ -254,6 +254,8 @@ func (e *Router) startSessionHandlerWeb(w http.ResponseWriter, r *http.Request)
|
|||
e.log.Error(r.Context(), "can't send sessionStart to queue: %s", err)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
r = r.WithContext(context.WithValue(r.Context(), "sessionID", fmt.Sprintf("%d", tokenData.ID)))
|
||||
}
|
||||
|
||||
// Save information about session beacon size
|
||||
|
|
@ -284,6 +286,10 @@ func (e *Router) pushMessagesHandlerWeb(w http.ResponseWriter, r *http.Request)
|
|||
startTime := time.Now()
|
||||
bodySize := 0
|
||||
|
||||
// Get debug header with batch info
|
||||
batch := r.Header.Get("X-Openreplay-Batch")
|
||||
r = r.WithContext(context.WithValue(r.Context(), "batch", batch))
|
||||
|
||||
// Check authorization
|
||||
sessionData, err := e.services.Tokenizer.ParseFromHTTPRequest(r)
|
||||
if sessionData != nil {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue