> For the complete documentation index, see [llms.txt](https://cbdebugger.ortusbooks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cbdebugger.ortusbooks.com/collectors/objects-methods.md).

# Objects Methods

Profile any object method call

<figure><img src="https://639975657-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkinv4fgugMReTxKWlgH5%2Fuploads%2FowwvSauJBRjYWVsL7UYB%2FSCR-20230616-nidy.png?alt=media&amp;token=a23c02b7-9c84-4ac1-bfe8-6ebc12434c86" alt=""><figcaption><p>Object Profiling</p></figcaption></figure>

The ColdBox debugger allows you to profile the execution of **ANY** method in **ANY** CFC via our AOP pointcuts. All you need to do is add the `profile` annotation to a method or component declaration in your model/ORM objects. Once you do, the debugger will track the execution of those methods in the debug timers panel for you. First thing to do is make sure the setting is turned on:

```cfscript
requestTracker : {
	// Profile model objects annotated with the `profile` annotation
	profileObjects               : true,
	// If enabled, will trace the results of any methods that are being profiled
	traceObjectResults           : false,
}
```

The `traceObjectResults` if `true` will track the actual results of the method calls into your debugger timer panel. Careful, as we will serialize anything you send to us. Then add the `profile` annotation to any method or CFC.

```js
/**
 * Profile all methods in this component
 */
component profile{

}

// Add the profile to this method to track it
function saveAllObjects() profile{

}
```

Profiling objects is great because you can just annotate and forget. Nothing to turn off in production.  However, just note that doing AOP abstractions on more methods, the more slow downs you will experience, especially on transient objects.  We would recommend that you use it on specific methods only and be very wearisome of using the tracing of object results.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://cbdebugger.ortusbooks.com/collectors/objects-methods.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
