> For the complete documentation index, see [llms.txt](https://docs.ostara.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ostara.dev/features/instance-features/jvm/thread-profiling.md).

# Thread Profiling

### Overview

Thread Profiling allows you to to profile the threads within your application for a set amount of time, after which you will be able to explore the results of the profiling.

### Usage

To initiate a new profiling, click the **Request Thread Profiling** at the top right

<figure><img src="https://141808391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQIUN58YadwFHHtojkuQ5%2Fuploads%2FH5Ri2iY5Y0SnFMlY6YZa%2F2023-04-03%2013.16.35.gif?alt=media&amp;token=16b3d89a-1195-452b-a4f6-cb81648b35ca" alt=""><figcaption></figcaption></figure>

Upon completion, click the **View Details** action to reveal the profiling window

The profiler runs for 60 seconds and gathers all thread dumps form this time, grouping the data by thread and thread state over time.&#x20;

&#x20;     \- Represents threads in a `RUNNING` state

&#x20;     \- Represents threads in a `WAITING` state

&#x20;     \- Represents threads in a `TIMED_WAITING` state

<figure><img src="https://141808391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQIUN58YadwFHHtojkuQ5%2Fuploads%2FhGzxwkHC8alvPi1SPJN2%2Fimage.png?alt=media&amp;token=8a220984-9ffa-4d94-bbaa-8606c081d544" alt=""><figcaption></figcaption></figure>

Each grouped block is expandable and will show the thread's details, as well as the stack trace. Multiple blocks can be expanded at a time.

<figure><img src="https://141808391-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQIUN58YadwFHHtojkuQ5%2Fuploads%2F9YRGaxNdZkiBRfmLsAiS%2F2023-04-03%2013.27.29.gif?alt=media&amp;token=39857588-c5cb-4422-974d-358169c8030e" alt=""><figcaption></figcaption></figure>

### Required Abilities

* [Thread Dump](/features/abilities.md)


---

# 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://docs.ostara.dev/features/instance-features/jvm/thread-profiling.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.
