Skip to content

feat: add profiling as internal sub-API#8096

Draft
philprime wants to merge 5 commits into
philprime/internal-api/replayfrom
philprime/internal-api/profiling
Draft

feat: add profiling as internal sub-API#8096
philprime wants to merge 5 commits into
philprime/internal-api/replayfrom
philprime/internal-api/profiling

Conversation

@philprime

@philprime philprime commented Jun 16, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds SentryInternalProfilingApi as a sub-API on SentryInternalApi with start(for:), collect(between:and:for:), and discard(for:) methods
  • Delegates through PrivateSentrySDKOnly for profiling operations (start, collect, discard)
  • Includes ObjC wrapper (SentryObjCInternalProfilingApi) with SentryObjCId parameters
  • Platform-guarded: #if !(os(watchOS) || os(tvOS) || os(visionOS)) / SENTRY_OBJC_PROFILING_SUPPORTED

#skip-changelog

@github-actions

github-actions Bot commented Jun 16, 2026

Copy link
Copy Markdown
Contributor
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 1bda1e6

@philprime philprime self-assigned this Jun 17, 2026
Add Swift unit, Swift integration, ObjC integration, and ObjC unit
tests for SentryInternalProfilingApi. Ports profiling tests from
PrivateSentrySDKOnlyTests and adds coverage for the new structured
API surface (SentrySDK.internal.profiling / SentryObjCSDK.internal.profiling).

Fix existing unit test: profiler can start without SDK (uses kernel
APIs directly), so start returns non-zero even before SDK init.

ObjC collect tests have a known issue with unrecognized selector
for collectBetween:and:for: that needs investigation.
@philprime philprime added the ready-to-merge Use this label to trigger all PR workflows label Jun 18, 2026
@sentry

sentry Bot commented Jun 18, 2026

Copy link
Copy Markdown

📲 Install Builds

iOS

🔗 App Name App ID Version Configuration
SDK-Size io.sentry.sample.SDK-Size 9.17.1 (1) Release

⚙️ sentry-cocoa Build Distribution Settings

@github-actions

Copy link
Copy Markdown
Contributor

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1222.90 ms 1258.43 ms 35.53 ms
Size 24.14 KiB 1.19 MiB 1.17 MiB

Baseline results on branch: philprime/internal-api/replay

Startup times

Revision Plain With Sentry Diff
f03e36c 1218.98 ms 1251.95 ms 32.97 ms

App size

Revision Plain With Sentry Diff
f03e36c 24.14 KiB 1.19 MiB 1.17 MiB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Use this label to trigger all PR workflows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant