Skip to content

Add event loop timing histogram data. - #9114

Merged
SolidWallOfCode merged 1 commit into
apache:masterfrom
SolidWallOfCode:histogram
Nov 13, 2022
Merged

Add event loop timing histogram data.#9114
SolidWallOfCode merged 1 commit into
apache:masterfrom
SolidWallOfCode:histogram

Conversation

@SolidWallOfCode

@SolidWallOfCode SolidWallOfCode commented Sep 29, 2022

Copy link
Copy Markdown
Member

This is based on a problem I had at LinkedIn involving latency in requests. The event loop data looked as if the event loops were very long (billions of nanoseconds in some cases) but it wasn't possible to tell if this was the exception or the rule (i.e. is there a plugin that now and then blocks on an ET_NET thread, or are the plugins in general slowing things up?). This adds histogram data for event loop timing so it's possible to see

  1. How relatively common long loops are.
  2. Whether there a variety of timings for long loops, instead of tracking only the very longest.
  3. Whether there are clusters at certain timings.

This should be backwards compatible with 9.x.

As part of this work, the Histogram class is added. It is designed to log samples performantly and provides a decay mechanism to keep the data relevant. These call all be adjusted by tweaking various compile time constants.

Comment thread proxy/http/HttpSM.cc Outdated
Comment thread iocore/eventsystem/UnixEThread.cc Outdated
@SolidWallOfCode

Copy link
Copy Markdown
Member Author

I cleaned up the internal access quite a bit, as @cmcfarlen requested, and fixed a build error (I hope).

@SolidWallOfCode
SolidWallOfCode force-pushed the histogram branch 2 times, most recently from 0ecb400 to e442875 Compare September 30, 2022 23:25
Comment thread include/tscpp/util/Histogram.h Outdated
@SolidWallOfCode
SolidWallOfCode merged commit 2188253 into apache:master Nov 13, 2022
SolidWallOfCode added a commit to SolidWallOfCode/trafficserver that referenced this pull request Nov 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants