Skip to content

Commit ed64102

Browse files
committed
refactor: wip
1 parent cdb745b commit ed64102

3 files changed

Lines changed: 184 additions & 50 deletions

File tree

packages/utils/src/lib/profiler/__snapshots__/create-entries-write-sink.json

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
[
22
{
3-
"args": {},
43
"displayTimeUnit": "ms",
54
"metadata": {
65
"dataOrigin": "TraceEvents",
@@ -13,14 +12,14 @@
1312
{
1413
"args": {
1514
"data": {
16-
"frameTreeNodeId": 5059301,
15+
"frameTreeNodeId": 1000101,
1716
"frames": [
1817
{
19-
"frame": "FRAME0P50593T1",
18+
"frame": "FRAME0P10001T1",
2019
"isInPrimaryMainFrame": true,
2120
"isOutermostMainFrame": true,
2221
"name": "",
23-
"processId": 50593,
22+
"processId": 10001,
2423
"url": "generated-trace",
2524
},
2625
],
@@ -30,19 +29,19 @@
3029
"cat": "devtools.timeline",
3130
"name": "TracingStartedInBrowser",
3231
"ph": "i",
33-
"pid": 50593,
32+
"pid": 10001,
3433
"tid": 1,
35-
"ts": 1769610566981801,
34+
"ts": 1700000005000000,
3635
},
3736
{
3837
"args": {},
3938
"cat": "devtools.timeline",
4039
"dur": 20000,
4140
"name": "[trace padding start]",
4241
"ph": "X",
43-
"pid": 50593,
42+
"pid": 10001,
4443
"tid": 1,
45-
"ts": 1769610566981801,
44+
"ts": 1700000005000000,
4645
},
4746
{
4847
"args": {
@@ -56,9 +55,9 @@
5655
"cat": "blink.user_timing",
5756
"name": "test-operation:start",
5857
"ph": "i",
59-
"pid": 50593,
58+
"pid": 10001,
6059
"tid": 1,
61-
"ts": 1769610567981801,
60+
"ts": 1700000005000002,
6261
},
6362
{
6463
"args": {
@@ -73,13 +72,13 @@
7372
},
7473
"cat": "blink.user_timing",
7574
"id2": {
76-
"local": "0x2",
75+
"local": "0x1",
7776
},
7877
"name": "test-operation",
7978
"ph": "b",
80-
"pid": 50593,
79+
"pid": 10001,
8180
"tid": 1,
82-
"ts": 1769610567981802,
81+
"ts": 1700000005000003,
8382
},
8483
{
8584
"args": {
@@ -94,13 +93,13 @@
9493
},
9594
"cat": "blink.user_timing",
9695
"id2": {
97-
"local": "0x2",
96+
"local": "0x1",
9897
},
9998
"name": "test-operation",
10099
"ph": "e",
101-
"pid": 50593,
100+
"pid": 10001,
102101
"tid": 1,
103-
"ts": 1769610567981917,
102+
"ts": 1700000005000004,
104103
},
105104
{
106105
"args": {
@@ -114,19 +113,19 @@
114113
"cat": "blink.user_timing",
115114
"name": "test-operation:end",
116115
"ph": "i",
117-
"pid": 50593,
116+
"pid": 10001,
118117
"tid": 1,
119-
"ts": 1769610567981918,
118+
"ts": 1700000005000005,
120119
},
121120
{
122121
"args": {},
123122
"cat": "devtools.timeline",
124123
"dur": 20000,
125124
"name": "[trace padding end]",
126125
"ph": "X",
127-
"pid": 50593,
126+
"pid": 10001,
128127
"tid": 1,
129-
"ts": 1769610568981918,
128+
"ts": 1700000005000006,
130129
},
131130
],
132131
},

packages/utils/src/lib/profiler/__snapshots__/write-test.json

Lines changed: 21 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,25 @@
11
[
22
{
3-
"args": {},
43
"displayTimeUnit": "ms",
54
"metadata": {
65
"dataOrigin": "TraceEvents",
7-
"generatedAt": "2026-01-28T14:29:28.023Z",
6+
"generatedAt": "2026-01-28T14:29:27.995Z",
87
"hardwareConcurrency": 1,
98
"source": "DevTools",
10-
"startTime": "2026-01-28T14:29:28.023Z",
9+
"startTime": "2026-01-28T14:29:27.995Z",
1110
},
1211
"traceEvents": [
1312
{
1413
"args": {
1514
"data": {
16-
"frameTreeNodeId": 5059301,
15+
"frameTreeNodeId": 1000101,
1716
"frames": [
1817
{
19-
"frame": "FRAME0P50593T1",
18+
"frame": "FRAME0P10001T1",
2019
"isInPrimaryMainFrame": true,
2120
"isOutermostMainFrame": true,
2221
"name": "",
23-
"processId": 50593,
22+
"processId": 10001,
2423
"url": "generated-trace",
2524
},
2625
],
@@ -30,19 +29,19 @@
3029
"cat": "devtools.timeline",
3130
"name": "TracingStartedInBrowser",
3231
"ph": "i",
33-
"pid": 50593,
32+
"pid": 10001,
3433
"tid": 1,
35-
"ts": 1769610567011998,
34+
"ts": 1700000005000000,
3635
},
3736
{
3837
"args": {},
3938
"cat": "devtools.timeline",
4039
"dur": 20000,
4140
"name": "[trace padding start]",
4241
"ph": "X",
43-
"pid": 50593,
42+
"pid": 10001,
4443
"tid": 1,
45-
"ts": 1769610567011998,
44+
"ts": 1700000005000000,
4645
},
4746
{
4847
"args": {
@@ -56,9 +55,9 @@
5655
"cat": "blink.user_timing",
5756
"name": "test-operation:start",
5857
"ph": "i",
59-
"pid": 50593,
58+
"pid": 10001,
6059
"tid": 1,
61-
"ts": 1769610568011998,
60+
"ts": 1700000005000002,
6261
},
6362
{
6463
"args": {
@@ -73,13 +72,13 @@
7372
},
7473
"cat": "blink.user_timing",
7574
"id2": {
76-
"local": "0x22",
75+
"local": "0x1",
7776
},
7877
"name": "test-operation",
7978
"ph": "b",
80-
"pid": 50593,
79+
"pid": 10001,
8180
"tid": 1,
82-
"ts": 1769610568011999,
81+
"ts": 1700000005000003,
8382
},
8483
{
8584
"args": {
@@ -94,13 +93,13 @@
9493
},
9594
"cat": "blink.user_timing",
9695
"id2": {
97-
"local": "0x22",
96+
"local": "0x1",
9897
},
9998
"name": "test-operation",
10099
"ph": "e",
101-
"pid": 50593,
100+
"pid": 10001,
102101
"tid": 1,
103-
"ts": 1769610568012014,
102+
"ts": 1700000005000004,
104103
},
105104
{
106105
"args": {
@@ -114,19 +113,19 @@
114113
"cat": "blink.user_timing",
115114
"name": "test-operation:end",
116115
"ph": "i",
117-
"pid": 50593,
116+
"pid": 10001,
118117
"tid": 1,
119-
"ts": 1769610568012015,
118+
"ts": 1700000005000005,
120119
},
121120
{
122121
"args": {},
123122
"cat": "devtools.timeline",
124123
"dur": 20000,
125124
"name": "[trace padding end]",
126125
"ph": "X",
127-
"pid": 50593,
126+
"pid": 10001,
128127
"tid": 1,
129-
"ts": 1769610569012015,
128+
"ts": 1700000005000006,
130129
},
131130
],
132131
},

0 commit comments

Comments
 (0)