Take a fast thing and make it faster.
In this Christmas special, Nick and Herman chat about the new built-in profiling support for cf-agent in the upcoming release.
The upcoming 3.27 LTS release introduces a first-class profiling capability directly into cf-agent. Unlike previous solutions (like cf-profile or the Perl-based profiler) which often required real-time analysis or significant logging overhead, this new approach decouples collection from analysis.
To profile a run, you simply add the --profile option, redirect the output to a file for later analysis.
cf-agent --no-lock --profile > callstack.jsonThis generates a JSON file containing the call stack and timing information for every promise evaluation.
Nick demonstrated a new, un-released tool, cfengine-cli, to digest this JSON data.
You can see which bundles, promises, or functions are consuming the most time:
cfengine profile --top 15 --bundles --promises --functions ./callstack.jsonVideo
The video recording is available on YouTube: https://youtu.be/q6hrwto91JE
At the end of every webinar, we stop the recording for a nice and relaxed, off-the-record chat with attendees. Join the next webinar to not miss this discussion.
Links
- Connect w/ Cody, Craig, Herman, or Nick
- All Episodes