Skip to content

Commit 1b36370

Browse files
Nancy LiDevtools-frontend LUCI CQ
authored andcommitted
[RPP Insight] Rename the LongCriticalTree insight to NetworkDependencyTree
For more information see here: https://docs.google.com/document/d/1zKpNkjJQbCuuPSXiZKwQu5qMscSDqXqjFHSiAHgDFug/edit?disco=AAABb9FRpzg Bug: 372897712 Change-Id: Ia75da0808c128ffa7ffdf174de317538f1230c51 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6271743 Commit-Queue: Nancy Li <[email protected]> Reviewed-by: Jack Franklin <[email protected]>
1 parent 2801cc6 commit 1b36370

File tree

14 files changed

+39
-39
lines changed

14 files changed

+39
-39
lines changed

config/gni/devtools_grd_files.gni

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1148,8 +1148,8 @@ grd_files_debug_sources = [
11481148
"front_end/models/trace/insights/InteractionToNextPaint.js",
11491149
"front_end/models/trace/insights/LCPDiscovery.js",
11501150
"front_end/models/trace/insights/LCPPhases.js",
1151-
"front_end/models/trace/insights/LongCriticalNetworkTree.js",
11521151
"front_end/models/trace/insights/Models.js",
1152+
"front_end/models/trace/insights/NetworkDependencyTree.js",
11531153
"front_end/models/trace/insights/RenderBlocking.js",
11541154
"front_end/models/trace/insights/SlowCSSSelector.js",
11551155
"front_end/models/trace/insights/Statistics.js",
@@ -1912,7 +1912,7 @@ grd_files_debug_sources = [
19121912
"front_end/panels/timeline/components/insights/InteractionToNextPaint.js",
19131913
"front_end/panels/timeline/components/insights/LCPDiscovery.js",
19141914
"front_end/panels/timeline/components/insights/LCPPhases.js",
1915-
"front_end/panels/timeline/components/insights/LongCriticalNetworkTree.js",
1915+
"front_end/panels/timeline/components/insights/NetworkDependencyTree.js",
19161916
"front_end/panels/timeline/components/insights/NodeLink.js",
19171917
"front_end/panels/timeline/components/insights/RenderBlocking.js",
19181918
"front_end/panels/timeline/components/insights/SidebarInsight.js",
@@ -1922,7 +1922,7 @@ grd_files_debug_sources = [
19221922
"front_end/panels/timeline/components/insights/Viewport.js",
19231923
"front_end/panels/timeline/components/insights/baseInsightComponent.css.js",
19241924
"front_end/panels/timeline/components/insights/checklist.css.js",
1925-
"front_end/panels/timeline/components/insights/longCriticalNetworkTreeInsight.css.js",
1925+
"front_end/panels/timeline/components/insights/networkDependencyTreeInsight.css.js",
19261926
"front_end/panels/timeline/components/insights/table.css.js",
19271927
"front_end/panels/timeline/components/insights/types.js",
19281928
"front_end/panels/timeline/components/interactionBreakdown.css.js",

front_end/models/trace/Processor.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,7 @@ describeWithEnvironment('TraceProcessor', function() {
406406
'LCPPhases',
407407
'LCPDiscovery',
408408
'RenderBlocking',
409-
'LongCriticalNetworkTree',
409+
'NetworkDependencyTree',
410410
'ImageDelivery',
411411
'DocumentLatency',
412412
'FontDisplay',
@@ -426,7 +426,7 @@ describeWithEnvironment('TraceProcessor', function() {
426426
'LCPPhases',
427427
'LCPDiscovery',
428428
'RenderBlocking',
429-
'LongCriticalNetworkTree',
429+
'NetworkDependencyTree',
430430
'ImageDelivery',
431431
'DocumentLatency',
432432
'FontDisplay',

front_end/models/trace/Processor.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ export class TraceProcessor extends EventTarget {
345345
LCPDiscovery: null,
346346
CLSCulprits: null,
347347
RenderBlocking: null,
348-
LongCriticalNetworkTree: null,
348+
NetworkDependencyTree: null,
349349
ImageDelivery: null,
350350
DocumentLatency: null,
351351
FontDisplay: null,

front_end/models/trace/insights/BUILD.gn

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ devtools_module("insights") {
1919
"InteractionToNextPaint.ts",
2020
"LCPDiscovery.ts",
2121
"LCPPhases.ts",
22-
"LongCriticalNetworkTree.ts",
2322
"Models.ts",
23+
"NetworkDependencyTree.ts",
2424
"RenderBlocking.ts",
2525
"SlowCSSSelector.ts",
2626
"Statistics.ts",
@@ -62,7 +62,7 @@ ts_library("unittests") {
6262
"InteractionToNextPaint.test.ts",
6363
"LCPDiscovery.test.ts",
6464
"LCPPhases.test.ts",
65-
"LongCriticalNetworkTree.test.ts",
65+
"NetworkDependencyTree.test.ts",
6666
"RenderBlocking.test.ts",
6767
"SlowCSSSelector.test.ts",
6868
"Statistics.test.ts",

front_end/models/trace/insights/Models.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export * as ImageDelivery from './ImageDelivery.js';
1212
export * as InteractionToNextPaint from './InteractionToNextPaint.js';
1313
export * as LCPDiscovery from './LCPDiscovery.js';
1414
export * as LCPPhases from './LCPPhases.js';
15-
export * as LongCriticalNetworkTree from './LongCriticalNetworkTree.js';
15+
export * as NetworkDependencyTree from './NetworkDependencyTree.js';
1616
export * as RenderBlocking from './RenderBlocking.js';
1717
export * as SlowCSSSelector from './SlowCSSSelector.js';
1818
export * as ThirdParties from './ThirdParties.js';

front_end/models/trace/insights/LongCriticalNetworkTree.test.ts renamed to front_end/models/trace/insights/NetworkDependencyTree.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ import {describeWithEnvironment} from '../../../testing/EnvironmentHelpers.js';
66
import {getFirstOrError, getInsightOrError, processTrace} from '../../../testing/InsightHelpers.js';
77
import * as Trace from '../trace.js';
88

9-
describeWithEnvironment('LongCriticalNetworkTree', function() {
9+
describeWithEnvironment('NetworkDependencyTree', function() {
1010
it('calculates network dependency tree', async () => {
1111
const {data, insights} = await processTrace(this, 'lcp-multiple-frames.json.gz');
1212
const firstNav = getFirstOrError(data.Meta.navigationsByNavigationId.values());
13-
const insight = getInsightOrError('LongCriticalNetworkTree', insights, firstNav);
13+
const insight = getInsightOrError('NetworkDependencyTree', insights, firstNav);
1414

1515
// The network dependency tree in this trace is
1616
// | .../index.html (ts:566777570990, dur:5005590)

front_end/models/trace/insights/LongCriticalNetworkTree.ts renamed to front_end/models/trace/insights/NetworkDependencyTree.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export const UIStrings = {
2121
/**
2222
* @description Title of an insight that recommends avoiding chaining critical requests.
2323
*/
24-
title: 'Long critical network tree',
24+
title: 'Network dependency tree',
2525
/**
2626
* @description Description of an insight that recommends avoiding chaining critical requests.
2727
*/
@@ -30,15 +30,15 @@ export const UIStrings = {
3030
/**
3131
* @description Text status indicating that there isn't long chaining critical network requests.
3232
*/
33-
noLongCriticalNetworkTree: 'No rendering tasks impacted by long critical network tree',
33+
noNetworkDependencyTree: 'No rendering tasks impacted by network dependencies',
3434
/**
3535
* @description Text for the maximum critical path latency. This refers to the longest chain of network requests that
3636
* the browser must download before it can render the page.
3737
*/
3838
maxCriticalPathLatency: 'Max critical path latency:'
3939
};
4040

41-
const str_ = i18n.i18n.registerUIStrings('models/trace/insights/LongCriticalNetworkTree.ts', UIStrings);
41+
const str_ = i18n.i18n.registerUIStrings('models/trace/insights/NetworkDependencyTree.ts', UIStrings);
4242
export const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
4343

4444
// XHRs are fetched at High priority, but we exclude them, as they are unlikely to be critical
@@ -56,7 +56,7 @@ export interface CriticalRequestNode {
5656
children: CriticalRequestNode[];
5757
}
5858

59-
export type LongCriticalNetworkTreeInsightModel = InsightModel<typeof UIStrings, {
59+
export type NetworkDependencyTreeInsightModel = InsightModel<typeof UIStrings, {
6060
rootNodes: CriticalRequestNode[],
6161
maxTime: Types.Timing.Micro,
6262
}>;
@@ -65,10 +65,10 @@ export function deps(): ['NetworkRequests'] {
6565
return ['NetworkRequests'];
6666
}
6767

68-
function finalize(partialModel: PartialInsightModel<LongCriticalNetworkTreeInsightModel>):
69-
LongCriticalNetworkTreeInsightModel {
68+
function finalize(partialModel: PartialInsightModel<NetworkDependencyTreeInsightModel>):
69+
NetworkDependencyTreeInsightModel {
7070
return {
71-
insightKey: 'LongCriticalNetworkTree',
71+
insightKey: 'NetworkDependencyTree',
7272
strings: UIStrings,
7373
title: i18nString(UIStrings.title),
7474
description: i18nString(UIStrings.description),
@@ -113,7 +113,7 @@ function isCritical(request: Types.Events.SyntheticNetworkRequest, context: Insi
113113
}
114114

115115
export function generateInsight(
116-
_parsedTrace: RequiredData<typeof deps>, context: InsightSetContext): LongCriticalNetworkTreeInsightModel {
116+
_parsedTrace: RequiredData<typeof deps>, context: InsightSetContext): NetworkDependencyTreeInsightModel {
117117
if (!context.navigation) {
118118
return finalize({
119119
rootNodes: [],

front_end/panels/ai_assistance/data_formatters/PerformanceInsightFormatter.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ We can break this time down into the 4 phases that combine to make up the LCP ti
8585
case 'LCPPhases':
8686
return `- https://web.dev/articles/lcp
8787
- https://web.dev/articles/optimize-lcp`;
88-
case 'LongCriticalNetworkTree':
88+
case 'NetworkDependencyTree':
8989
return '';
9090
case 'RenderBlocking':
9191
return '';
@@ -119,7 +119,7 @@ We can break this time down into the 4 phases that combine to make up the LCP ti
119119
return '';
120120
case 'LCPPhases':
121121
return 'This insight is used to analyse the loading of the LCP resource and identify which of the 4 phases are contributing most to the delay in rendering the LCP element. For this insight it can be useful to get a list of all network requests that happened before the LCP time and look for slow requests. You can also look for main thread activity during the phases, in particular the load delay and render delay phases.';
122-
case 'LongCriticalNetworkTree':
122+
case 'NetworkDependencyTree':
123123
return '';
124124
case 'RenderBlocking':
125125
return '';

front_end/panels/timeline/components/SidebarSingleInsightSet.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ describeWithEnvironment('SidebarSingleInsightSet', () => {
158158
assert.deepEqual(userVisibleTitles, [
159159
'LCP by phase',
160160
'Layout shift culprits',
161-
'Long critical network tree',
161+
'Network dependency tree',
162162
'Improve image delivery',
163163
'Font display',
164164
'3rd parties',

front_end/panels/timeline/components/SidebarSingleInsightSet.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export interface SidebarSingleInsightSetData {
9191
* users. */
9292
const EXPERIMENTAL_INSIGHTS: ReadonlySet<string> = new Set([
9393
'FontDisplay',
94-
'LongCriticalNetworkTree',
94+
'NetworkDependencyTree',
9595
]);
9696

9797
type InsightNameToComponentMapping = Record<
@@ -111,7 +111,7 @@ const INSIGHT_NAME_TO_COMPONENT: InsightNameToComponentMapping = {
111111
InteractionToNextPaint: Insights.InteractionToNextPaint.InteractionToNextPaint,
112112
LCPDiscovery: Insights.LCPDiscovery.LCPDiscovery,
113113
LCPPhases: Insights.LCPPhases.LCPPhases,
114-
LongCriticalNetworkTree: Insights.LongCriticalNetworkTree.LongCriticalNetworkTree,
114+
NetworkDependencyTree: Insights.NetworkDependencyTree.NetworkDependencyTree,
115115
RenderBlocking: Insights.RenderBlocking.RenderBlocking,
116116
SlowCSSSelector: Insights.SlowCSSSelector.SlowCSSSelector,
117117
ThirdParties: Insights.ThirdParties.ThirdParties,

0 commit comments

Comments
 (0)