Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
15 changes: 14 additions & 1 deletion packages/core/src/domain/telemetry/telemetryEvent.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,10 @@ export type TelemetryConfigurationEvent = CommonTelemetryProperties & {
* The version of Unity used in a Unity application
*/
unity_version?: string
/**
* The version of MAUI used in a .NET MAUI application
*/
maui_version?: string
/**
* The threshold used for iOS App Hangs monitoring (in milliseconds)
*/
Expand Down Expand Up @@ -447,7 +451,7 @@ export type TelemetryConfigurationEvent = CommonTelemetryProperties & {
*/
sdk_version?: string
/**
* The source of the SDK, e.g., 'browser', 'ios', 'android', 'flutter', 'react-native', 'unity', 'kotlin-multiplatform'.
* The source of the SDK, e.g., 'browser', 'ios', 'android', 'flutter', 'react-native', 'unity', 'kotlin-multiplatform', 'maui'.
*/
source?: string
/**
Expand Down Expand Up @@ -545,6 +549,7 @@ export type TelemetryBrowserFeaturesUsage =
| StopAction
| StartResource
| StopResource
| SourceCodeContext
/**
* Schema of mobile specific features usage
*/
Expand Down Expand Up @@ -589,6 +594,7 @@ export interface CommonTelemetryProperties {
| 'kotlin-multiplatform'
| 'electron'
| 'rum-cpp'
| 'maui'
/**
* The version of the SDK generating the telemetry event
*/
Expand Down Expand Up @@ -970,6 +976,13 @@ export interface StopResource {
feature: 'stop-resource'
[k: string]: unknown
}
export interface SourceCodeContext {
/**
* DD_SOURCE_CODE_CONTEXT global for microfrontends
*/
feature: 'source-code-context'
[k: string]: unknown
}
export interface TrackWebView {
/**
* trackWebView API
Expand Down
10 changes: 9 additions & 1 deletion packages/rum-core/src/domain/contexts/sourceCodeContext.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
import { SKIPPED, computeStackTrace, objectEntries, addTelemetryError, HookNames } from '@datadog/browser-core'
import {
SKIPPED,
computeStackTrace,
objectEntries,
addTelemetryError,
HookNames,
addTelemetryUsage,
} from '@datadog/browser-core'
import type { Hooks, DefaultRumEventAttributes, AssembleHookParams } from '../hooks'

interface SourceCodeContext {
Expand All @@ -19,6 +26,7 @@ export function startSourceCodeContext(hooks: Hooks) {
if (!browserWindow.DD_SOURCE_CODE_CONTEXT) {
return
}
addTelemetryUsage({ feature: 'source-code-context' })

objectEntries(browserWindow.DD_SOURCE_CODE_CONTEXT).forEach(([stack, context]) => {
const stackTrace = computeStackTrace({ stack })
Expand Down
5 changes: 4 additions & 1 deletion packages/rum-core/src/rumEvent.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export type RumActionEvent = CommonProperties &
*/
readonly height?: number
/**
* Mobile-only: a globally unique and stable identifier for this UI element, computed as the hash of the element's path (32 lowercase hex characters). Used to correlate actions with mobile session replay wireframes.
* Mobile-only: a globally unique and stable identifier for this UI element, computed as the hash of the element's path. Used to correlate actions with mobile session replay wireframes.
*/
readonly permanent_id?: string
[k: string]: unknown
Expand Down Expand Up @@ -321,6 +321,7 @@ export type RumErrorEvent = CommonProperties &
| 'windows'
| 'macos'
| 'linux'
| 'maui'
/**
* Resource properties of the error
*/
Expand Down Expand Up @@ -1172,6 +1173,7 @@ export interface CommonProperties {
| 'kotlin-multiplatform'
| 'electron'
| 'rum-cpp'
| 'maui'
/**
* View properties
*/
Expand Down Expand Up @@ -1525,6 +1527,7 @@ export interface ViewContainerSchema {
| 'kotlin-multiplatform'
| 'electron'
| 'rum-cpp'
| 'maui'
[k: string]: unknown
}
[k: string]: unknown
Expand Down
2 changes: 1 addition & 1 deletion rum-events-format
Submodule rum-events-format updated 30 files
+6 −6 lib/cjs/generated/mobileSessionReplay.d.ts
+4 −4 lib/cjs/generated/rum.d.ts
+6 −6 lib/cjs/generated/sessionReplay.d.ts
+14 −3 lib/cjs/generated/telemetry.d.ts
+1 −0 lib/cjs/src/session-replay-mobile.d.ts
+1 −0 lib/cjs/src/session-replay-mobile.js
+6 −6 lib/esm/generated/mobileSessionReplay.d.ts
+4 −4 lib/esm/generated/rum.d.ts
+6 −6 lib/esm/generated/sessionReplay.d.ts
+14 −3 lib/esm/generated/telemetry.d.ts
+1 −0 lib/esm/src/session-replay-mobile.d.ts
+1 −0 lib/esm/src/session-replay-mobile.js
+1 −0 lib/src/session-replay-mobile.ts
+7 −0 schemas/profiling-mobile-rum-metadata-event-schema.json
+38 −0 schemas/profiling/mobile/profile-rum-metadata-event-schema.json
+2 −1 schemas/rum/_common-schema.json
+2 −1 schemas/rum/_view-container-schema.json
+1 −1 schemas/rum/action-schema.json
+2 −1 schemas/rum/error-schema.json
+1 −1 schemas/session-replay/mobile/image-wireframe-schema.json
+1 −1 schemas/session-replay/mobile/placeholder-wireframe-schema.json
+1 −1 schemas/session-replay/mobile/segment-metadata-schema.json
+1 −1 schemas/session-replay/mobile/shape-wireframe-schema.json
+1 −1 schemas/session-replay/mobile/text-wireframe-schema.json
+1 −1 schemas/session-replay/mobile/webview-wireframe-schema.json
+2 −1 schemas/telemetry/_common-schema.json
+6 −1 schemas/telemetry/configuration-schema.json
+11 −0 schemas/telemetry/usage/browser-features-schema.json
+1 −0 scripts/generate.mjs
+1 −0 scripts/validate.mjs
Loading