@datadog/mobile-react-native-code-push 2.3.2 → 2.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/typescript/core/src/DdSdkReactNativeConfiguration.d.ts +7 -7
- package/lib/typescript/core/src/logs/types.d.ts +10 -10
- package/lib/typescript/core/src/nativeModulesTypes.d.ts +5 -5
- package/lib/typescript/core/src/rum/eventMappers/actionEventMapper.d.ts +4 -4
- package/lib/typescript/core/src/rum/eventMappers/errorEventMapper.d.ts +4 -4
- package/lib/typescript/core/src/rum/eventMappers/resourceEventMapper.d.ts +4 -4
- package/lib/typescript/core/src/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.d.ts +3 -3
- package/lib/typescript/core/src/rum/instrumentation/resourceTracking/distributedTracing/firstPartyHosts.d.ts +1 -1
- package/lib/typescript/core/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/DatadogRumResource/ResourceReporter.d.ts +1 -1
- package/lib/typescript/core/src/rum/instrumentation/resourceTracking/requestProxy/interfaces/RequestProxy.d.ts +1 -1
- package/lib/typescript/core/src/rum/instrumentation/resourceTracking/requestProxy/interfaces/RumResource.d.ts +1 -1
- package/lib/typescript/core/src/rum/types.d.ts +3 -3
- package/lib/typescript/core/src/sdk/AttributesSingleton/types.d.ts +1 -1
- package/lib/typescript/core/src/sdk/DatadogProvider/DatadogProvider.d.ts +2 -2
- package/lib/typescript/core/src/sdk/EventMappers/EventMapper.d.ts +1 -1
- package/lib/typescript/core/src/sdk/UserInfoSingleton/types.d.ts +1 -1
- package/lib/typescript/core/src/types.d.ts +2 -2
- package/lib/typescript/core/src/utils/TimeProvider.d.ts +1 -1
- package/lib/typescript/core/src/version.d.ts +1 -1
- package/package.json +3 -3
|
@@ -40,9 +40,9 @@ export declare enum BatchSize {
|
|
|
40
40
|
*/
|
|
41
41
|
SMALL = "SMALL"
|
|
42
42
|
}
|
|
43
|
-
export
|
|
44
|
-
export
|
|
45
|
-
export
|
|
43
|
+
export type FirstPartyHostsConfiguration = (FirstPartyHost | LegacyFirstPartyHost)[];
|
|
44
|
+
export type LegacyFirstPartyHost = string;
|
|
45
|
+
export type CustomEndpoints = {
|
|
46
46
|
rum?: string;
|
|
47
47
|
logs?: string;
|
|
48
48
|
trace?: string;
|
|
@@ -243,7 +243,7 @@ export declare class DdSdkReactNativeConfiguration {
|
|
|
243
243
|
* Auto Instrumentation configuration passed to DatadogProvider.
|
|
244
244
|
* Does not include default values.
|
|
245
245
|
*/
|
|
246
|
-
export
|
|
246
|
+
export type AutoInstrumentationConfiguration = {
|
|
247
247
|
readonly trackInteractions: boolean;
|
|
248
248
|
readonly trackResources: boolean;
|
|
249
249
|
readonly firstPartyHosts?: FirstPartyHostsConfiguration;
|
|
@@ -258,7 +258,7 @@ export declare type AutoInstrumentationConfiguration = {
|
|
|
258
258
|
/**
|
|
259
259
|
* Parameters needed to start auto instrumentation. Includes default values.
|
|
260
260
|
*/
|
|
261
|
-
export
|
|
261
|
+
export type AutoInstrumentationParameters = {
|
|
262
262
|
readonly trackInteractions: boolean;
|
|
263
263
|
readonly trackResources: boolean;
|
|
264
264
|
readonly firstPartyHosts: FirstPartyHostsConfiguration;
|
|
@@ -275,7 +275,7 @@ export declare type AutoInstrumentationParameters = {
|
|
|
275
275
|
* the older android jsc that can still be used.
|
|
276
276
|
*/
|
|
277
277
|
export declare const addDefaultValuesToAutoInstrumentationConfiguration: (features: AutoInstrumentationConfiguration) => AutoInstrumentationParameters;
|
|
278
|
-
export
|
|
278
|
+
export type PartialInitializationConfiguration = {
|
|
279
279
|
readonly clientToken: string;
|
|
280
280
|
readonly env: string;
|
|
281
281
|
readonly applicationId: string;
|
|
@@ -313,4 +313,4 @@ export declare enum InitializationMode {
|
|
|
313
313
|
SYNC = "SYNC",
|
|
314
314
|
ASYNC = "ASYNC"
|
|
315
315
|
}
|
|
316
|
-
export
|
|
316
|
+
export type InitializationModeForTelemetry = 'LEGACY' | 'SYNC' | 'ASYNC' | 'PARTIAL' | 'FILE';
|
|
@@ -2,7 +2,7 @@ import type { UserInfo } from '../sdk/UserInfoSingleton/types';
|
|
|
2
2
|
/**
|
|
3
3
|
* The entry point to use Datadog's Logs feature.
|
|
4
4
|
*/
|
|
5
|
-
export
|
|
5
|
+
export type DdLogsType = {
|
|
6
6
|
/**
|
|
7
7
|
* Send a log with debug level.
|
|
8
8
|
* @param message: The message to send.
|
|
@@ -31,12 +31,12 @@ export declare type DdLogsType = {
|
|
|
31
31
|
/**
|
|
32
32
|
* Log input from developers
|
|
33
33
|
*/
|
|
34
|
-
export
|
|
34
|
+
export type RawLog = {
|
|
35
35
|
message: string;
|
|
36
36
|
context: object;
|
|
37
37
|
status: LogStatus;
|
|
38
38
|
};
|
|
39
|
-
export
|
|
39
|
+
export type RawLogWithError = {
|
|
40
40
|
message: string;
|
|
41
41
|
errorKind: string;
|
|
42
42
|
errorMessage: string;
|
|
@@ -47,19 +47,19 @@ export declare type RawLogWithError = {
|
|
|
47
47
|
/**
|
|
48
48
|
* Log input for native SDKs
|
|
49
49
|
*/
|
|
50
|
-
export
|
|
50
|
+
export type NativeLog = {
|
|
51
51
|
message: string;
|
|
52
52
|
context: object;
|
|
53
53
|
};
|
|
54
|
-
export
|
|
54
|
+
export type NativeLogWithError = {
|
|
55
55
|
message: string;
|
|
56
56
|
errorKind: string;
|
|
57
57
|
errorMessage: string;
|
|
58
58
|
stacktrace: string;
|
|
59
59
|
context: object;
|
|
60
60
|
};
|
|
61
|
-
export
|
|
62
|
-
export
|
|
61
|
+
export type LogStatus = 'debug' | 'info' | 'warn' | 'error';
|
|
62
|
+
export type LogEvent = {
|
|
63
63
|
message: string;
|
|
64
64
|
context: object;
|
|
65
65
|
errorKind?: string;
|
|
@@ -69,9 +69,9 @@ export declare type LogEvent = {
|
|
|
69
69
|
readonly userInfo: UserInfo;
|
|
70
70
|
readonly attributes?: object;
|
|
71
71
|
};
|
|
72
|
-
export
|
|
73
|
-
export
|
|
74
|
-
export
|
|
72
|
+
export type LogEventMapper = (logEvent: LogEvent) => LogEvent | null;
|
|
73
|
+
export type LogArguments = [message: string, context?: object];
|
|
74
|
+
export type LogWithErrorArguments = [
|
|
75
75
|
message: string,
|
|
76
76
|
errorKind?: string,
|
|
77
77
|
errorMessage?: string,
|
|
@@ -9,11 +9,11 @@ import type { Spec as NativeDdTrace } from './specs/NativeDdTrace';
|
|
|
9
9
|
/**
|
|
10
10
|
* The entry point to use Datadog's Logs feature.
|
|
11
11
|
*/
|
|
12
|
-
export
|
|
12
|
+
export type DdNativeLogsType = NativeDdLogs;
|
|
13
13
|
/**
|
|
14
14
|
* The entry point to use Datadog's Trace feature.
|
|
15
15
|
*/
|
|
16
|
-
export
|
|
16
|
+
export type DdNativeTraceType = NativeDdTrace;
|
|
17
17
|
/**
|
|
18
18
|
* A configuration object to initialize Datadog's features.
|
|
19
19
|
*/
|
|
@@ -38,9 +38,9 @@ export interface DdNativeSdkType extends NativeDdSdk {
|
|
|
38
38
|
*/
|
|
39
39
|
initialize(configuration: DdNativeSdkConfiguration): Promise<void>;
|
|
40
40
|
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
type ActionType = 'TAP' | 'SCROLL' | 'SWIPE' | 'BACK' | 'CUSTOM';
|
|
42
|
+
type ResourceKind = 'image' | 'xhr' | 'beacon' | 'css' | 'document' | 'fetch' | 'font' | 'js' | 'media' | 'other' | 'native';
|
|
43
|
+
type ErrorSource = 'NETWORK' | 'SOURCE' | 'CONSOLE' | 'WEBVIEW' | 'CUSTOM';
|
|
44
44
|
/**
|
|
45
45
|
* The entry point to use Datadog's RUM feature.
|
|
46
46
|
*/
|
|
@@ -2,20 +2,20 @@ import type { GestureResponderEvent } from 'react-native';
|
|
|
2
2
|
import type { AdditionalEventDataForMapper } from '../../sdk/EventMappers/EventMapper';
|
|
3
3
|
import { EventMapper } from '../../sdk/EventMappers/EventMapper';
|
|
4
4
|
import type { RumActionType } from '../types';
|
|
5
|
-
|
|
5
|
+
type RawAction = {
|
|
6
6
|
readonly type: RumActionType;
|
|
7
7
|
readonly name: string;
|
|
8
8
|
context: object;
|
|
9
9
|
readonly timestampMs: number;
|
|
10
10
|
actionContext?: GestureResponderEvent;
|
|
11
11
|
};
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
type ActionEvent = RawAction & AdditionalEventDataForMapper;
|
|
13
|
+
type NativeAction = {
|
|
14
14
|
type: RumActionType;
|
|
15
15
|
name: string;
|
|
16
16
|
context: object;
|
|
17
17
|
timestampMs: number;
|
|
18
18
|
};
|
|
19
|
-
export
|
|
19
|
+
export type ActionEventMapper = (event: ActionEvent) => ActionEvent | null;
|
|
20
20
|
export declare const generateActionEventMapper: (eventMapper: ActionEventMapper | undefined) => EventMapper<RawAction, ActionEvent, NativeAction>;
|
|
21
21
|
export {};
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import type { AdditionalEventDataForMapper } from '../../sdk/EventMappers/EventMapper';
|
|
2
2
|
import { EventMapper } from '../../sdk/EventMappers/EventMapper';
|
|
3
3
|
import type { ErrorSource } from '../types';
|
|
4
|
-
|
|
4
|
+
type RawError = {
|
|
5
5
|
message: string;
|
|
6
6
|
source: ErrorSource;
|
|
7
7
|
stacktrace: string;
|
|
8
8
|
context: object;
|
|
9
9
|
timestampMs: number;
|
|
10
10
|
};
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
type ErrorEvent = RawError & AdditionalEventDataForMapper;
|
|
12
|
+
type NativeError = {
|
|
13
13
|
message: string;
|
|
14
14
|
source: ErrorSource;
|
|
15
15
|
stacktrace: string;
|
|
16
16
|
context: object;
|
|
17
17
|
timestampMs: number;
|
|
18
18
|
};
|
|
19
|
-
export
|
|
19
|
+
export type ErrorEventMapper = (event: ErrorEvent) => ErrorEvent | null;
|
|
20
20
|
export declare const generateErrorEventMapper: (eventMapper: ErrorEventMapper | undefined) => EventMapper<RawError, ErrorEvent, NativeError>;
|
|
21
21
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { AdditionalEventDataForMapper } from '../../sdk/EventMappers/EventMapper';
|
|
2
2
|
import { EventMapper } from '../../sdk/EventMappers/EventMapper';
|
|
3
3
|
import type { ResourceKind } from '../types';
|
|
4
|
-
|
|
4
|
+
type RawResource = {
|
|
5
5
|
readonly key: string;
|
|
6
6
|
readonly statusCode: number;
|
|
7
7
|
readonly kind: ResourceKind;
|
|
@@ -10,8 +10,8 @@ declare type RawResource = {
|
|
|
10
10
|
readonly timestampMs: number;
|
|
11
11
|
resourceContext: XMLHttpRequest | undefined;
|
|
12
12
|
};
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
type ResourceEvent = RawResource & AdditionalEventDataForMapper;
|
|
14
|
+
type NativeResource = {
|
|
15
15
|
key: string;
|
|
16
16
|
statusCode: number;
|
|
17
17
|
kind: ResourceKind;
|
|
@@ -19,6 +19,6 @@ declare type NativeResource = {
|
|
|
19
19
|
context: object;
|
|
20
20
|
timestampMs: number;
|
|
21
21
|
};
|
|
22
|
-
export
|
|
22
|
+
export type ResourceEventMapper = (event: ResourceEvent) => ResourceEvent | null;
|
|
23
23
|
export declare const generateResourceEventMapper: (eventMapper: ResourceEventMapper | undefined) => EventMapper<RawResource, ResourceEvent, NativeResource>;
|
|
24
24
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { PropagatorType } from '../../../types';
|
|
2
2
|
import type { RegexMap } from '../requestProxy/interfaces/RequestProxy';
|
|
3
3
|
import type { Hostname } from './firstPartyHosts';
|
|
4
|
-
export
|
|
4
|
+
export type DdRumResourceTracingAttributes = {
|
|
5
5
|
tracingStrategy: 'KEEP';
|
|
6
6
|
traceId: TraceId;
|
|
7
7
|
spanId: SpanId;
|
|
@@ -23,10 +23,10 @@ export declare const getTracingAttributes: ({ hostname, firstPartyHostsRegexMap,
|
|
|
23
23
|
* Using branded types will ensure we don't accidentally use
|
|
24
24
|
* traceId for spanId when generating headers.
|
|
25
25
|
*/
|
|
26
|
-
export
|
|
26
|
+
export type TraceId = TraceIdentifier & {
|
|
27
27
|
_brand: 'traceId';
|
|
28
28
|
};
|
|
29
|
-
export
|
|
29
|
+
export type SpanId = TraceIdentifier & {
|
|
30
30
|
_brand: 'spanId';
|
|
31
31
|
};
|
|
32
32
|
export declare class TraceIdentifier {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { FirstPartyHost, PropagatorType } from '../../../types';
|
|
2
2
|
import type { RegexMap } from '../requestProxy/interfaces/RequestProxy';
|
|
3
|
-
export
|
|
3
|
+
export type Hostname = {
|
|
4
4
|
_type: 'Hostname';
|
|
5
5
|
} & string;
|
|
6
6
|
export declare const NO_MATCH_REGEX: RegExp;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { RUMResource } from '../../interfaces/RumResource';
|
|
2
|
-
|
|
2
|
+
type ResourceMapper = (resource: RUMResource) => RUMResource | null;
|
|
3
3
|
export declare class ResourceReporter {
|
|
4
4
|
private mappers;
|
|
5
5
|
constructor(resourceMappers: ResourceMapper[]);
|
|
@@ -20,7 +20,7 @@ export interface RUMResource {
|
|
|
20
20
|
};
|
|
21
21
|
resourceContext?: XMLHttpRequest;
|
|
22
22
|
}
|
|
23
|
-
export
|
|
23
|
+
export type DdRumResourceGraphqlAttributes = {
|
|
24
24
|
operationType?: string;
|
|
25
25
|
operationName?: string;
|
|
26
26
|
variables?: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The entry point to use Datadog's RUM feature.
|
|
3
3
|
*/
|
|
4
|
-
export
|
|
4
|
+
export type DdRumType = {
|
|
5
5
|
/**
|
|
6
6
|
* Start tracking a RUM View.
|
|
7
7
|
* @param key: The view unique key identifier.
|
|
@@ -104,7 +104,7 @@ export declare enum RumActionType {
|
|
|
104
104
|
/** A custom action. */
|
|
105
105
|
CUSTOM = "CUSTOM"
|
|
106
106
|
}
|
|
107
|
-
export
|
|
107
|
+
export type ResourceKind = 'image' | 'xhr' | 'beacon' | 'css' | 'document' | 'fetch' | 'font' | 'js' | 'media' | 'other' | 'native';
|
|
108
108
|
export declare enum ErrorSource {
|
|
109
109
|
NETWORK = "NETWORK",
|
|
110
110
|
SOURCE = "SOURCE",
|
|
@@ -125,7 +125,7 @@ export declare enum PropagatorType {
|
|
|
125
125
|
B3 = "b3",
|
|
126
126
|
B3MULTI = "b3multi"
|
|
127
127
|
}
|
|
128
|
-
export
|
|
128
|
+
export type FirstPartyHost = {
|
|
129
129
|
match: string;
|
|
130
130
|
propagatorTypes: PropagatorType[];
|
|
131
131
|
};
|
|
@@ -3,7 +3,7 @@ import type { PropsWithChildren } from 'react';
|
|
|
3
3
|
import { DatadogProviderConfiguration } from '../../DdSdkReactNativeConfiguration';
|
|
4
4
|
import type { PartialInitializationConfiguration, AutoInstrumentationConfiguration } from '../../DdSdkReactNativeConfiguration';
|
|
5
5
|
import type { FileBasedConfiguration } from '../FileBasedConfiguration/FileBasedConfiguration';
|
|
6
|
-
|
|
6
|
+
type Props = PropsWithChildren<{
|
|
7
7
|
/**
|
|
8
8
|
* If a `DatadogProviderConfiguration` instance is passed, the SDK will start tracking errors, resources and actions and sending events.
|
|
9
9
|
*
|
|
@@ -15,7 +15,7 @@ declare type Props = PropsWithChildren<{
|
|
|
15
15
|
*/
|
|
16
16
|
onInitialization?: () => void;
|
|
17
17
|
}>;
|
|
18
|
-
|
|
18
|
+
type StaticProperties = {
|
|
19
19
|
initialize: (configuration: PartialInitializationConfiguration) => Promise<void>;
|
|
20
20
|
onInitialization?: () => void;
|
|
21
21
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Attributes } from '../AttributesSingleton/types';
|
|
2
2
|
import type { UserInfo } from '../UserInfoSingleton/types';
|
|
3
|
-
export
|
|
3
|
+
export type AdditionalEventDataForMapper = {
|
|
4
4
|
userInfo: UserInfo;
|
|
5
5
|
attributes: Attributes;
|
|
6
6
|
};
|
|
@@ -73,7 +73,7 @@ export declare class DdSdkConfiguration {
|
|
|
73
73
|
/**
|
|
74
74
|
* The entry point to initialize Datadog's features.
|
|
75
75
|
*/
|
|
76
|
-
export
|
|
76
|
+
export type DdSdkType = {
|
|
77
77
|
/**
|
|
78
78
|
* Initializes Datadog's features.
|
|
79
79
|
* @param configuration: The configuration to use.
|
|
@@ -98,7 +98,7 @@ export declare type DdSdkType = {
|
|
|
98
98
|
/**
|
|
99
99
|
* The entry point to use Datadog's Trace feature.
|
|
100
100
|
*/
|
|
101
|
-
export
|
|
101
|
+
export type DdTraceType = {
|
|
102
102
|
/**
|
|
103
103
|
* Start a span, and returns a unique identifier for the span.
|
|
104
104
|
* @param operation: The operation name of the span.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "2.3.
|
|
1
|
+
export declare const version = "2.3.3";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@datadog/mobile-react-native-code-push",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.3",
|
|
4
4
|
"description": "A client-side React Native module to interact with Appcenter Codepush and Datadog",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"datadog",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"prepare": "rm -rf lib && yarn bob build"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@datadog/mobile-react-native": "^2.3.
|
|
41
|
+
"@datadog/mobile-react-native": "^2.3.3",
|
|
42
42
|
"@testing-library/react-native": "7.0.2",
|
|
43
43
|
"react-native-builder-bob": "0.17.1",
|
|
44
44
|
"react-native-code-push": "7.0.5"
|
|
@@ -78,5 +78,5 @@
|
|
|
78
78
|
]
|
|
79
79
|
]
|
|
80
80
|
},
|
|
81
|
-
"gitHead": "
|
|
81
|
+
"gitHead": "f9db01676449a1e3e31ad32ba20d1bcf360556e5"
|
|
82
82
|
}
|