Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PLAT-31288] Split out ending a span and closing/sending for processing #361

Merged
merged 1 commit into from
Dec 12, 2024

Conversation

kstenerud
Copy link
Contributor

Goal

The RN library needs to be able to set the end time multiple times, so we need to split out:

  • ending a span (marking the end time)
  • closing the span and sending for processing (at which time it becomes immutable)

Design

BugsnagPerformanceSpan now has two new internal APIs:

  • - (void)markEndTime:(NSDate *)endTime to set the end time of the span (can be called multiple times)
  • - (void)sendForProcessing to send for processing (idempotent, only performs operation once)

Testing

Existing tests are sufficient since the public end functions now call these functions.

Copy link

BugsnagPerformance.framework binary size increased by 720 bytes from 524,168 to 524,888

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  [ = ]       0 +13e3% +15.3Ki    [__LINKEDIT]
  +0.4%    +384  +0.4%    +384    Symbol Table
  +0.3%    +328  +0.3%    +328    String Table
  +0.2%    +204  +0.2%    +204    __TEXT,__text
  +0.8%    +144  +0.8%    +144    __DATA,__objc_const
  +0.7%    +115  +0.7%    +115    __TEXT,__objc_methname
  +0.8%     +96  +0.8%     +96    __TEXT,__objc_stubs
  +0.7%     +24  +0.7%     +24    __DATA,__objc_selrefs
  +0.1%     +12  +0.1%     +12    __TEXT,__gcc_except_tab
  +0.7%      +8  +0.7%      +8    Function Start Addresses
  +0.2%      +8  +0.2%      +8    __TEXT,__unwind_info
  +0.9%      +4  +0.9%      +4    __DATA,__objc_ivar
  -2.8%    -172  -2.9%    -172    [__DATA]
  -1.0%    -435  -1.0%    -435    [__TEXT]
  +0.1%    +720  +3.1% +16.0Ki    TOTAL

Generated by 🚫 Danger

@kstenerud kstenerud merged commit 3b097a7 into next Dec 12, 2024
25 checks passed
@kstenerud kstenerud deleted the PLAT-13288-split-span-end-and-process branch December 12, 2024 15:19
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.

3 participants