Skip to content

feat(profiling): add pause and resume functions for manual profiling - #2310

Open
Litarnus wants to merge 2 commits into
continuous-profiling-baseline-00from
manual-pause-resume
Open

Litarnus wants to merge 2 commits into
continuous-profiling-baseline-00from
manual-pause-resume

Conversation

@Litarnus

@Litarnus Litarnus commented Nov 3, 2026

Copy link
Copy Markdown
Collaborator

Introduces pausing and resuming a manual profiling session. For long living runtimes such as FrankenPHP or Swoole, there might be a time where the runtime simply waits for a next request to handle. By design, the process doesn't terminate which means that Excimer is still running and producing samples. This will then look like the last call took a very long time.

By calling pause and resume at request boundaries, we are able to inject idle samples which will signal a stop to the previous sampled call. Internally it's solved through a request reference counting, so even if the runtimes is async, it will only pause if no other request is currently in-flight.

@Litarnus
Litarnus added this pull request to stack #2311 November 3, 2026 14:51
@Litarnus
Litarnus force-pushed the manual-pause-resume branch from 2f481fc to ed98285 Compare November 3, 2026 16:51

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit ed98285. Configure here.

Comment thread src/Profiling/ContinuousProfiler.php Resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant