logAllThreads

Writes stack traces of all running threads to a JSON Lines file at a set interval for a set time, to help find performance problems. Runs in the background and returns right away.

logAllThreads(path [, interval] [, duration]) → returns void

This function requires Lucee 6.2.0.219 and up.  Not supported on Adobe ColdFusion, etc.

Argument Reference

path string
Required

The file to write to, ideally ending in .jsonl. The file is created or appended to.

interval numeric
Default: 0

The time between captures, in milliseconds.

duration numeric
Default: 10000

How long to capture for, in milliseconds.

Examples
Sample code invoking the logAllThreads function

Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.

Fork me on GitHub