-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add profiling compatibility include (#11190)
* feat: add profiling compatibility include * ref: reword compat * Update includes/profiling-mode-explanation.mdx Co-authored-by: vivianyentran <20403606+vivianyentran@users.noreply.github.com> --------- Co-authored-by: vivianyentran <20403606+vivianyentran@users.noreply.github.com>
- Loading branch information
Showing
1 changed file
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#### Continuous vs. Transaction-based Profiling | ||
|
||
Sentry's profiler offers two profiling modes: continuous (new) and transaction-based (old). | ||
In transaction-based profiling, the profiler integrates with the Sentry client to profile code executed during transaction start and stop calls. This approach has two main limitations: | ||
|
||
- Limited visibility into program runtime (only profiling instrumented code) | ||
- A maximum profile duration of 30 seconds (due to payload size constraints) | ||
|
||
These limitations make transaction-based profiling unsuitable for long-running tasks or profiling long-lived processes. | ||
Continuous profiling addresses these limitations by enabling profiling of long-running tasks. Since the profiler runs continuously and is not bound to the transaction model, it can provide visibility into non-instrumented code and surpass the 30-second profile duration limit. | ||
|
||
#### Impact on Product Experience | ||
|
||
We've worked to match the product experience between these two modes by inferring transaction events in continuous profiling mode. If you use both of our products, the experience remains largely the same. The main advantage of continuous profiling is the ability to escape the limitations of transaction-based profiling, and since profiles are no longer tied to transactions, it also means you can use profiling as a standalone product and are not forced to pay for transactions if you no longer wish to. | ||
|
||
#### Compatibility Between Modes in the SDK | ||
|
||
Continuous profiling mode is not compatible with transaction-based profiling, so you'll need to choose one or the other (you can switch between them at any time). To enable continuous profiling, ensure that the profiles sample rate and profiles sampler are not defined in the SDK. If they are defined, continuous profiling mode will be disabled. |