Skip to content

Commit

Permalink
[Core] Exclude js or map assets from event loop utilisation log (elas…
Browse files Browse the repository at this point in the history
…tic#203155)

## Summary

Exclude `js` and `.js.map` assets from the logger.
  • Loading branch information
dej611 authored Dec 18, 2024
1 parent d5af2e0 commit 38aa404
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,11 @@ function startEluMeasurement<T>(
if (
eluMonitorOptions.logging.enabled &&
active >= eluMonitorOptions.logging.threshold.ela &&
utilization >= eluMonitorOptions.logging.threshold.elu
utilization >= eluMonitorOptions.logging.threshold.elu &&
// static js and js.map assets are generating lots of noise for this
// event loop check, hiding endpoint slowness which are higher priority
// remove this check once endpoints slowness is addressed
!['js', 'js.map'].some((ext) => path.endsWith(ext))
) {
log.warn(
`Event loop utilization for ${path} exceeded threshold of ${elaThreshold}ms (${Math.round(
Expand Down

0 comments on commit 38aa404

Please sign in to comment.