@fluidframework/fluid-telemetry 2.0.0-dev-rc.3.0.0.254513 → 2.0.0-dev-rc.3.0.0.254674
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/dist/alpha.d.ts +27 -0
- package/dist/beta.d.ts +27 -0
- package/dist/public.d.ts +13 -0
- package/lib/alpha.d.ts +27 -0
- package/lib/beta.d.ts +27 -0
- package/lib/public.d.ts +13 -0
- package/package.json +14 -21
- package/api-extractor-cjs.json +0 -30
- package/dist/fluid-telemetry-alpha.d.ts +0 -229
- package/dist/fluid-telemetry-beta.d.ts +0 -229
- package/dist/fluid-telemetry-public.d.ts +0 -35
- package/dist/fluid-telemetry-untrimmed.d.ts +0 -229
- package/dist/tsdoc-metadata.json +0 -11
- package/lib/fluid-telemetry-alpha.d.ts +0 -229
- package/lib/fluid-telemetry-beta.d.ts +0 -229
- package/lib/fluid-telemetry-public.d.ts +0 -35
- package/lib/fluid-telemetry-untrimmed.d.ts +0 -229
package/dist/alpha.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError,
|
|
13
|
+
|
|
14
|
+
// beta APIs
|
|
15
|
+
AppInsightsTelemetryConsumer,
|
|
16
|
+
ContainerConnectedTelemetry,
|
|
17
|
+
ContainerDisconnectedTelemetry,
|
|
18
|
+
ContainerDisposedTelemetry,
|
|
19
|
+
ContainerTelemetryEventName,
|
|
20
|
+
ContainerTelemetryEventNames,
|
|
21
|
+
FluidTelemetryEventName,
|
|
22
|
+
IContainerTelemetry,
|
|
23
|
+
IFluidTelemetry,
|
|
24
|
+
ITelemetryConsumer,
|
|
25
|
+
TelemetryConfig,
|
|
26
|
+
startTelemetry
|
|
27
|
+
} from "./index.js";
|
package/dist/beta.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError,
|
|
13
|
+
|
|
14
|
+
// beta APIs
|
|
15
|
+
AppInsightsTelemetryConsumer,
|
|
16
|
+
ContainerConnectedTelemetry,
|
|
17
|
+
ContainerDisconnectedTelemetry,
|
|
18
|
+
ContainerDisposedTelemetry,
|
|
19
|
+
ContainerTelemetryEventName,
|
|
20
|
+
ContainerTelemetryEventNames,
|
|
21
|
+
FluidTelemetryEventName,
|
|
22
|
+
IContainerTelemetry,
|
|
23
|
+
IFluidTelemetry,
|
|
24
|
+
ITelemetryConsumer,
|
|
25
|
+
TelemetryConfig,
|
|
26
|
+
startTelemetry
|
|
27
|
+
} from "./index.js";
|
package/dist/public.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError
|
|
13
|
+
} from "./index.js";
|
package/lib/alpha.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError,
|
|
13
|
+
|
|
14
|
+
// beta APIs
|
|
15
|
+
AppInsightsTelemetryConsumer,
|
|
16
|
+
ContainerConnectedTelemetry,
|
|
17
|
+
ContainerDisconnectedTelemetry,
|
|
18
|
+
ContainerDisposedTelemetry,
|
|
19
|
+
ContainerTelemetryEventName,
|
|
20
|
+
ContainerTelemetryEventNames,
|
|
21
|
+
FluidTelemetryEventName,
|
|
22
|
+
IContainerTelemetry,
|
|
23
|
+
IFluidTelemetry,
|
|
24
|
+
ITelemetryConsumer,
|
|
25
|
+
TelemetryConfig,
|
|
26
|
+
startTelemetry
|
|
27
|
+
} from "./index.js";
|
package/lib/beta.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError,
|
|
13
|
+
|
|
14
|
+
// beta APIs
|
|
15
|
+
AppInsightsTelemetryConsumer,
|
|
16
|
+
ContainerConnectedTelemetry,
|
|
17
|
+
ContainerDisconnectedTelemetry,
|
|
18
|
+
ContainerDisposedTelemetry,
|
|
19
|
+
ContainerTelemetryEventName,
|
|
20
|
+
ContainerTelemetryEventNames,
|
|
21
|
+
FluidTelemetryEventName,
|
|
22
|
+
IContainerTelemetry,
|
|
23
|
+
IFluidTelemetry,
|
|
24
|
+
ITelemetryConsumer,
|
|
25
|
+
TelemetryConfig,
|
|
26
|
+
startTelemetry
|
|
27
|
+
} from "./index.js";
|
package/lib/public.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
+
*/
|
|
10
|
+
export {
|
|
11
|
+
// public APIs
|
|
12
|
+
ICriticalContainerError
|
|
13
|
+
} from "./index.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/fluid-telemetry",
|
|
3
|
-
"version": "2.0.0-dev-rc.3.0.0.
|
|
3
|
+
"version": "2.0.0-dev-rc.3.0.0.254674",
|
|
4
4
|
"description": "Customer facing Fluid telemetry types and classes for both producing and consuming said telemetry",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": {
|
|
@@ -25,21 +25,21 @@
|
|
|
25
25
|
},
|
|
26
26
|
"./public": {
|
|
27
27
|
"import": {
|
|
28
|
-
"types": "./lib/
|
|
28
|
+
"types": "./lib/public.d.ts",
|
|
29
29
|
"default": "./lib/index.js"
|
|
30
30
|
},
|
|
31
31
|
"require": {
|
|
32
|
-
"types": "./dist/
|
|
32
|
+
"types": "./dist/public.d.ts",
|
|
33
33
|
"default": "./dist/index.js"
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
"./beta": {
|
|
37
37
|
"import": {
|
|
38
|
-
"types": "./lib/
|
|
38
|
+
"types": "./lib/beta.d.ts",
|
|
39
39
|
"default": "./lib/index.js"
|
|
40
40
|
},
|
|
41
41
|
"require": {
|
|
42
|
-
"types": "./dist/
|
|
42
|
+
"types": "./dist/beta.d.ts",
|
|
43
43
|
"default": "./dist/index.js"
|
|
44
44
|
}
|
|
45
45
|
},
|
|
@@ -57,16 +57,16 @@
|
|
|
57
57
|
"main": "dist/index.js",
|
|
58
58
|
"types": "dist/index.d.ts",
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@fluidframework/container-definitions": "2.0.0-dev-rc.3.0.0.
|
|
61
|
-
"@fluidframework/container-loader": "2.0.0-dev-rc.3.0.0.
|
|
62
|
-
"@fluidframework/fluid-static": "2.0.0-dev-rc.3.0.0.
|
|
60
|
+
"@fluidframework/container-definitions": "2.0.0-dev-rc.3.0.0.254674",
|
|
61
|
+
"@fluidframework/container-loader": "2.0.0-dev-rc.3.0.0.254674",
|
|
62
|
+
"@fluidframework/fluid-static": "2.0.0-dev-rc.3.0.0.254674",
|
|
63
63
|
"@microsoft/applicationinsights-web": "^2.8.11",
|
|
64
64
|
"uuid": "^9.0.0"
|
|
65
65
|
},
|
|
66
66
|
"devDependencies": {
|
|
67
67
|
"@arethetypeswrong/cli": "^0.15.2",
|
|
68
|
-
"@fluid-internal/client-utils": "2.0.0-dev-rc.3.0.0.
|
|
69
|
-
"@fluid-internal/mocha-test-setup": "2.0.0-dev-rc.3.0.0.
|
|
68
|
+
"@fluid-internal/client-utils": "2.0.0-dev-rc.3.0.0.254674",
|
|
69
|
+
"@fluid-internal/mocha-test-setup": "2.0.0-dev-rc.3.0.0.254674",
|
|
70
70
|
"@fluid-tools/build-cli": "^0.35.0",
|
|
71
71
|
"@fluidframework/build-tools": "^0.35.0",
|
|
72
72
|
"@microsoft/api-extractor": "^7.42.3",
|
|
@@ -75,6 +75,7 @@
|
|
|
75
75
|
"@types/sinon": "^17.0.3",
|
|
76
76
|
"@types/uuid": "^9.0.2",
|
|
77
77
|
"chai": "^4.2.0",
|
|
78
|
+
"copyfiles": "^2.4.1",
|
|
78
79
|
"eslint": "~8.55.0",
|
|
79
80
|
"mocha": "^10.2.0",
|
|
80
81
|
"prettier": "~3.0.3",
|
|
@@ -85,14 +86,6 @@
|
|
|
85
86
|
},
|
|
86
87
|
"fluidBuild": {
|
|
87
88
|
"tasks": {
|
|
88
|
-
"build:docs": {
|
|
89
|
-
"dependsOn": [
|
|
90
|
-
"...",
|
|
91
|
-
"api-extractor:commonjs",
|
|
92
|
-
"api-extractor:esnext"
|
|
93
|
-
],
|
|
94
|
-
"script": false
|
|
95
|
-
},
|
|
96
89
|
"tsc": [
|
|
97
90
|
"...",
|
|
98
91
|
"typetests:gen"
|
|
@@ -105,12 +98,12 @@
|
|
|
105
98
|
},
|
|
106
99
|
"scripts": {
|
|
107
100
|
"api": "fluid-build . --task api",
|
|
108
|
-
"api-extractor:commonjs": "
|
|
109
|
-
"api-extractor:esnext": "
|
|
101
|
+
"api-extractor:commonjs": "flub generate entrypoints --outDir ./dist",
|
|
102
|
+
"api-extractor:esnext": "flub generate entrypoints --outDir ./lib",
|
|
110
103
|
"build": "fluid-build . --task build",
|
|
111
104
|
"build:commonjs": "fluid-build . --task commonjs",
|
|
112
105
|
"build:compile": "fluid-build . --task compile",
|
|
113
|
-
"build:docs": "
|
|
106
|
+
"build:docs": "api-extractor run --local",
|
|
114
107
|
"build:esnext": "tsc --project ./tsconfig.json",
|
|
115
108
|
"check:are-the-types-wrong": "attw --pack . --entrypoints .",
|
|
116
109
|
"check:release-tags": "api-extractor run --local --config ./api-extractor-lint.json",
|
package/api-extractor-cjs.json
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
-
"extends": "../../../../common/build/build-common/api-extractor-base.cjs.primary.json",
|
|
4
|
-
// CJS is actually secondary; so, no report.
|
|
5
|
-
"apiReport": {
|
|
6
|
-
"enabled": false
|
|
7
|
-
},
|
|
8
|
-
"messages": {
|
|
9
|
-
// The following overrides are workarounds for API-Extractor incorrectly running analysis on our application
|
|
10
|
-
// insights dependency.
|
|
11
|
-
"tsdocMessageReporting": {
|
|
12
|
-
"tsdoc-escape-right-brace": {
|
|
13
|
-
"logLevel": "none"
|
|
14
|
-
},
|
|
15
|
-
"tsdoc-malformed-inline-tag": {
|
|
16
|
-
"logLevel": "none"
|
|
17
|
-
},
|
|
18
|
-
"tsdoc-undefined-tag": {
|
|
19
|
-
"logLevel": "none"
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
"extractorMessageReporting": {
|
|
23
|
-
// Require documentation on all package-exported API items.
|
|
24
|
-
"ae-undocumented": {
|
|
25
|
-
"logLevel": "error",
|
|
26
|
-
"addToApiReportFile": false
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
@@ -1,229 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This package provides an implementation and types for producing and consuming telemetry for Fluid Framework applications
|
|
3
|
-
* @packageDocumentation
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
import { ApplicationInsights } from '@microsoft/applicationinsights-web';
|
|
7
|
-
import { ICriticalContainerError } from '@fluidframework/container-definitions';
|
|
8
|
-
import type { IFluidContainer } from '@fluidframework/fluid-static';
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* An implementation of {@link ITelemetryConsumer} that routes {@link IFluidTelemetry} to Azure App Insights
|
|
12
|
-
* in a format that is supported by Fluid Framework service offerings such as Cloud dashboards and alarms.
|
|
13
|
-
*
|
|
14
|
-
* @beta
|
|
15
|
-
*/
|
|
16
|
-
export declare class AppInsightsTelemetryConsumer implements ITelemetryConsumer {
|
|
17
|
-
private readonly appInsightsClient;
|
|
18
|
-
constructor(appInsightsClient: ApplicationInsights);
|
|
19
|
-
/**
|
|
20
|
-
* Takes the incoming {@link IFluidTelemetry} and sends it to Azure App Insights
|
|
21
|
-
*/
|
|
22
|
-
consume(event: IFluidTelemetry): void;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* The container "connected" telemetry event.
|
|
27
|
-
* It is produced from an internal Fluid container system event {@link @fluidframework/container-definitions#IContainerEvents} which is emitted when the {@link @fluidframework/container-definitions#IContainer} completes connecting to the Fluid service.
|
|
28
|
-
*
|
|
29
|
-
* @see More details about {@link @fluidframework/container-definitions#IContainer.connectionState | the containers connection state}
|
|
30
|
-
* @see More details about {@link @fluidframework/container-definitions#IContainer.connect | the function to connect a container }
|
|
31
|
-
* @see More details about {@link @fluidframework/container-definitions#IContainer.connectionState | the containers connection state}
|
|
32
|
-
*
|
|
33
|
-
* @beta
|
|
34
|
-
*/
|
|
35
|
-
export declare interface ContainerConnectedTelemetry extends IContainerTelemetry {
|
|
36
|
-
/**
|
|
37
|
-
* {@inheritDoc IFluidTelemetry.eventName}
|
|
38
|
-
*/
|
|
39
|
-
eventName: "fluidframework.container.connected";
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* The container "disconnected" telemetry event. This telemetry is produced from an internal Fluid container system event
|
|
44
|
-
* {@link @fluidframework/container-definitions#IContainerEvents} which is emitted when the {@link @fluidframework/container-definitions#IContainer}
|
|
45
|
-
* becomes disconnected from the Fluid service.
|
|
46
|
-
*
|
|
47
|
-
* @see More details about{@link @fluidframework/container-definitions#IContainer.connectionState | the containers connection state}
|
|
48
|
-
*
|
|
49
|
-
* @see More details about{@link @fluidframework/container-definitions#IContainer.disconnect | the function to disconnect a container}
|
|
50
|
-
*
|
|
51
|
-
* @beta
|
|
52
|
-
*/
|
|
53
|
-
export declare interface ContainerDisconnectedTelemetry extends IContainerTelemetry {
|
|
54
|
-
/**
|
|
55
|
-
* {@inheritDoc IFluidTelemetry.eventName}
|
|
56
|
-
*/
|
|
57
|
-
eventName: "fluidframework.container.disconnected";
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
*
|
|
62
|
-
* The Fluid container "disposed" telemetry event. This telemetry is produced from the "disposed" Fluid container system event
|
|
63
|
-
* which is emitted when the {@link @fluidframework/fluid-static#IFluidContainer} is closed, which permanently disables it.
|
|
64
|
-
*
|
|
65
|
-
* @see More details about{@link @fluidframework/container-definitions#IContainer.close | the container close event}
|
|
66
|
-
*
|
|
67
|
-
* @beta
|
|
68
|
-
*/
|
|
69
|
-
export declare interface ContainerDisposedTelemetry extends IContainerTelemetry {
|
|
70
|
-
/**
|
|
71
|
-
* {@inheritDoc IFluidTelemetry.eventName}
|
|
72
|
-
*/
|
|
73
|
-
eventName: "fluidframework.container.disposed";
|
|
74
|
-
/**
|
|
75
|
-
* If the container was closed due to error (as opposed to an explicit call to
|
|
76
|
-
* {@link @fluidframework/fluid-static#IFluidContainer."dispose"}), this will contain details about the error that caused it.
|
|
77
|
-
*/
|
|
78
|
-
error?: ICriticalContainerError;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
/**
|
|
82
|
-
* The aggregate type for all values within {@link ContainerTelemetryEventNames}
|
|
83
|
-
* @beta
|
|
84
|
-
*/
|
|
85
|
-
export declare type ContainerTelemetryEventName = (typeof ContainerTelemetryEventNames)[keyof typeof ContainerTelemetryEventNames];
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* This object contains names for Container Telemetry. Unlike the raw {@link @fluidframework/fluid-static#IFluidContainerEvents | IFluidContainer system event names} they contain more information such as the scope
|
|
89
|
-
*
|
|
90
|
-
* @beta
|
|
91
|
-
*/
|
|
92
|
-
export declare const ContainerTelemetryEventNames: {
|
|
93
|
-
/**
|
|
94
|
-
* Name for the container telemetry event that is intended to be produced from the IFluidContainer "connected" {@link @fluidframework/fluid-static#IFluidContainerEvents | system event}
|
|
95
|
-
*
|
|
96
|
-
* @see {@link ContainerConnectedTelemetry}
|
|
97
|
-
*/
|
|
98
|
-
readonly CONNECTED: "fluidframework.container.connected";
|
|
99
|
-
/**
|
|
100
|
-
* Name for the container telemetry event that is intended to be produced from the IFluidContainer "disconnected" {@link @fluidframework/fluid-static#IFluidContainerEvents | system event}
|
|
101
|
-
*
|
|
102
|
-
* @see {@link ContainerDisconnectedTelemetry}
|
|
103
|
-
*/
|
|
104
|
-
readonly DISCONNECTED: "fluidframework.container.disconnected";
|
|
105
|
-
/**
|
|
106
|
-
* Name for the container telemetry event that is intended to be produced from the IFluidContainer "disposed" {@link @fluidframework/fluid-static#IFluidContainerEvents | system event}
|
|
107
|
-
*
|
|
108
|
-
* @see {@link ContainerDisposedTelemetry}
|
|
109
|
-
*/
|
|
110
|
-
readonly DISPOSED: "fluidframework.container.disposed";
|
|
111
|
-
};
|
|
112
|
-
|
|
113
|
-
/**
|
|
114
|
-
* Aggregate type for all the different types of Fluid telemetry event names.
|
|
115
|
-
*
|
|
116
|
-
* @privateremarks This only looks odd right now because {@link ContainerTelemetryEventName} is the only aggregation at the moment.
|
|
117
|
-
*
|
|
118
|
-
* @beta
|
|
119
|
-
*/
|
|
120
|
-
export declare type FluidTelemetryEventName = ContainerTelemetryEventName;
|
|
121
|
-
|
|
122
|
-
/**
|
|
123
|
-
* The base interface for all Container telemetry
|
|
124
|
-
* @beta
|
|
125
|
-
*/
|
|
126
|
-
export declare interface IContainerTelemetry extends IFluidTelemetry {
|
|
127
|
-
/**
|
|
128
|
-
* {@inheritdoc IFluidTelemetry.eventName}
|
|
129
|
-
*/
|
|
130
|
-
eventName: ContainerTelemetryEventName;
|
|
131
|
-
/**
|
|
132
|
-
* Unique identifier for a container, stable across creation and load.
|
|
133
|
-
* I.e. different clients loading the same container (or the same client loading the container two separate times)
|
|
134
|
-
* will agree on this value.
|
|
135
|
-
*
|
|
136
|
-
* @remarks This can be undefined for a container that has not been attached.
|
|
137
|
-
*/
|
|
138
|
-
containerId?: string;
|
|
139
|
-
/**
|
|
140
|
-
* Unique identifier for the container instance that generated the telemetry.
|
|
141
|
-
* This is not a stable identifier for the container across clients/time.
|
|
142
|
-
* Every load of the container will result in a different value.
|
|
143
|
-
*
|
|
144
|
-
*/
|
|
145
|
-
containerInstanceId: string;
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
export { ICriticalContainerError }
|
|
149
|
-
|
|
150
|
-
/**
|
|
151
|
-
* The base interface extended by all Fluid telemetry
|
|
152
|
-
*
|
|
153
|
-
* @see {@link @fluidframework/fluid-telemetry#IContainerTelemetry} for an extension of this interface for all container related telemetry.
|
|
154
|
-
*
|
|
155
|
-
* @beta
|
|
156
|
-
*/
|
|
157
|
-
export declare interface IFluidTelemetry {
|
|
158
|
-
/**
|
|
159
|
-
* The unique name of the telemetry event. The event name contains scope concatenated together
|
|
160
|
-
* with periods to enable more granular log searching
|
|
161
|
-
*
|
|
162
|
-
* @example
|
|
163
|
-
* "fluidframework.container.connected"
|
|
164
|
-
*/
|
|
165
|
-
eventName: FluidTelemetryEventName;
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
/**
|
|
169
|
-
* Base interface for all telemetry consumers.
|
|
170
|
-
* Conusmers are intended to take incoming produced {@link IFluidTelemetry} and do something of your choice with it.
|
|
171
|
-
* This could be sending the telemetry to a cloud platform or just console logging.
|
|
172
|
-
*
|
|
173
|
-
* @example
|
|
174
|
-
* Here is an example of how we construct a consumer to send telemetry to Azure App Insights, a cloud logging platform:
|
|
175
|
-
* ```ts
|
|
176
|
-
* class AppInsightsTelemetryConsumer implements ITelemetryConsumer {
|
|
177
|
-
* constructor(private readonly appInsightsClient: ApplicationInsights) {}
|
|
178
|
-
*
|
|
179
|
-
* consume(event: IFluidTelemetry) {
|
|
180
|
-
* this.appInsightsClient.trackEvent({
|
|
181
|
-
* name: event.eventName,
|
|
182
|
-
* properties: event,
|
|
183
|
-
* });
|
|
184
|
-
* }
|
|
185
|
-
* }
|
|
186
|
-
*```
|
|
187
|
-
*
|
|
188
|
-
* @beta
|
|
189
|
-
*/
|
|
190
|
-
export declare interface ITelemetryConsumer {
|
|
191
|
-
/**
|
|
192
|
-
* This method is intended to take created {@link IFluidTelemetry} and do something with it.
|
|
193
|
-
* This could be sending the telemetry to a cloud platform, just console logging or something else of your choice.
|
|
194
|
-
*/
|
|
195
|
-
consume(event: IFluidTelemetry): any;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
/**
|
|
199
|
-
* Starts creating {@link @fluidframework/fluid-telemetry#IFluidTelemetry} by transforming raw system events emitted by the specified container
|
|
200
|
-
* into said telemetry and passing it onto to the specified {@link ITelemetryConsumer}
|
|
201
|
-
*
|
|
202
|
-
* @beta
|
|
203
|
-
*/
|
|
204
|
-
export declare const startTelemetry: (config: TelemetryConfig) => void;
|
|
205
|
-
|
|
206
|
-
/**
|
|
207
|
-
* Configuration object for subscribing to {@link @fluidframework/fluid-telemetry#IFluidTelemetry} and consuming said telemetry via one or more {@link ITelemetryConsumer}
|
|
208
|
-
*
|
|
209
|
-
* @beta
|
|
210
|
-
*/
|
|
211
|
-
export declare interface TelemetryConfig {
|
|
212
|
-
/**
|
|
213
|
-
* The container whose events should be monitored, transformed into Fluid telemetry, and sent to a {@link ITelemetryConsumer}.
|
|
214
|
-
*/
|
|
215
|
-
container: IFluidContainer;
|
|
216
|
-
/**
|
|
217
|
-
* Unique identifier for the passed in container, i.e. the return value of a call
|
|
218
|
-
* to {@link @fluidframework/fluid-static#IFluidContainer.attach | `IFluidContainer.attach()`} when creating a new
|
|
219
|
-
* Fluid container, or the id used to load a pre-existing one.
|
|
220
|
-
*/
|
|
221
|
-
containerId: string;
|
|
222
|
-
/**
|
|
223
|
-
* Conusmers take incoming produced {@link @fluidframework/fluid-telemetry#IFluidTelemetry} and do something of your choice with it.
|
|
224
|
-
* This could be sending the telemetry to a cloud platform or just console logging.
|
|
225
|
-
*/
|
|
226
|
-
consumers: ITelemetryConsumer[];
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
export { }
|