Skip to content

RUM-9908 Create view attributes update methods#2655

Merged
xgouchet merged 2 commits into
feature/v3from
xgouchet/RUM-9908/add_view_attributes_update_methods
May 23, 2025
Merged

RUM-9908 Create view attributes update methods#2655
xgouchet merged 2 commits into
feature/v3from
xgouchet/RUM-9908/add_view_attributes_update_methods

Conversation

@xgouchet

Copy link
Copy Markdown
Contributor

What does this PR do?

Add methods for customer to update the current View's attributes

@xgouchet
xgouchet requested review from a team as code owners May 16, 2025 08:09
@codecov-commenter

codecov-commenter commented May 16, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.85%. Comparing base (71b124b) to head (a4a2645).
⚠️ Report is 543 commits behind head on feature/v3.

Additional details and impacted files
@@              Coverage Diff               @@
##           feature/v3    #2655      +/-   ##
==============================================
+ Coverage       67.84%   67.85%   +0.01%     
==============================================
  Files             821      821              
  Lines           30555    30570      +15     
  Branches         5158     5160       +2     
==============================================
+ Hits            20729    20741      +12     
- Misses           8454     8472      +18     
+ Partials         1372     1357      -15     
Files with missing lines Coverage Δ
.../main/kotlin/com/datadog/android/rum/RumMonitor.kt 28.57% <ø> (ø)
...d/rum/internal/domain/scope/RumApplicationScope.kt 94.29% <ø> (+0.95%) ⬆️
...g/android/rum/internal/domain/scope/RumRawEvent.kt 100.00% <100.00%> (ø)
.../android/rum/internal/domain/scope/RumViewScope.kt 94.86% <100.00%> (+0.63%) ⬆️
.../android/rum/internal/monitor/DatadogRumMonitor.kt 85.49% <100.00%> (-0.13%) ⬇️

... and 29 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/align_attribute_propagation branch from fb654a1 to 872dfe4 Compare May 16, 2025 10:11
eventTime: Time,
writer: DataWriter<Any>
) {
attributes.putAll(GlobalRumMonitor.get(sdkCore).getAttributes())

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think this PR contains the changes from the other one ? I think you need a rebase here ?

@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/add_view_attributes_update_methods branch from a5dcf59 to ae7afba Compare May 19, 2025 09:06
@xgouchet
xgouchet requested a review from mariusc83 May 19, 2025 09:06
@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/add_view_attributes_update_methods branch from ae7afba to 18f2194 Compare May 19, 2025 09:22
ambushwork
ambushwork previously approved these changes May 19, 2025
@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/align_attribute_propagation branch 4 times, most recently from 370a88b to 11b287e Compare May 20, 2025 06:58
@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/add_view_attributes_update_methods branch from 18f2194 to 9ced598 Compare May 20, 2025 08:11
mariusc83
mariusc83 previously approved these changes May 20, 2025
Base automatically changed from xgouchet/RUM-9908/align_attribute_propagation to feature/v3 May 20, 2025 09:00
@xgouchet
xgouchet dismissed stale reviews from mariusc83 and ambushwork May 20, 2025 09:00

The base branch was changed.

@xgouchet
xgouchet requested review from ambushwork and mariusc83 May 20, 2025 09:00
fun clearAttributes()
fun stopSession()
fun addViewLoadingTime(Boolean)
fun addViewAttributes(Map<String, Any?>)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

question/ Any reason for not having an interface for single attributes?
Additionally, is it planned an interface to add multiple global attributes?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The RFC didn't mention adding a single attribute although it's feasible anyway with the current API.
I can create another PR which adds the option to add multiple global attributes 👍

@xgouchet
xgouchet requested a review from simaoseica-dd May 20, 2025 10:59
@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/add_view_attributes_update_methods branch from 9ced598 to db5fc6f Compare May 21, 2025 07:45
@xgouchet
xgouchet force-pushed the xgouchet/RUM-9908/add_view_attributes_update_methods branch from db5fc6f to a4a2645 Compare May 22, 2025 16:17
@xgouchet
xgouchet merged commit 2fe6c41 into feature/v3 May 23, 2025
@xgouchet
xgouchet deleted the xgouchet/RUM-9908/add_view_attributes_update_methods branch May 23, 2025 09:14
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.

5 participants