@fluidframework/fluid-telemetry 2.0.0-dev-rc.3.0.0.254674 → 2.0.0-rc.3.0.0
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/CHANGELOG.md +32 -0
- package/README.md +216 -13
- package/beta.d.ts +11 -0
- package/dist/beta.d.ts +1 -0
- package/dist/{alpha.d.ts → legacy.d.ts} +1 -0
- package/dist/public.d.ts +1 -0
- package/internal.d.ts +11 -0
- package/legacy.d.ts +11 -0
- package/lib/beta.d.ts +1 -0
- package/lib/{alpha.d.ts → legacy.d.ts} +1 -0
- package/lib/public.d.ts +1 -0
- package/package.json +19 -19
- package/readme_images/telemetry_1.png +0 -0
- package/readme_images/telemetry_2.png +0 -0
- package/readme_images/telemetry_3.png +0 -0
- package/readme_images/telemetry_4.png +0 -0
- package/readme_images/telemetry_5.png +0 -0
- package/readme_images/telemetry_6.png +0 -0
- package/readme_images/telemetry_time_period.png +0 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# @fluidframework/fluid-telemetry
|
|
2
|
+
|
|
3
|
+
## 2.0.0-rc.3.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- New package: @fluidframework/fluid-telemetry [97d68aa06b](https://github.com/microsoft/FluidFramework/commit/97d68aa06bd5c022ecb026655814aea222a062ae)
|
|
8
|
+
|
|
9
|
+
Before deploying your application at scale, it is critical to have the holistic telemetry in place to monitor its usage
|
|
10
|
+
and look for issues and optimizations. To make this easier, we are providing a fluid-telemetry package that comes with
|
|
11
|
+
Typed telemetry events that you can funnel to your any analytics tool of your choice. If you decide to use Azure App
|
|
12
|
+
Insights to view this data, we also provide helper packages and dashboard queries to get you started quickly. You can
|
|
13
|
+
learn more at <https://aka.ms/fluid/telemetry>.
|
|
14
|
+
|
|
15
|
+
- Packages now use package.json "exports" and require modern module resolution [97d68aa06b](https://github.com/microsoft/FluidFramework/commit/97d68aa06bd5c022ecb026655814aea222a062ae)
|
|
16
|
+
|
|
17
|
+
Fluid Framework packages have been updated to use the [package.json "exports"
|
|
18
|
+
field](https://nodejs.org/docs/latest-v18.x/api/packages.html#exports) to define explicit entry points for both
|
|
19
|
+
TypeScript types and implementation code.
|
|
20
|
+
|
|
21
|
+
This means that using Fluid Framework packages require the following TypeScript settings in tsconfig.json:
|
|
22
|
+
|
|
23
|
+
- `"moduleResolution": "Node16"` with `"module": "Node16"`
|
|
24
|
+
- `"moduleResolution": "Bundler"` with `"module": "ESNext"`
|
|
25
|
+
|
|
26
|
+
We recommend using Node16/Node16 unless absolutely necessary. That will produce transpiled JavaScript that is suitable
|
|
27
|
+
for use with modern versions of Node.js _and_ Bundlers.
|
|
28
|
+
[See the TypeScript documentation](https://www.typescriptlang.org/tsconfig#moduleResolution) for more information
|
|
29
|
+
regarding the module and moduleResolution options.
|
|
30
|
+
|
|
31
|
+
**Node10 moduleResolution is not supported; it does not support Fluid Framework's API structuring pattern that is used
|
|
32
|
+
to distinguish stable APIs from those that are in development.**
|
package/README.md
CHANGED
|
@@ -2,21 +2,29 @@
|
|
|
2
2
|
|
|
3
3
|
This package contains code enabling the production and consumption of typed telemetry for Fluid Framework applications. The typed telemetry from this package is used as the backbone for different Fluid Framework cloud offerings such as dashboards and alarms for Fluid applications. This package can also be used as a reference for customizing and creating your own telemetry solution if desired.
|
|
4
4
|
|
|
5
|
-
At this time, the package enables collection of Fluid Container
|
|
5
|
+
At this time, the package enables collection of telemetry related to the Fluid Container only. In the future, more areas would be added as needs evolve.
|
|
6
6
|
|
|
7
7
|
# Getting Started
|
|
8
8
|
|
|
9
|
-
Let's walk through some
|
|
9
|
+
Let's walk through some examples for getting started with Fluid telemetry for containers using the `@fluidframework/fluid-telemetry` package.
|
|
10
10
|
|
|
11
|
-
##
|
|
11
|
+
## Use Case 1: Logging container telemetry to Azure App Insights and analyzing app data
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
### Prerequisite
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
Before you can get telemetry sent to Azure App Insights, you'll need to create an Instance of App Insights on Azure. You'll then be able to integrate your Azure App Insights instance with your Fluid application and route your Fluid container application telemetry to App Insights. [Learn more about Azure App Insights](https://learn.microsoft.com/en-us/azure/azure-monitor/app/app-insights-overview). [Creating your App Insights instance](https://learn.microsoft.com/en-us/azure/azure-monitor/app/create-workspace-resource?tabs=bicep).
|
|
16
|
+
|
|
17
|
+
Once you setup your App Insights instance, you can proceed with next steps below to route the telemetry to App Insights.
|
|
18
|
+
|
|
19
|
+
### Step 1: Install new package dependencies
|
|
20
|
+
|
|
21
|
+
Install the Fluid Framework telemetry package and Azure App Insights package dependencies
|
|
16
22
|
|
|
17
23
|
- Using NPM: `npm install @fluidframework/fluid-telemetry @microsoft/applicationinsights-web`
|
|
18
24
|
|
|
19
|
-
|
|
25
|
+
### Step 2: Setup telemetry collection
|
|
26
|
+
|
|
27
|
+
Now, let's start the telemetry production by initializing our telemetry collection where we initialize our containers:
|
|
20
28
|
|
|
21
29
|
```ts
|
|
22
30
|
import { ApplicationInsights } from "@microsoft/applicationinsights-web";
|
|
@@ -39,7 +47,10 @@ if (containerExists) {
|
|
|
39
47
|
const appInsightsClient = new ApplicationInsights({
|
|
40
48
|
config: {
|
|
41
49
|
connectionString:
|
|
42
|
-
|
|
50
|
+
/////////////// Important ///////////////
|
|
51
|
+
// Edit this with your app insights instance connection string which
|
|
52
|
+
// can be found on the Azure Portal where you created the
|
|
53
|
+
// App Insights instance (below is an example string)
|
|
43
54
|
"InstrumentationKey=abcdefgh-ijkl-mnop-qrst-uvwxyz6ffd9c;IngestionEndpoint=https://westus2-2.in.applicationinsights.azure.com/;LiveEndpoint=https://westus2.livediagnostics.monitor.azure.com/",
|
|
44
55
|
},
|
|
45
56
|
});
|
|
@@ -62,17 +73,25 @@ startTelemetry(telemetryConfig);
|
|
|
62
73
|
// Done! Your container telemetry is now being created and sent to your Telemetry Consumer which will forward it to Azure App Insights.
|
|
63
74
|
```
|
|
64
75
|
|
|
65
|
-
|
|
76
|
+
That's it for now! If you've decided to use Azure App Insights, we have designed useful prebuilt queries that utilize the generated telemetry. You can try out these queries after running your application with above code for a little duration.
|
|
66
77
|
|
|
67
|
-
|
|
78
|
+
You can find these queries [in the "Interpreting Telemetry Data" section below.](#telemetry_visualization)
|
|
68
79
|
|
|
69
|
-
|
|
80
|
+
## Use Case 2: Setup a custom telemetry consumer
|
|
70
81
|
|
|
71
|
-
|
|
82
|
+
To use a custom telemetry consumer and integrate with a cloud provider or custom dashboard solution, you need to implement the `ITelemetryConsumer` interface.
|
|
83
|
+
|
|
84
|
+
In this example, you'll walk through the basic setup process to start getting container telemetry to be produced and log it to the console.
|
|
85
|
+
|
|
86
|
+
### Step 1: Install new package dependencies
|
|
87
|
+
|
|
88
|
+
Install the Fluid Framework telemetry package dependency
|
|
72
89
|
|
|
73
90
|
- Using NPM: `npm install @fluidframework/fluid-telemetry`
|
|
74
91
|
|
|
75
|
-
### Step 2:
|
|
92
|
+
### Step 2: Define a custom telemetry consumer
|
|
93
|
+
|
|
94
|
+
Here we'll create our own telemetry consumer which extends the `ITelemetryConsumer` interface. Let's look at an example that will simply log the telemetry to console.
|
|
76
95
|
|
|
77
96
|
```ts
|
|
78
97
|
import { ITelemetryConsumer, IFluidTelemetry } from "@fluidframework/fluid-telemetry";
|
|
@@ -84,7 +103,9 @@ class MySimpleTelemetryConsumer implements ITelemetryConsumer {
|
|
|
84
103
|
}
|
|
85
104
|
```
|
|
86
105
|
|
|
87
|
-
### Step 3:
|
|
106
|
+
### Step 3: Setup telemetry collection
|
|
107
|
+
|
|
108
|
+
Now, let's start the telemetry production and loop in our telemetry consumer from step 2. We will be initializing our telemetry collection where we initialize our containers:
|
|
88
109
|
|
|
89
110
|
```ts
|
|
90
111
|
import { IFluidContainer } from "@fluidframework/fluid-static";
|
|
@@ -116,3 +137,185 @@ startTelemetry(telemetryConfig);
|
|
|
116
137
|
|
|
117
138
|
// Done! Your container telemetry is now being created and sent to your Telemetry Consumer
|
|
118
139
|
```
|
|
140
|
+
|
|
141
|
+
You can now run the app and see the telemetry being printed on your console.
|
|
142
|
+
|
|
143
|
+
## <a name="telemetry_visualization">Interpreting telemetry data</a>
|
|
144
|
+
|
|
145
|
+
This section provides a set of Azure App Insights queries related to collaborative sessions within a Fluid Framework application. It is intended to be used with the telemetry generated from @fluidframework/fluid-telemetry package whose integration steps are outline above.
|
|
146
|
+
|
|
147
|
+
### Understanding container telemetry
|
|
148
|
+
|
|
149
|
+
Before we dive into the queries, we will walk through what a “session” or “collaborative session” is in the context of the following queries. Currently, the concept of a "session” or “collaborative session” does not actually exist within telemetry itself. At a high level, we identify a session by finding a set of container telemetry being emitted with the same container ID within a specific time frame.
|
|
150
|
+
|
|
151
|
+
Going into more detail, A “Session” or “Collaborative Session” is defined as a period in which we see a continuous stream of container telemetry being emitted with a unique container Id. For a given set of telemetry with the same container Id, if this stream of telemetry stops for longer than a specified period of time then we consider that the end of the session. Each session is differentiated from each other because it has no telemetry (no user activity) emitted for a defined amount of time prior to the start and after the end of emitted telemetry. For each of these queries you can also adjust the time gap that defines a session based on your preference.
|
|
152
|
+
|
|
153
|
+
> Note: All telemetry being visualized below is generated from clients without any intervention from the server. The accuracy might be impacted due to inherent nature of client telemetry and data being lost due to faulty clients or lack of connectivity before the telemetry is fully pushed out. We recommend not using this telemetry for business metrics, but rather use it for operational metrics and diagnosis of issues.
|
|
154
|
+
|
|
155
|
+
### Accessing App Insights Portal
|
|
156
|
+
|
|
157
|
+
Before we can query, we must first navigate to your Azure App Insights telemetry page. To do this, go to your Azure App Insights Instance and click on the “Logs” tab under Monitoring.
|
|
158
|
+
|
|
159
|
+

|
|
160
|
+
|
|
161
|
+
Now, close out the “Queries” pane if it showed up for you and you will be in the view where we can execute our queries. Note that if you are using the Fluid Azure App Insights logger, your telemetry data will be available in the “customEvents” table.
|
|
162
|
+
|
|
163
|
+
### Queries and results
|
|
164
|
+
|
|
165
|
+
1. Session information
|
|
166
|
+
|
|
167
|
+
The following query provides a table of data that can give you a quick overview of information about sessions for your application. It includes the Id of the container being interacted with, the number of containers and the length of each session. Note that query provides session id’s but these values do not actually exist in the telemetry, it is a concept we have derived from the data; see the intro paragraph for more information on sessions.
|
|
168
|
+
|
|
169
|
+
```sql
|
|
170
|
+
let sessionGap = 5m;
|
|
171
|
+
let sessionGapSeconds = toint(sessionGap / 1s);
|
|
172
|
+
customEvents
|
|
173
|
+
| extend containerId = tostring(customDimensions.containerId), containerInstanceId = tostring(customDimensions.containerInstanceId )
|
|
174
|
+
| where name startswith "fluidframework.container"
|
|
175
|
+
| extend containerIdTimestamp = strcat(containerId, timestamp)
|
|
176
|
+
| sort by containerIdTimestamp asc
|
|
177
|
+
| extend prevTimestamp = prev(timestamp), prevContainerId = prev(containerId)
|
|
178
|
+
| extend Diff = datetime_diff("second", timestamp, prevTimestamp)
|
|
179
|
+
| extend IsNewPeriod = iif(prevContainerId != containerId or Diff > (sessionGapSeconds) or isnull(Diff), 1, 0)
|
|
180
|
+
| extend SessionId = row_cumsum(IsNewPeriod)
|
|
181
|
+
| summarize NumCollaborators = dcount(containerInstanceId), StartTime = min(timestamp), EndTime = max(timestamp) by SessionId, containerId
|
|
182
|
+
| extend PeriodDurationInMinutes = datetime_diff("minute", EndTime, StartTime)
|
|
183
|
+
| project SessionId, containerId , NumCollaborators, PeriodDurationInMinutes, StartTime, EndTime
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+

|
|
187
|
+
|
|
188
|
+
2. Total number of sessions over time period
|
|
189
|
+
|
|
190
|
+
The following query provides the average number of total sessions occurring over 10-minute intervals. The query logic graphs the total number of sessions occurring over 10-minute data points denoted by the variable named summedDataPointInterval.
|
|
191
|
+
|
|
192
|
+
This variable can be adjusted to your liking, for example, replace `let summedDataPointInterval = 10m;` with `let summedDataPointInterval = 1hr;` for 1hr data points.
|
|
193
|
+
|
|
194
|
+
```sql
|
|
195
|
+
let summedDataPointInterval = 10m;
|
|
196
|
+
let averagedTimeInterval = 1hr;
|
|
197
|
+
let sessionGap = 5m;
|
|
198
|
+
let sessionGapSeconds = toint(sessionGap / 1s);
|
|
199
|
+
let minTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize min(timestamp));
|
|
200
|
+
let maxTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize max(timestamp));
|
|
201
|
+
customEvents
|
|
202
|
+
| extend containerId = tostring(customDimensions.containerId)
|
|
203
|
+
| where name startswith "fluidframework.container"
|
|
204
|
+
| extend docIdTimestamp = strcat(containerId, timestamp)
|
|
205
|
+
| sort by docIdTimestamp asc
|
|
206
|
+
| extend prevTimestamp = prev(timestamp), prevContainerId = prev(containerId)
|
|
207
|
+
| extend Diff = datetime_diff("second", timestamp, prevTimestamp)
|
|
208
|
+
| extend IsNewPeriod = iif(prevContainerId != containerId or Diff > (sessionGapSeconds) or isnull(Diff), 1, 0)
|
|
209
|
+
| extend SessionId = row_cumsum(IsNewPeriod)
|
|
210
|
+
| summarize by SessionId, containerId, bin(timestamp, summedDataPointInterval)
|
|
211
|
+
| make-series sumSessions = dcount(SessionId) on timestamp from minTimestamp to maxTimestamp step averagedTimeInterval
|
|
212
|
+
| render timechart with (title = "Total Number of Sessions Occurring Over 1 Hour Intervals")
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+

|
|
216
|
+
|
|
217
|
+
3. Average number of sessions over time period
|
|
218
|
+
|
|
219
|
+
The following query provides the average number of sessions occurring over 1-hour intervals. The query logic first sums up the total number of sessions occurring over 10-minute data points denoted by the variable named `summedDataPointInterval`. It then averages these data points over 1-hour intervals denoted by the `averagedTimeInterval` variable.
|
|
220
|
+
|
|
221
|
+
Both variables can be adjusted to your preference, For example, replace `let summedDataPointInterval = 10m;` with `let summedDataPointInterval = 1hr;` for 1-hour data points and replace `let averagedTimeInterval = 1hr;` with `let averagedTimeInterval = 1d`; for 1 hour data points averaged over 1 day time intervals.
|
|
222
|
+
|
|
223
|
+
```sql
|
|
224
|
+
let summedDataPointInterval = 5m;
|
|
225
|
+
let averagedTimeInterval = 20m;
|
|
226
|
+
let sessionGap = 5m;
|
|
227
|
+
let sessionGapSeconds = toint(sessionGap / 1s);
|
|
228
|
+
let minTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize min(timestamp));
|
|
229
|
+
let maxTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize max(timestamp));
|
|
230
|
+
customEvents
|
|
231
|
+
| extend containerId = tostring(customDimensions.containerId)
|
|
232
|
+
| where name startswith "fluidframework.container"
|
|
233
|
+
| extend containerIdTimestamp = strcat(containerId, timestamp)
|
|
234
|
+
| sort by containerIdTimestamp asc
|
|
235
|
+
| extend prevTimestamp = prev(timestamp), prevContainerId = prev(containerId)
|
|
236
|
+
| extend Diff = datetime_diff("second", timestamp, prevTimestamp)
|
|
237
|
+
| extend IsNewPeriod = iif(prevContainerId != containerId or Diff > (sessionGapSeconds) or isnull(Diff), 1, 0)
|
|
238
|
+
| extend SessionId = row_cumsum(IsNewPeriod)
|
|
239
|
+
| summarize sumSessions = dcount(SessionId) by bin(timestamp, summedDataPointInterval)
|
|
240
|
+
| make-series avgSessions = avg(sumSessions) on timestamp from minTimestamp to maxTimestamp step averagedTimeInterval
|
|
241
|
+
| render timechart with (title = "Average Number of Sessions Occurring Over 1 Hour Intervals")
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+

|
|
245
|
+
|
|
246
|
+
4. Average number of containers per session over a time period
|
|
247
|
+
|
|
248
|
+
The following query will provide you with the approximate average number of containers per session over 1 hour time intervals. The query logic first sums up the total number of containers per sessions occurring over 10-minute data points denoted by the variable named `summedDataPointInterval`. It then averages these datapoints over 1-hour intervals denoted by the `averagedTimeInterval` variable.
|
|
249
|
+
|
|
250
|
+
Both variables can be adjusted to your preference, For example, replace `let summedDataPointInterval = 10m;` with `let summedDataPointInterval = 1hr;` for 1-hour data points and replace `let averagedTimeInterval = 1hr;` with `let averagedTimeInterval = 1d;` for 1 hour data points averaged over 1 day time intervals.
|
|
251
|
+
|
|
252
|
+
```sql
|
|
253
|
+
let summedDataPointInterval = 10m;
|
|
254
|
+
let averagedTimeInterval = 1hr;
|
|
255
|
+
let sessionGap = 5m;
|
|
256
|
+
let sessionGapSeconds = toint(sessionGap / 1s);
|
|
257
|
+
let minTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize min(timestamp));
|
|
258
|
+
let maxTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize max(timestamp));
|
|
259
|
+
customEvents
|
|
260
|
+
| extend containerId = tostring(customDimensions.containerId), containerInstanceId = tostring(customDimensions.containerInstanceId)
|
|
261
|
+
| where name startswith "fluidframework.container"
|
|
262
|
+
| extend docIdTimestamp = strcat(containerId, timestamp)
|
|
263
|
+
| sort by docIdTimestamp asc
|
|
264
|
+
| extend prevTimestamp = prev(timestamp), prevContainerId = prev(containerId)
|
|
265
|
+
| extend Diff = datetime_diff("second", timestamp, prevTimestamp)
|
|
266
|
+
| extend IsNewPeriod = iif(prevContainerId != containerId or Diff > (sessionGapSeconds) or isnull(Diff), 1, 0)
|
|
267
|
+
| extend SessionId = row_cumsum(IsNewPeriod)
|
|
268
|
+
| summarize sumCollaborators = dcount(containerInstanceId) by SessionId, containerId, bin(timestamp, summedDataPointInterval)
|
|
269
|
+
| make-series avgCollaborators = avg(sumCollaborators) on timestamp from minTimestamp to maxTimestamp step averagedTimeInterval
|
|
270
|
+
| render timechart with (title = "Approximate Average Number Of Container Per Session Over 1 Hour Intervals")
|
|
271
|
+
```
|
|
272
|
+
|
|
273
|
+

|
|
274
|
+
|
|
275
|
+
5. Length of Individual Sessions in Minutes
|
|
276
|
+
|
|
277
|
+
This query provides you with the length of time of individual sessions, graphed by putting them into time bins increasing in 2.5 minute increments. The query logic calculates the length of time of each session that occurs and then sorts them into time bins going up in 2.5 minute increments denoted by the `let sessionLengthMinuteBins = 2.5;` variable. To adjust the 2.5 minute time bins, simply modify the `sessionLengthMinuteBins` variable. Note that this number represents minutes.
|
|
278
|
+
|
|
279
|
+
```sql
|
|
280
|
+
let sessionLengthMinuteBins = 2.5;
|
|
281
|
+
let sessionGap = 5m;
|
|
282
|
+
let sessionGapSeconds = toint(sessionGap / 1s);
|
|
283
|
+
let minTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize min(timestamp));
|
|
284
|
+
let maxTimestamp = toscalar(customEvents | where name startswith "fluidframework.container" | summarize max(timestamp));
|
|
285
|
+
customEvents
|
|
286
|
+
| extend containerId = tostring(customDimensions.containerId)
|
|
287
|
+
| where name startswith "fluidframework.container"
|
|
288
|
+
| extend docIdTimestamp = strcat(containerId, timestamp)
|
|
289
|
+
| sort by docIdTimestamp asc
|
|
290
|
+
| extend prevTimestamp = prev(timestamp), prevContainerId = prev(containerId)
|
|
291
|
+
| extend Diff = datetime_diff("second", timestamp, prevTimestamp)
|
|
292
|
+
| extend IsNewPeriod = iif(prevContainerId != containerId or Diff > (sessionGapSeconds) or isnull(Diff), 1, 0)
|
|
293
|
+
| extend SessionId = row_cumsum(IsNewPeriod)
|
|
294
|
+
| summarize StartTime = min(timestamp), EndTime = max(timestamp) by SessionId, containerId
|
|
295
|
+
| extend SessionDurationInMinutes = datetime_diff("minute", EndTime, StartTime)
|
|
296
|
+
| make-series numSessions = dcount(SessionId) default=0 on sessionLengthBin = bin(SessionDurationInMinutes, sessionLengthMinuteBins) step sessionLengthMinuteBins
|
|
297
|
+
| mvexpand sessionLengthBin, numSessions
|
|
298
|
+
| extend numSessionsLong = tolong(numSessions), sessionLengthBinDouble = todouble(sessionLengthBin)
|
|
299
|
+
| project LengthOfSession = sessionLengthBinDouble, NumberOfSessions = numSessionsLong
|
|
300
|
+
| sort by LengthOfSession asc
|
|
301
|
+
| render columnchart with (title = "Length Of Sessions Separated Into 2.5 Minute Time Bins")
|
|
302
|
+
|
|
303
|
+
```
|
|
304
|
+
|
|
305
|
+

|
|
306
|
+
|
|
307
|
+
#### General Query Adjustments
|
|
308
|
+
|
|
309
|
+
1. Adjusting the date span of the query
|
|
310
|
+
|
|
311
|
+
To adjust the time span of this query, simply use the Time Range dropdown provided by azure. You do not need to modify the query directly. By default, these queries will query against all logs you have available.
|
|
312
|
+
|
|
313
|
+

|
|
314
|
+
|
|
315
|
+
2. Adjusting the gap of time that defines a session
|
|
316
|
+
|
|
317
|
+
By default, we identify each session has a period of 5 minutes of inactivity before and after. However, you may want to adjust this time period. To do so, modify the value of the variable named `sessionGap` to be your desired time length.
|
|
318
|
+
|
|
319
|
+
3. Adjusting the title of your graphs
|
|
320
|
+
|
|
321
|
+
For all queries, you can modify the title of your graph using the last line of the query, for example, replace `render columnchart with (title = "Approximate Length Of Sessions Separated Into 2.5 Minute Time Bins")` query, `with render columnchart with (title = "Approximate Length Of Sessions Separated Into 10 Minute Time Bins")`
|
package/beta.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
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
|
+
|
|
11
|
+
export * from "./lib/beta.js";
|
package/dist/beta.d.ts
CHANGED
package/dist/public.d.ts
CHANGED
package/internal.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
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
|
+
|
|
11
|
+
export * from "./lib/index.js";
|
package/legacy.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
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
|
+
|
|
11
|
+
export * from "./lib/legacy.js";
|
package/lib/beta.d.ts
CHANGED
package/lib/public.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/fluid-telemetry",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-rc.3.0.0",
|
|
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": {
|
|
@@ -15,21 +15,21 @@
|
|
|
15
15
|
"exports": {
|
|
16
16
|
".": {
|
|
17
17
|
"import": {
|
|
18
|
-
"types": "./lib/
|
|
18
|
+
"types": "./lib/public.d.ts",
|
|
19
19
|
"default": "./lib/index.js"
|
|
20
20
|
},
|
|
21
21
|
"require": {
|
|
22
|
-
"types": "./dist/
|
|
22
|
+
"types": "./dist/public.d.ts",
|
|
23
23
|
"default": "./dist/index.js"
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
|
-
"./
|
|
26
|
+
"./legacy": {
|
|
27
27
|
"import": {
|
|
28
|
-
"types": "./lib/
|
|
28
|
+
"types": "./lib/legacy.d.ts",
|
|
29
29
|
"default": "./lib/index.js"
|
|
30
30
|
},
|
|
31
31
|
"require": {
|
|
32
|
-
"types": "./dist/
|
|
32
|
+
"types": "./dist/legacy.d.ts",
|
|
33
33
|
"default": "./dist/index.js"
|
|
34
34
|
}
|
|
35
35
|
},
|
|
@@ -54,21 +54,21 @@
|
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
},
|
|
57
|
-
"main": "
|
|
58
|
-
"types": "
|
|
57
|
+
"main": "lib/index.js",
|
|
58
|
+
"types": "lib/index.d.ts",
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@fluidframework/container-definitions": "2.0.0-
|
|
61
|
-
"@fluidframework/container-loader": "2.0.0-
|
|
62
|
-
"@fluidframework/fluid-static": "2.0.0-
|
|
60
|
+
"@fluidframework/container-definitions": ">=2.0.0-rc.3.0.0 <2.0.0-rc.3.1.0",
|
|
61
|
+
"@fluidframework/container-loader": ">=2.0.0-rc.3.0.0 <2.0.0-rc.3.1.0",
|
|
62
|
+
"@fluidframework/fluid-static": ">=2.0.0-rc.3.0.0 <2.0.0-rc.3.1.0",
|
|
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-
|
|
69
|
-
"@fluid-internal/mocha-test-setup": "2.0.0-
|
|
70
|
-
"@fluid-tools/build-cli": "^0.
|
|
71
|
-
"@fluidframework/build-tools": "^0.
|
|
68
|
+
"@fluid-internal/client-utils": ">=2.0.0-rc.3.0.0 <2.0.0-rc.3.1.0",
|
|
69
|
+
"@fluid-internal/mocha-test-setup": ">=2.0.0-rc.3.0.0 <2.0.0-rc.3.1.0",
|
|
70
|
+
"@fluid-tools/build-cli": "^0.37.0",
|
|
71
|
+
"@fluidframework/build-tools": "^0.37.0",
|
|
72
72
|
"@microsoft/api-extractor": "^7.42.3",
|
|
73
73
|
"@types/chai": "^4.0.0",
|
|
74
74
|
"@types/mocha": "^9.1.1",
|
|
@@ -98,17 +98,17 @@
|
|
|
98
98
|
},
|
|
99
99
|
"scripts": {
|
|
100
100
|
"api": "fluid-build . --task api",
|
|
101
|
-
"api-extractor:commonjs": "flub generate entrypoints --outDir ./dist",
|
|
102
|
-
"api-extractor:esnext": "flub generate entrypoints --outDir ./lib",
|
|
101
|
+
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
|
|
102
|
+
"api-extractor:esnext": "flub generate entrypoints --outFileAlpha legacy --outDir ./lib --node10TypeCompat",
|
|
103
103
|
"build": "fluid-build . --task build",
|
|
104
104
|
"build:commonjs": "fluid-build . --task commonjs",
|
|
105
105
|
"build:compile": "fluid-build . --task compile",
|
|
106
106
|
"build:docs": "api-extractor run --local",
|
|
107
107
|
"build:esnext": "tsc --project ./tsconfig.json",
|
|
108
|
-
"check:are-the-types-wrong": "attw --pack .
|
|
108
|
+
"check:are-the-types-wrong": "attw --pack .",
|
|
109
109
|
"check:release-tags": "api-extractor run --local --config ./api-extractor-lint.json",
|
|
110
110
|
"ci:build:docs": "api-extractor run",
|
|
111
|
-
"clean": "rimraf --glob _api-extractor-temp coverage dist lib nyc \"**/*.tsbuildinfo\" \"**/*.build.log\"",
|
|
111
|
+
"clean": "rimraf --glob _api-extractor-temp coverage dist lib \"*.d.ts\" nyc \"**/*.tsbuildinfo\" \"**/*.build.log\"",
|
|
112
112
|
"eslint": "eslint --format stylish src",
|
|
113
113
|
"eslint:fix": "eslint --format stylish src --fix --fix-type problem,suggestion,layout",
|
|
114
114
|
"format": "fluid-build --task format .",
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|