Debugging
Functions
- CallStackDump()
Dump the context (stacktrace) of the current position.
- CallStackGet()
Returns the context (stacktrace) of the current position.
- ComponentCacheList()
list elements in the component path cache
- DebugAdd()
Adding data to debug output.
- Dump()
Outputs the elements, variables and values of most kinds of CFML objects. Useful for debugging. You can display the contents of simple and complex variables, objects, components, user-defined functions, and other elements.
- Echo()
Writes the given string to the main response buffer regardless of conditions established by the cfsetting tag. see also function writeOutput.
- GetComponentMetaData()
Gets metadata (such as the functions and implemented interfaces of a component) for a CFC or Interface.
- GetComponentStaticScope()
returns the static scope of a specific component, of course access rules apply.
- GetContextInfo()
Returns information about the current context.
- GetContextRoot()
Returns path to the J2EE server context root for the current request.
- GetCPUUsage()
returns the CPU usage for a defined time range (default: 1000ms).
- GetMetadata()
Returns back meta information depending on the object passed in
- GetPageContext()
Gets the current PageContext object that provides access to page attributes and configuration, request and response objects.
- GetTickCount()
Returns the elapsed time from a specific reference point, based on the specified
unit
. The default unit, "milli," represents milliseconds since midnight, January 1, 1970 UTC, and aligns with conventional system time. The "nano" and "micro" units offer high-resolution timing based on the Java Virtual Machine's internal clock, ideal for measuring elapsed time rather than absolute wall-clock time - IsDebugMode()
Determines whether debugging output is enabled.
- LogAllThreads()
Creates detailed thread stack trace logs in JSONL format for performance analysis and debugging. This function captures stack traces from all running threads at specified intervals for a given duration. It executes asynchronously, returning immediately after starting the logging process, making it ideal for analyzing specific code segments by initiating logging just before the target code execution
- SizeOf()
this function is experimental, do not use in a production environment. this function returns the size in bytes of a given object.
- SystemOutput()
writes the given string to the output stream.
- Trace()
Displays and logs debugging data about the state of an application at the time this function executes.
- WriteDump()
Outputs the elements, variables and values of most kinds of CFML objects. Useful for debugging. You can display the contents of simple and complex variables, objects, components, user-defined functions, and other elements.
- WriteLog()
Writes a message to a log file.
Tags
- <cfdump>
Outputs the elements, variables and values of most kinds of CFML objects. Useful for debugging. You can display the contents of simple and complex variables, objects, components, user-defined functions, and other elements.
- <cflog>
Writes a message to a log file.
- <cfprocessingdirective>
Sets compiler directives that affect the entire template. Unlike most CFML tags, cfprocessingdirective is processed at compile time and must be placed at the root level of your template.
- <cfsetting>
Controls various aspects of page processing, such as the output of HTML code in pages. One benefit of this option is managing whitespace that can occur in output pages served by CFML.
- <cfthrow>
The cfthrow tag raises a developer-specified exception
- <cftimer>
Displays execution time for a specified section of CFML code.
- <cftrace>
Displays and logs debugging data about the state of an application at the time the cftrace tag executes.
Guides
- Exception - Cause
Lucee 6.1 improves its support for exception causes, providing better debugging and error handling capabilities.
- Exception Output
How to catch and display exceptions.
- ExecutionLog
Log details about code execution at the statement level
- Lucee Step Debugger Installation Guide
How to set up the step debugger "luceedebug" for enhanced CFML Debugging in Visual Studio Code and Lucee
- Monitoring - Enable for your session
Shows you a way to enable Monitoring for your session
- Monitoring/Debugging
Learn about the changes in Lucee 6.1 regarding Monitoring and Debugging. Understand the old and new behavior, and how to configure the settings in Lucee Admin and Application.cfc.
- SystemOutput, writing to the console
This document explains the systemoutput function with some simple examples.
- Thread Dump During Startup
How to capture thread positions during Lucee startup for debugging and performance analysis
- Troubleshooting Lucee Server problems
A guide to diagnosing problems with Lucee