Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
457 commits
Select commit Hold shift + click to select a range
cb78569
Expose sdk iOS config option `trackMemoryWarnings`
cdn34dd Nov 5, 2025
3984bcc
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
6a42fca
Add `userId` and `accountId`to baggage headers
cdn34dd Nov 7, 2025
85ebed2
Cache `userId` and `accountId` when first set
cdn34dd Nov 13, 2025
c04b071
Integrate Feature Operations into `core` SDK
cdn34dd Nov 21, 2025
ee2972a
Remove defaultPrivacyLevel from Session Replay
sbarrio Nov 18, 2025
a7067ae
Bump Native SDKs to 3.3.0
sbarrio Nov 28, 2025
ef5f4a1
Solve merge issues and fix failing native tests
sbarrio Nov 28, 2025
bf864c4
Remove type interdependencies between modules
sbarrio Sep 5, 2025
ce64712
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
1158e31
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
c3e310f
Remove setUser
sbarrio Sep 12, 2025
01dd817
Bump Native SDKs to 3.1.0
sbarrio Sep 19, 2025
1a7f360
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
bd90e99
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
d5b4325
Expose clearUserInfo API
sbarrio Sep 19, 2025
283888b
Update attribute API
sbarrio Sep 29, 2025
4a176b2
JS refresh rate normalization
sbarrio Oct 16, 2025
bc103f2
Expose view Attributes API
sbarrio Oct 10, 2025
22c7422
Bump Android Native SDK to 3.2.0 and regenerate app podfiles
sbarrio Oct 27, 2025
e4a2828
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
421455e
Remove setUser
sbarrio Sep 12, 2025
67b3193
Bump Native SDKs to 3.1.0
sbarrio Sep 19, 2025
c27cc8b
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
09e2679
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
869d159
Expose clearUserInfo API
sbarrio Sep 19, 2025
f68acc3
Update attribute API
sbarrio Sep 29, 2025
64ae74c
JS refresh rate normalization
sbarrio Oct 16, 2025
fa0a304
Expose view Attributes API
sbarrio Oct 10, 2025
2126d4e
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
30623d7
Adapt internal testing tools package to changes done for v3
sbarrio Dec 3, 2025
46f65b0
Fixed ProxiedCore implementation
sbarrio Dec 4, 2025
fc53cc6
Remove unnecessary isInitialized check on DdLogsImplementation
sbarrio Dec 4, 2025
afb2c81
Fix iOS tests
sbarrio Dec 4, 2025
8065371
Attributes Safe Encoding
marco-saia-datadog Oct 10, 2025
73f2d9e
Fixed existing tests
marco-saia-datadog Oct 10, 2025
e88bc66
Minor warning fixes in tests
marco-saia-datadog Oct 10, 2025
611ac95
Changed .tsx to .ts + removed left-over comment
marco-saia-datadog Oct 13, 2025
5d564fb
Limit encoded attributes to 128
marco-saia-datadog Oct 21, 2025
2a7a47b
Add tests to ensure attributes are encoded by copy
marco-saia-datadog Oct 21, 2025
53ee54e
Missing attributes on FileBasedConfiguration and linting
sbarrio Nov 28, 2025
ae07a87
Add NavigationTrackingOptions to React Navigation tracking
sbarrio Nov 28, 2025
2c7683c
Add NavigationTrackingOptions to React Native Navigation tracking
sbarrio Nov 28, 2025
8c47a07
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
44940e6
Codepush adaptation
sbarrio Nov 25, 2025
c778e41
Fix iOS tests
sbarrio Nov 26, 2025
06cd0cc
Fix Android tests
sbarrio Nov 27, 2025
8ebf50e
Fix Typescript tests
sbarrio Nov 27, 2025
6bf3698
Edited schema configutarion description
sbarrio Dec 9, 2025
e7b0063
Rename CoreConfiguration and RumConfiguration
sbarrio Dec 9, 2025
d27d674
Fix import of DdSdkNativeCOnfiguration type for DdSdkInternal
sbarrio Dec 10, 2025
e89583b
Correct Baggage Header Handling
marco-saia-datadog Dec 10, 2025
630a2dd
Refactored baggage header parsing for readability
marco-saia-datadog Dec 15, 2025
f0b8ce8
Fix Typescript tests
sbarrio Nov 27, 2025
2f34bd4
Rename CoreConfiguration and RumConfiguration
sbarrio Dec 9, 2025
4138aae
feat: Support trace sampling based on RUM Session ID
marco-saia-datadog Dec 9, 2025
737ea1a
Bumped Datadog iOS SDK to v3.4.0
marco-saia-datadog Dec 15, 2025
2b9b839
Bump Datadog Android SDK to v3.4.0
sbarrio Dec 15, 2025
a94c962
Fix internal testing tools core wrapping to work with v3
sbarrio Dec 15, 2025
93c24bb
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
b366a1b
Fix Typescript tests
sbarrio Nov 27, 2025
48b0318
Use global instance for DatadogProvider state
marco-saia-datadog Dec 9, 2025
b9a80b2
Use global instance for GlobalState
marco-saia-datadog Dec 9, 2025
e99aa9b
Use global instance for DdBabelInteractionTracking
marco-saia-datadog Dec 9, 2025
290d018
Use global instance for DdRumReactNavigationTracking
marco-saia-datadog Dec 9, 2025
acd0808
Restore exception for androidx.performance import on RN<0.76
sbarrio Dec 15, 2025
f4dba4b
Solve merge conflicts
sbarrio Dec 17, 2025
c1f5700
Merge with feature/v3
sbarrio Dec 17, 2025
2c0ba0f
Fix merge errors
sbarrio Dec 17, 2025
231f76f
Prevent encoding of internal SDK attributes
cdn34dd Jan 5, 2026
7ee4c51
Merge pull request #1091 from DataDog/carlosnogueira/RUM-13565/incorr…
cdn34dd Jan 5, 2026
5743f21
Merge pull request #1084 from DataDog/sbarrio/chore/update-v3-with-la…
sbarrio Jan 8, 2026
36fac4c
Deprecate interaction tracking in core sdk package
cdn34dd Dec 19, 2025
7c6991b
Merge pull request #1088 from DataDog/carlosnogueira/RUM-12776/deprec…
cdn34dd Jan 8, 2026
4e8f39e
Change react-navigation view's key format so url_path_group is calcul…
cdn34dd Jan 12, 2026
84230b6
Merge pull request #1103 from DataDog/carlosnogueira/RUM-13689/update…
cdn34dd Jan 14, 2026
1e5c4a0
RUM-9023 use session id to sample network traces
xgouchet Apr 7, 2025
6db0536
RUM-7747 update default tracing sampling rate
xgouchet Apr 28, 2025
7f0a9e4
Remove fatal errors from logs
sbarrio Sep 2, 2025
356c1d6
Improve module wrapper singleton creation
sbarrio Sep 2, 2025
01004f2
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
74b0dcf
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
1759eb7
Remove type interdependencies between modules
sbarrio Sep 5, 2025
3a687f5
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
7a79687
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
5aa0b4d
Remove setUser
sbarrio Sep 12, 2025
9d130e5
Update Tracer imports for Android to remove opentracing dependencies
sbarrio Sep 12, 2025
c83598a
Fix android tests
sbarrio Sep 18, 2025
dee0ebc
Fix iOS tests
sbarrio Sep 18, 2025
f0b3c5e
Bump Native SDKs to 3.1.0
sbarrio Sep 19, 2025
efd38c7
Fix internaltTestingTools tests
sbarrio Sep 19, 2025
d40ec79
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
d4f93e1
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
4d2b1ee
Expose clearUserInfo API
sbarrio Sep 19, 2025
55ef82b
Update attribute API
sbarrio Sep 29, 2025
2fdddf9
JS refresh rate normalization
sbarrio Oct 16, 2025
88baa66
Expose view Attributes API
sbarrio Oct 10, 2025
d6bae19
Fix FileBasedConfiguration related issues
sbarrio Aug 22, 2025
2783e9b
Bump Android Native SDK to 3.2.0 and regenerate app podfiles
sbarrio Oct 27, 2025
bbe8ca0
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
bc52612
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
ca6819c
Remove setUser
sbarrio Sep 12, 2025
a426033
Bump Native SDKs to 3.1.0
sbarrio Sep 19, 2025
513895f
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
9102f8e
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
c37a1ec
Expose clearUserInfo API
sbarrio Sep 19, 2025
d481aab
Update attribute API
sbarrio Sep 29, 2025
a255d9c
JS refresh rate normalization
sbarrio Oct 16, 2025
510e57e
Expose view Attributes API
sbarrio Oct 10, 2025
e7a4270
Handle optional String on removeAttributes
sbarrio Oct 27, 2025
0199cf3
Bump minSdkVersion to 23
sbarrio Oct 27, 2025
ff36b07
Expose sdk iOS config option `trackMemoryWarnings`
cdn34dd Nov 5, 2025
6b4e913
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
fc6230c
Add `userId` and `accountId`to baggage headers
cdn34dd Nov 7, 2025
b4bff4f
Cache `userId` and `accountId` when first set
cdn34dd Nov 13, 2025
2051667
Integrate Feature Operations into `core` SDK
cdn34dd Nov 21, 2025
815e146
Remove defaultPrivacyLevel from Session Replay
sbarrio Nov 18, 2025
981f719
Bump Native SDKs to 3.3.0
sbarrio Nov 28, 2025
48690c3
Solve merge issues and fix failing native tests
sbarrio Nov 28, 2025
bf55f23
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
50dfd73
Remove setUser
sbarrio Sep 12, 2025
b134e53
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
78ed895
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
9bc7d64
Expose clearUserInfo API
sbarrio Sep 19, 2025
a4d0217
Update attribute API
sbarrio Sep 29, 2025
53324db
JS refresh rate normalization
sbarrio Oct 16, 2025
1e3bc3d
Expose view Attributes API
sbarrio Oct 10, 2025
40d6932
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
32e38e1
Remove setUser
sbarrio Sep 12, 2025
4373160
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
1703b33
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
ff07572
Expose clearUserInfo API
sbarrio Sep 19, 2025
9e0d7e9
Update attribute API
sbarrio Sep 29, 2025
4167d1d
JS refresh rate normalization
sbarrio Oct 16, 2025
45519c8
Expose view Attributes API
sbarrio Oct 10, 2025
59f0ee9
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
e857e8c
Adapt internal testing tools package to changes done for v3
sbarrio Dec 3, 2025
305c7cc
Fixed ProxiedCore implementation
sbarrio Dec 4, 2025
f7d9af0
Remove unnecessary isInitialized check on DdLogsImplementation
sbarrio Dec 4, 2025
bf94a8b
Fix iOS tests
sbarrio Dec 4, 2025
d2b1793
Attributes Safe Encoding
marco-saia-datadog Oct 10, 2025
6d4a687
Fixed existing tests
marco-saia-datadog Oct 10, 2025
db66958
Minor warning fixes in tests
marco-saia-datadog Oct 10, 2025
cbe5260
Changed .tsx to .ts + removed left-over comment
marco-saia-datadog Oct 13, 2025
277cb22
Limit encoded attributes to 128
marco-saia-datadog Oct 21, 2025
1548a13
Add tests to ensure attributes are encoded by copy
marco-saia-datadog Oct 21, 2025
06b43d9
Missing attributes on FileBasedConfiguration and linting
sbarrio Nov 28, 2025
c355340
Add NavigationTrackingOptions to React Navigation tracking
sbarrio Nov 28, 2025
c5cd225
Add NavigationTrackingOptions to React Native Navigation tracking
sbarrio Nov 28, 2025
80990db
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
9ad062f
Codepush adaptation
sbarrio Nov 25, 2025
e41d756
Fix iOS tests
sbarrio Nov 26, 2025
7b078dc
Fix Android tests
sbarrio Nov 27, 2025
3a8cec1
Fix Typescript tests
sbarrio Nov 27, 2025
6f4b805
Edited schema configutarion description
sbarrio Dec 9, 2025
bd0fd52
Rename CoreConfiguration and RumConfiguration
sbarrio Dec 9, 2025
18e2489
Fix import of DdSdkNativeCOnfiguration type for DdSdkInternal
sbarrio Dec 10, 2025
92c0675
Correct Baggage Header Handling
marco-saia-datadog Dec 10, 2025
3e4adce
Refactored baggage header parsing for readability
marco-saia-datadog Dec 15, 2025
f32bfb9
Fix Typescript tests
sbarrio Nov 27, 2025
e8fd1ce
Rename CoreConfiguration and RumConfiguration
sbarrio Dec 9, 2025
85159cf
feat: Support trace sampling based on RUM Session ID
marco-saia-datadog Dec 9, 2025
8d64446
Bumped Datadog iOS SDK to v3.4.0
marco-saia-datadog Dec 15, 2025
9c60e95
Bump Datadog Android SDK to v3.4.0
sbarrio Dec 15, 2025
bcdb636
Fix internal testing tools core wrapping to work with v3
sbarrio Dec 15, 2025
a68b1fc
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
3c933da
Fix Typescript tests
sbarrio Nov 27, 2025
8be3b19
Use global instance for DatadogProvider state
marco-saia-datadog Dec 9, 2025
3d83deb
Use global instance for GlobalState
marco-saia-datadog Dec 9, 2025
d3a4009
Use global instance for DdBabelInteractionTracking
marco-saia-datadog Dec 9, 2025
b1d577e
Use global instance for DdRumReactNavigationTracking
marco-saia-datadog Dec 9, 2025
b31a7c2
Restore exception for androidx.performance import on RN<0.76
sbarrio Dec 15, 2025
fc23b99
Prevent encoding of internal SDK attributes
cdn34dd Jan 5, 2026
4e80afb
Improve module wrapper singleton creation
sbarrio Sep 2, 2025
a9601c0
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
e245125
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
774e5ab
Remove setUser
sbarrio Sep 12, 2025
37514b6
Fix internaltTestingTools tests
sbarrio Sep 19, 2025
9f9c318
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
ace05d5
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
3651f91
Expose clearUserInfo API
sbarrio Sep 19, 2025
fc8d29d
Update attribute API
sbarrio Sep 29, 2025
13ad8a2
JS refresh rate normalization
sbarrio Oct 16, 2025
97abf12
Expose view Attributes API
sbarrio Oct 10, 2025
d835de3
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
8a7135b
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
b379088
Remove setUser
sbarrio Sep 12, 2025
86ff62e
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
b2fc4f5
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
f441fd3
Expose clearUserInfo API
sbarrio Sep 19, 2025
60ab8e0
Update attribute API
sbarrio Sep 29, 2025
a52f3ba
JS refresh rate normalization
sbarrio Oct 16, 2025
1f3347c
Expose view Attributes API
sbarrio Oct 10, 2025
2667b4c
Expose sdk iOS config option `trackMemoryWarnings`
cdn34dd Nov 5, 2025
11074de
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
75fbb0d
Solve merge issues and fix failing native tests
sbarrio Nov 28, 2025
1a5ad5e
iOS: Always use SDK default core instance
marco-saia-datadog Sep 9, 2025
b46a9a4
Remove setUser
sbarrio Sep 12, 2025
4bd48cb
Bump Native SDKs to 3.1.0
sbarrio Sep 19, 2025
d42c8c3
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
cc9270c
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
f998e9e
Expose clearUserInfo API
sbarrio Sep 19, 2025
129b9dd
Update attribute API
sbarrio Sep 29, 2025
095bdcf
JS refresh rate normalization
sbarrio Oct 16, 2025
e3e04fa
Expose view Attributes API
sbarrio Oct 10, 2025
fa5d0a4
Bump native SDK dependencies to 3.0.0
sbarrio Sep 8, 2025
7718275
Remove setUser
sbarrio Sep 12, 2025
ca501a4
Use native sdk's core instance instead of the one inside RN SDK wrapper
sbarrio Sep 5, 2025
6370d2f
Fixed internal testing tools and unit tests
marco-saia-datadog Sep 22, 2025
332347a
Expose clearUserInfo API
sbarrio Sep 19, 2025
2741091
Update attribute API
sbarrio Sep 29, 2025
1647866
JS refresh rate normalization
sbarrio Oct 16, 2025
0373ee5
Expose view Attributes API
sbarrio Oct 10, 2025
3670255
Expose `setAccountInfo` API to JS layer
cdn34dd Nov 3, 2025
afb453a
Attributes Safe Encoding
marco-saia-datadog Oct 10, 2025
bf843d2
Changed .tsx to .ts + removed left-over comment
marco-saia-datadog Oct 13, 2025
5e12d35
Limit encoded attributes to 128
marco-saia-datadog Oct 21, 2025
c906cf0
Add NavigationTrackingOptions to React Native Navigation tracking
sbarrio Nov 28, 2025
d2ee8c9
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
5c409a5
Codepush adaptation
sbarrio Nov 25, 2025
dd2e535
Fix iOS tests
sbarrio Nov 26, 2025
c340136
Fix Typescript tests
sbarrio Nov 27, 2025
b18e7a9
Rename CoreConfiguration and RumConfiguration
sbarrio Dec 9, 2025
bff95c6
Bumped Datadog iOS SDK to v3.4.0
marco-saia-datadog Dec 15, 2025
20849be
Fix internal testing tools core wrapping to work with v3
sbarrio Dec 15, 2025
48ce93f
Restructuring of initialization API and configuration types
sbarrio Nov 25, 2025
cee6e47
Fix Typescript tests
sbarrio Nov 27, 2025
8fc744e
Solve merge conflicts
sbarrio Dec 17, 2025
9f9c2ee
Fix merge errors
sbarrio Dec 17, 2025
72d87ec
Deprecate interaction tracking in core sdk package
cdn34dd Dec 19, 2025
2708288
Change react-navigation view's key format so url_path_group is calcul…
cdn34dd Jan 12, 2026
f15482e
Update podfile.lock files from examples and benchmark
sbarrio Jan 16, 2026
7db7ccc
Merge
sbarrio Jan 16, 2026
1dba53b
Fix wrong merge
sbarrio Jan 19, 2026
888a3b8
Move resourceTraceSampleRate, nativeLongTaskThreshold, nativeCrashRep…
sbarrio Dec 18, 2025
a8e832b
Fix iOS tests
sbarrio Dec 18, 2025
9b584d8
Fix Android tests
sbarrio Dec 18, 2025
f2df627
Expose optional Rum, Logs and Trace configuration objects on Datado…
sbarrio Dec 18, 2025
a5b4c4f
Configuration constructor now retains default values
sbarrio Dec 19, 2025
6cf49b9
Refactored Initialization APIs and configs
marco-saia-datadog Dec 19, 2025
731d0a8
review: using parsed RN version in test snapshot
marco-saia-datadog Jan 5, 2026
a2fc28e
Ensure SDK does not crash if module configuration is missing
sbarrio Jan 5, 2026
6cfc1bd
Changes from PR comments
sbarrio Jan 16, 2026
c472665
Added MIGRATION.md and modified CONTRIBUTING.md to acknowledge init A…
sbarrio Jan 9, 2026
6d6a659
Update READMEs and cleaned up on sample apps
sbarrio Jan 9, 2026
3b8e5a7
Update packages/react-navigation/README.md
sbarrio Jan 12, 2026
6efb940
Merge pull request #1107 from DataDog/sbarrio/v3/update-with-latest-f…
sbarrio Jan 19, 2026
1522dc9
Merge pull request #1089 from DataDog/marcosaia/chore/refactor-init-apis
sbarrio Jan 19, 2026
2ec03b3
Merge pull request #1099 from DataDog/sbarrio/v3/update-repository-do…
sbarrio Jan 19, 2026
1e21f7d
Bump to version 3.0.0
sbarrio Jan 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 15 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,17 +142,26 @@ use_frameworks!
Now you can go back to your `App.js/tsx` and use `@datadog/mobile-react-native` from there
Example code:
```
import { DdSdkReactNative, DdSdkReactNativeConfiguration } from '@datadog/mobile-react-native';
import { DdSdkReactNative, CoreConfiguration, TrackingConsent } from '@datadog/mobile-react-native';

const App: () => React$Node = () => {
const config = new DdSdkReactNativeConfiguration(
const config = new CoreConfiguration(
"<CLIENT_TOKEN>",
"<ENVIRONMENT_NAME>",
"<RUM_APPLICATION_ID>",
true, // track User interactions (e.g.: Tap on buttons)
true, // track XHR Resources
true // track Errors
TrackingConsent.GRANTED,
{
rumConfiguration: {
applicationId: APPLICATION_ID,
trackInteractions: true,
trackResources: true,
trackFrustrations: true,
trackErrors: true,
},
logsConfiguration: {},
traceConfiguration: {}
}
)

DdSdkReactNative.initialize(config);
...
```
Expand Down
239 changes: 239 additions & 0 deletions MIGRATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,239 @@
# Migration Guide

This document outlines breaking changes and migration steps between major versions of the project.

## Migration from 2.x to 3.0

This section describes the main changes introduced in SDK `3.0` compared to `2.x`.

### Core SDK Initialization changes

The configuration object used to initialize the SDK has seen some changes in its structure.
Feature configuration is now split into feature-specific properties: rumConfiguration, logsConfiguration, traceConfiguration.

Then, RUM, Logs and Trace can be independently configured via their optional configuration objects that are each represented by a property inside the core configuration object.

**NOTE: clientToken, environment and trackingConsent are mandatory for the Core SDK initialization.
ApplicationID is mandatory for RUM to work.**

For instance, to configure the SDK and enable RUM, Logs and Trace you'd do the following:

```
const config = new CoreConfiguration(
CLIENT_TOKEN,
ENVIRONMENT,
TrackingConsent.GRANTED,
{
rumConfiguration: {
applicationId: APPLICATION_ID,
trackInteractions: true,
trackResources: true,
trackFrustrations: true,
sessionSampleRate: 100,
telemetrySampleRate: 100
}
},
logsConfiguration: {
logEventMapper: (logEvent) => {
logEvent.message = `[CUSTOM] ${logEvent.message}`;
return logEvent;
}
},
traceConfiguration: {}
);

...

await DdSdkReactNative.initialize(config);
```

Or if using the DatadogProvider wrapper:

```
const configuration = new DatadogProviderConfiguration(
CLIENT_TOKEN,
ENVIRONMENT,
TrackingConsent.GRANTED,
{
batchSize: BatchSize.SMALL,
uploadFrequency: UploadFrequency.FREQUENT,
batchProcessingLevel: BatchProcessingLevel.MEDIUM,
additionalConfiguration: {
customProperty: "sdk-example-app"
},
rumConfiguration: {
applicationId: APPLICATION_ID,
trackInteractions: true,
trackResources: true,
trackErrors: true,
sessionSampleRate: 100,
nativeCrashReportEnabled: true
},
logsConfiguration: {
logEventMapper: (logEvent) => {
logEvent.message = `[CUSTOM] ${logEvent.message}`;
return logEvent;
}
},
traceConfiguration: {}
}
);

...

<DatadogProvider configuration={configuration} onInitialization={onDatadogInitialization}>
```

**NOTE: Unlike v2.x, which would always enable all feature modules when initializing the SDK, v3 won't initialize nor enable a feature module if there's no configuration for it.**

### Property renames and relocations

| Property | New Location | Changes |
| :--- | :--- | :--- |
| `sampleRate` | *Removed* | Deprecated property removed. |
| `sessionSamplingRate` | `RumConfiguration` | Moved and renamed to `sessionSampleRate` |
| `resourceTracingSamplingRate` | `RumConfiguration` | Moved and renamed to `resourceTraceSampleRate`. |
| `proxyConfig` | `CoreConfiguration` | Renamed to `proxyConfiguration`. |
| `serviceName` | `CoreConfiguration` | Renamed to `service`. |
| `customEndpoints` | *Split* | Split into `customEndpoint` within `RumConfiguration`, `LogsConfiguration`, and `TraceConfiguration` |
| *New Property* | `CoreConfiguration` | `attributeEncoders` added. |
| *New Property* | `RumConfiguration` | `trackMemoryWarnings` added. |
| `nativeCrashReportEnabled` | `RumConfiguration` | Moved. |
| `nativeViewTracking` | `RumConfiguration` | Moved. |
| `nativeInteractionTracking` | `RumConfiguration` | Moved. |
| `firstPartyHosts` | `RumConfiguration` | Moved. |
| `telemetrySampleRate` | `RumConfiguration` | Moved. |
| `nativeLongTaskThresholdMs` | `RumConfiguration` | Moved. |
| `longTaskThresholdMs` | `RumConfiguration` | Moved. |
| `vitalsUpdateFrequency` | `RumConfiguration` | Moved. |
| `trackFrustrations` | `RumConfiguration` | Moved. |
| `trackBackgroundEvents` | `RumConfiguration` | Moved. |
| `bundleLogsWithRum` | `LogsConfiguration` | Moved. |
| `bundleLogsWithTraces` | `LogsConfiguration` | Moved. |
| `trackNonFatalAnrs` | `RumConfiguration` | Moved. |
| `appHangThreshold` | `RumConfiguration` | Moved. |
| `initialResourceThreshold` | `RumConfiguration` | Moved. |
| `trackWatchdogTerminations` | `RumConfiguration` | Moved. |
| `actionNameAttribute` | `RumConfiguration` | Moved. |
| `logEventMapper` | `LogsConfiguration` | Moved. |
| `errorEventMapper` | `RumConfiguration` | Moved. |
| `resourceEventMapper` | `RumConfiguration` | Moved. |
| `actionEventMapper` | `RumConfiguration` | Moved. |`TraceConfiguration`. |
| `useAccessibilityLabel` | `RumConfiguration` | Moved. |
| `trackInteractions` | `RumConfiguration` | Moved. |
| `trackResources` | `RumConfiguration` | Moved. |
| `trackErrors` | `RumConfiguration` | Moved. |

### FileBasedConfiguration changes

FileBasedConfiguration now requires a path to a configuration JSON file instead of trying to find a default `datadog-configuration.json` at the app's root level like it did on v2.

### Changes to SessionReplay configuration
defaultPrivacyLevel has been removed in favor of granular options: imagePrivacyLevel, touchPrivacyLevel and textAndInputPrivacyLevel.

### Fatal Errors are no longer reported as logs

Fatal Errors are no longer automatically reported as Logs. Fatal crashes will still be captured, but are no longer duplicated in Logs by default.

### Context / Attribute encoding
Context / attributes encoding is now safe and deterministic
All attributes passed to Datadog SDK APIs are automatically sanitized and encoded:
Unsupported values (functions, symbols, non-finite numbers, etc.) are dropped with a warning to prevent crashes and undefined behavior
Common types (Date, Error, Map) are properly serialized
Nested objects are flattened using dot notation (a.b.c = value) to match native SDK expectations
Root-level primitives and arrays are wrapped under a context key for schema consistency
Custom encoders can be registered via the attributeEncoders configuration option for domain-specific types

### Android mindSdkVersion bumped to 23
Android's minSdkVersion has been bumped to 23.

### Resource Traces sampling aligned with RUM Sessions
Resource traces are now consistently sampled based on the active RUM session.
You may notice changes in the percentage of reported resources.

### JS Refresh rate normalization changes
JS refresh rate is now normalized to a 0–60 FPS range.

### RUM Session sampling changes
v3 modifies the logic to determine whether a trace should be sampled or not, by using the RUM Session ID first, before using the Trace sampling if no session can be found.

Consistent trace sampling based on RUM Session ID allows RUM clients and the backend to come to a the same decision about sampling without relying on randomness for each trace.

### Removed APIs

| API | Status |
| :--- | :--- |
| setUser | Removed in favor of setUserInfo. To completely remove userInfo please use the newly added clearUserInfo |
| setAttributes| Removed in favor of addAttributes |

### Attributes API
The attribute API has been expanded allowing for addition and removal of single or batches of attributes in bulk.This can be performed with the new granular APIs: addAttributes, removeAttributes, addAttribute and removeAttribute.

### New APIs

#### ViewAttributes

RUM View-level attributes are now automatically propagated to all related child events, including resources, user actions, errors, and long tasks. This ensures consistent metadata across events, making it easier to filter and correlate data on Datadog dashboards.

To manage View level attributes more effectively, new APIs were added:

```
addViewAttribute = (key: string, value: unknown)
removeViewAttribute = (key: string)
addViewAttributes = (attributes: Attributes)
removeViewAttributes = (keys: string[])
```

#### AccountInfo
The AccountInfo API from the native Datadog SDKs has been exposed to React Native as well:

```
setAccountInfo = async (accountInfo: {
id: string;
name?: string;
extraInfo?: Record<string, unknown>;
})

clearAccountInfo = async ()

addAccountExtraInfo = async (extraAccountInfo: Record<string, unknown>)
```

#### Feature Operations

```
startFeatureOperation(
name: string,
operationKey: string | null,
attributes: object
): Promise<void>

succeedFeatureOperation(
name: string,
operationKey: string | null,
attributes: object
): Promise<void>

failFeatureOperation(
name: string,
operationKey: string | null,
reason: FeatureOperationFailure,
attributes: object
): Promise<void>
```

### New Navigation Tracking Options

v3 modifies the automatic navigation tracking modules for React Navigation and React Native Navigation and exposes a new NavigationTrackingOptions parameter through the startTracking/startTrackingViews function.

This `options` object allows to customize the view tracking logic via 3 new optional predicate functions:

- ViewNamePredicate - a custom naming predicates that decide the display name of views tracked by RUM.
- ViewTrackingPredicate - a custom predicate that decides if a view needs to be tracked by RUM or not.
- ParamsTrackingPredicate - a custom predicate that decides which navigation parameters (if any) need to be tracked alongside the view on RUM.

All of these are optional, and when not set the default behavior will be used for each one of them. The default behaviours are as follows:

- ViewNamePredicate - directly forwards the view given name to RUM.
- ViewTrackingPredicate - tracks all views on RUM.
- ParamsTrackingPredicate - does not forward any parameters to RUM.
1 change: 1 addition & 0 deletions NATIVE_SDK_VERSIONS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
| React Native | iOS Bridge / iOS SDK | Android Bridge / Android SDK |
|-------------|---------------------|-----------------------------|
| 3.0.0 | 3.4.0 | 3.4.0 |
| 2.14.1 | 2.30.2 | 2.26.2 |
| 2.14.0 | 2.30.2 | 2.26.2 |
| 2.13.2 | 2.30.2 | 2.26.2 |
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -129,5 +129,5 @@ dependencies {

// Benchmark tools from dd-sdk-android are used for vitals recording
// Remember to bump thid alongside the main dd-sdk-android dependencies
implementation("com.datadoghq:dd-sdk-android-benchmark-internal:2.25.0")
implementation("com.datadoghq:dd-sdk-android-benchmark-internal:3.4.0")
}
Loading
Loading