The Node.js® Website

docs(learn): Migrate diagnostics user journey from guide to learn section (#6291)

* fix: redirect old guide links to new learn section

- redirect old guide links to new learn section
- fix the focus on click to the #filtering-out-nodejs-internal-functions

* docs(learn): migrate diagnostics user journey to learn

* doc(learn): add redirect changes

* fix(learn): fix redirect url

* doc(learn): move internal links to the nav and fix redirect

* doc(learn): remove toc from files

* docs(learn): change javascript snippets to js

authored by Paulo Belucci and committed by GitHub d54acbd0 35111002

+98 -89
+4
i18n/locales/en.json
··· 87 "diagnostics": { 88 "links": { 89 "diagnostics": "Diagnostics", 90 "flameGraphs": "Flame Graphs" 91 } 92 }
··· 87 "diagnostics": { 88 "links": { 89 "diagnostics": "Diagnostics", 90 + "userJourney": "User Journey", 91 + "memory": "Memory", 92 + "liveDebugging": "Live Debugging", 93 + "poorPerformance": "Poor Performance", 94 "flameGraphs": "Flame Graphs" 95 } 96 }
+16
navigation.json
··· 234 "diagnostics": { 235 "label": "components.navigation.learn.diagnostics.links.diagnostics", 236 "items": { 237 "flameGraphs": { 238 "link": "/learn/diagnostics/flame-graphs", 239 "label": "components.navigation.learn.diagnostics.links.flameGraphs"
··· 234 "diagnostics": { 235 "label": "components.navigation.learn.diagnostics.links.diagnostics", 236 "items": { 237 + "userJourney": { 238 + "link": "/learn/diagnostics/user-journey", 239 + "label": "components.navigation.learn.diagnostics.links.userJourney" 240 + }, 241 + "memory": { 242 + "link": "/learn/diagnostics/memory", 243 + "label": "components.navigation.learn.diagnostics.links.memory" 244 + }, 245 + "liveDebugging": { 246 + "link": "/learn/diagnostics/live-debugging", 247 + "label": "components.navigation.learn.diagnostics.links.liveDebugging" 248 + }, 249 + "poorPerformance": { 250 + "link": "/learn/diagnostics/poor-performance", 251 + "label": "components.navigation.learn.diagnostics.links.poorPerformance" 252 + }, 253 "flameGraphs": { 254 "link": "/learn/diagnostics/flame-graphs", 255 "label": "components.navigation.learn.diagnostics.links.flameGraphs"
+11 -11
pages/en/guides/backpressuring-in-streams.md
··· 36 part of the internal codebase utilizes that module. As a developer, you 37 are more than encouraged to use them too! 38 39 - ```javascript 40 const readline = require('readline'); 41 42 // process.stdin and process.stdout are both instances of Streams. ··· 67 a script that takes Node.js' module [`zlib`][], that wraps around another 68 compression tool, [`gzip(1)`][]. 69 70 - ```javascript 71 const gzip = require('zlib').createGzip(); 72 const fs = require('fs'); 73 ··· 95 96 Here is an example of using pipeline: 97 98 - ```javascript 99 const { pipeline } = require('stream'); 100 const fs = require('fs'); 101 const zlib = require('zlib'); ··· 120 121 You can also call [`promisify`][] on pipeline to use it with `async` / `await`: 122 123 - ```javascript 124 const stream = require('stream'); 125 const fs = require('fs'); 126 const zlib = require('zlib'); ··· 156 occur because the write disk will not be able to keep up with the speed from 157 the read. 158 159 - ```javascript 160 // Secretly the stream is saying: "whoa, whoa! hang on, this is way too much!" 161 // Data will begin to build up on the read-side of the data buffer as 162 // `write` tries to keep up with the incoming data flow. ··· 417 In this case, your output from your [`Readable`][] stream will enter in the 418 [`Transform`][] and will pipe into the [`Writable`][]. 419 420 - ```javascript 421 Readable.pipe(Transformable).pipe(Writable); 422 ``` 423 ··· 477 478 Here is an example of bad practice using [`.push()`][]: 479 480 - ```javascript 481 // This is problematic as it completely ignores return value from push 482 // which may be a signal for backpressure from the destination stream! 483 class MyReadable extends Readable { ··· 495 forces data through whenever it is available (signaled by the 496 [`'data'` event][]): 497 498 - ```javascript 499 // This ignores the backpressure mechanisms Node.js has set in place, 500 // and unconditionally pushes through data, regardless if the 501 // destination stream is ready for it or not. ··· 504 505 Here's an example of using [`.push()`][] with a Readable stream. 506 507 - ```javascript 508 const { Readable } = require('stream'); 509 510 // Create a custom Readable stream ··· 551 552 <!-- eslint-disable indent --> 553 554 - ```javascript 555 // This writable is invalid because of the async nature of JavaScript callbacks. 556 // Without a return statement for each callback prior to the last, 557 // there is a great chance multiple callbacks will be called. ··· 573 The function is coupled with [`.cork()`][], but there is a common mistake when 574 writing: 575 576 - ```javascript 577 // Using .uncork() twice here makes two calls on the C++ layer, rendering the 578 // cork/uncork technique useless. 579 ws.cork();
··· 36 part of the internal codebase utilizes that module. As a developer, you 37 are more than encouraged to use them too! 38 39 + ```js 40 const readline = require('readline'); 41 42 // process.stdin and process.stdout are both instances of Streams. ··· 67 a script that takes Node.js' module [`zlib`][], that wraps around another 68 compression tool, [`gzip(1)`][]. 69 70 + ```js 71 const gzip = require('zlib').createGzip(); 72 const fs = require('fs'); 73 ··· 95 96 Here is an example of using pipeline: 97 98 + ```js 99 const { pipeline } = require('stream'); 100 const fs = require('fs'); 101 const zlib = require('zlib'); ··· 120 121 You can also call [`promisify`][] on pipeline to use it with `async` / `await`: 122 123 + ```js 124 const stream = require('stream'); 125 const fs = require('fs'); 126 const zlib = require('zlib'); ··· 156 occur because the write disk will not be able to keep up with the speed from 157 the read. 158 159 + ```js 160 // Secretly the stream is saying: "whoa, whoa! hang on, this is way too much!" 161 // Data will begin to build up on the read-side of the data buffer as 162 // `write` tries to keep up with the incoming data flow. ··· 417 In this case, your output from your [`Readable`][] stream will enter in the 418 [`Transform`][] and will pipe into the [`Writable`][]. 419 420 + ```js 421 Readable.pipe(Transformable).pipe(Writable); 422 ``` 423 ··· 477 478 Here is an example of bad practice using [`.push()`][]: 479 480 + ```js 481 // This is problematic as it completely ignores return value from push 482 // which may be a signal for backpressure from the destination stream! 483 class MyReadable extends Readable { ··· 495 forces data through whenever it is available (signaled by the 496 [`'data'` event][]): 497 498 + ```js 499 // This ignores the backpressure mechanisms Node.js has set in place, 500 // and unconditionally pushes through data, regardless if the 501 // destination stream is ready for it or not. ··· 504 505 Here's an example of using [`.push()`][] with a Readable stream. 506 507 + ```js 508 const { Readable } = require('stream'); 509 510 // Create a custom Readable stream ··· 551 552 <!-- eslint-disable indent --> 553 554 + ```js 555 // This writable is invalid because of the async nature of JavaScript callbacks. 556 // Without a return statement for each callback prior to the last, 557 // there is a great chance multiple callbacks will be called. ··· 573 The function is coupled with [`.cork()`][], but there is a common mistake when 574 writing: 575 576 + ```js 577 // Using .uncork() twice here makes two calls on the C++ layer, rendering the 578 // cork/uncork technique useless. 579 ws.cork();
-22
pages/en/guides/diagnostics/index.md
··· 1 - --- 2 - title: Diagnostics Guide 3 - layout: docs.hbs 4 - --- 5 - 6 - # Diagnostics Guide 7 - 8 - These guides were created by the [Diagnostics Working Group][] with the 9 - objective of providing guidance when diagnosing an issue in a user's 10 - application. 11 - 12 - The documentation project is organized based on user journey. Those journeys 13 - are a coherent set of step-by-step procedures that a user can follow to 14 - root-cause their issues. 15 - 16 - This is the available set of diagnostics guides: 17 - 18 - - [Memory](/guides/diagnostics/memory) 19 - - [Live Debugging](/guides/diagnostics/live-debugging) 20 - - [Poor Performance](/guides/diagnostics/poor-performance) 21 - 22 - [Diagnostics Working Group]: https://github.com/nodejs/diagnostics
···
+2 -7
pages/en/guides/diagnostics/live-debugging/index.md pages/en/learn/diagnostics/live-debugging/index.md
··· 1 --- 2 title: Live Debugging 3 - layout: docs.hbs 4 --- 5 6 # Live Debugging 7 - 8 - - [Live Debugging](#live-debugging) 9 - - [My application doesn’t behave as expected](#my-application-doesnt-behave-as-expected) 10 - - [Symptoms](#symptoms) 11 - - [Debugging](#debugging) 12 13 In this document you can learn about how to live debug a Node.js process. 14 ··· 28 may also want to step through the code and control the execution as well as 29 inspect what values variables hold in memory. 30 31 - - [Using Inspector](/guides/diagnostics/live-debugging/using-inspector)
··· 1 --- 2 title: Live Debugging 3 + layout: learn.hbs 4 --- 5 6 # Live Debugging 7 8 In this document you can learn about how to live debug a Node.js process. 9 ··· 23 may also want to step through the code and control the execution as well as 24 inspect what values variables hold in memory. 25 26 + - [Using Inspector](/learn/diagnostics/live-debugging/using-inspector)
+2 -2
pages/en/guides/diagnostics/live-debugging/using-inspector.md pages/en/learn/diagnostics/live-debugging/using-inspector.md
··· 1 --- 2 title: Using Inspector 3 - layout: docs.hbs 4 --- 5 6 # Using Inspector ··· 14 15 ## How To 16 17 - /guides/debugging-getting-started/
··· 1 --- 2 title: Using Inspector 3 + layout: learn.hbs 4 --- 5 6 # Using Inspector ··· 14 15 ## How To 16 17 + [Debugging Node.js](/learn/getting-started/debugging)
+5 -14
pages/en/guides/diagnostics/memory/index.md pages/en/learn/diagnostics/memory/index.md
··· 1 --- 2 - title: Memory Diagnostics 3 - layout: docs.hbs 4 --- 5 6 # Memory 7 8 In this document you can learn about how to debug memory related issues. 9 - 10 - - [Memory](#memory) 11 - - [My process runs out of memory](#my-process-runs-out-of-memory) 12 - - [Symptoms](#symptoms) 13 - - [Side Effects](#side-effects) 14 - - [My process utilizes memory inefficiently](#my-process-utilizes-memory-inefficiently) 15 - - [Symptoms](#symptoms-1) 16 - - [Side Effects](#side-effects-1) 17 - - [Debugging](#debugging) 18 19 ## My process runs out of memory 20 ··· 58 collected. It can also help to know the allocation pattern of our program over 59 time. 60 61 - - [Using Heap Profiler](/guides/diagnostics/memory/using-heap-profiler/) 62 - - [Using Heap Snapshot](/guides/diagnostics/memory/using-heap-snapshot/) 63 - - [GC Traces](/guides/diagnostics/memory/using-gc-traces)
··· 1 --- 2 + title: Memory 3 + layout: learn.hbs 4 --- 5 6 # Memory 7 8 In this document you can learn about how to debug memory related issues. 9 10 ## My process runs out of memory 11 ··· 49 collected. It can also help to know the allocation pattern of our program over 50 time. 51 52 + - [Using Heap Profiler](/learn/diagnostics/memory/using-heap-profiler/) 53 + - [Using Heap Snapshot](/learn/diagnostics/memory/using-heap-snapshot/) 54 + - [GC Traces](/learn/diagnostics/memory/using-gc-traces)
+3 -3
pages/en/guides/diagnostics/memory/using-gc-traces.md pages/en/learn/diagnostics/memory/using-gc-traces.md
··· 1 --- 2 - title: Memory Diagnostics - Using GC Trace 3 - layout: docs.hbs 4 --- 5 6 # Tracing garbage collection ··· 393 [`--max-old-space-size`]: https://nodejs.org/api/cli.html#--max-old-space-sizesize-in-megabytes 394 [performance hooks]: https://nodejs.org/api/perf_hooks.html 395 [exercise]: https://github.com/nodejs/diagnostics/tree/main/documentation/memory/step3/exercise 396 - [guide dedicated to heap snapshot]: /guides/diagnostics/memory/using-heap-snapshot#how-to-find-a-memory-leak-with-heap-snapshots 397 [document]: https://github.com/thlorenz/v8-perf/blob/master/gc.md#marking-state 398 [Scavenge scenario]: https://github.com/thlorenz/v8-perf/blob/master/gc.md#sample-scavenge-scenario 399 [talk of Peter Marshall]: https://v8.dev/blog/trash-talk
··· 1 --- 2 + title: Tracing garbage collection 3 + layout: learn.hbs 4 --- 5 6 # Tracing garbage collection ··· 393 [`--max-old-space-size`]: https://nodejs.org/api/cli.html#--max-old-space-sizesize-in-megabytes 394 [performance hooks]: https://nodejs.org/api/perf_hooks.html 395 [exercise]: https://github.com/nodejs/diagnostics/tree/main/documentation/memory/step3/exercise 396 + [guide dedicated to heap snapshot]: /learn/diagnostics/memory/using-heap-snapshot#how-to-find-a-memory-leak-with-heap-snapshots 397 [document]: https://github.com/thlorenz/v8-perf/blob/master/gc.md#marking-state 398 [Scavenge scenario]: https://github.com/thlorenz/v8-perf/blob/master/gc.md#sample-scavenge-scenario 399 [talk of Peter Marshall]: https://v8.dev/blog/trash-talk
+3 -4
pages/en/guides/diagnostics/memory/using-heap-profiler.md pages/en/learn/diagnostics/memory/using-heap-profiler.md
··· 1 --- 2 - title: Memory Diagnostics - Using Heap Profiler 3 - layout: docs.hbs 4 --- 5 6 # Using Heap Profiler ··· 97 ## Useful Links 98 99 - https://developer.chrome.com/docs/devtools/memory-problems/memory-101/ 100 - - https://github.com/v8/sampling-heap-profiler 101 - https://developer.chrome.com/docs/devtools/memory-problems/allocation-profiler/ 102 103 - [Using Heap Snapshot]: /guides/diagnostics/memory/using-heap-snapshot/ 104 [@mmarchini/observe]: https://www.npmjs.com/package/@mmarchini/observe 105 [`heap-profiler`]: https://www.npmjs.com/package/heap-profile 106 [heap profiler tutorial 1]: /static/images/docs/guides/diagnostics/heap-profiler-tutorial-1.png
··· 1 --- 2 + title: Using Heap Profiler 3 + layout: learn.hbs 4 --- 5 6 # Using Heap Profiler ··· 97 ## Useful Links 98 99 - https://developer.chrome.com/docs/devtools/memory-problems/memory-101/ 100 - https://developer.chrome.com/docs/devtools/memory-problems/allocation-profiler/ 101 102 + [Using Heap Snapshot]: /learn/diagnostics/memory/using-heap-snapshot/ 103 [@mmarchini/observe]: https://www.npmjs.com/package/@mmarchini/observe 104 [`heap-profiler`]: https://www.npmjs.com/package/heap-profile 105 [heap profiler tutorial 1]: /static/images/docs/guides/diagnostics/heap-profiler-tutorial-1.png
+2 -2
pages/en/guides/diagnostics/memory/using-heap-snapshot.md pages/en/learn/diagnostics/memory/using-heap-snapshot.md
··· 1 --- 2 - title: Memory Diagnostics - Using Heap Snapshot 3 - layout: docs.hbs 4 --- 5 6 # Using Heap Snapshot
··· 1 --- 2 + title: Using Heap Snapshot 3 + layout: learn.hbs 4 --- 5 6 # Using Heap Snapshot
+3 -8
pages/en/guides/diagnostics/poor-performance/index.md pages/en/learn/diagnostics/poor-performance/index.md
··· 1 --- 2 - title: Poor Performance - Diagnostics 3 - layout: docs.hbs 4 --- 5 6 # Poor Performance 7 8 In this document you can learn about how to profile a Node.js process. 9 - 10 - - [Poor Performance](#poor-performance) 11 - - [My application has a poor performance](#my-application-has-a-poor-performance) 12 - - [Symptoms](#symptoms) 13 - - [Debugging](#debugging) 14 15 ## My application has a poor performance 16 ··· 33 This document provides two simple ways to profile a Node.js application: 34 35 - [Using V8 Sampling Profiler](/guides/simple-profiling/) 36 - - [Using Linux Perf](/guides/diagnostics/poor-performance/using-linux-perf)
··· 1 --- 2 + title: Poor Performance 3 + layout: learn.hbs 4 --- 5 6 # Poor Performance 7 8 In this document you can learn about how to profile a Node.js process. 9 10 ## My application has a poor performance 11 ··· 28 This document provides two simple ways to profile a Node.js application: 29 30 - [Using V8 Sampling Profiler](/guides/simple-profiling/) 31 + - [Using Linux Perf](/learn/diagnostics/poor-performance/using-linux-perf)
+2 -2
pages/en/guides/diagnostics/poor-performance/using-linux-perf.md pages/en/learn/diagnostics/poor-performance/using-linux-perf.md
··· 1 --- 2 - title: Poor Performance - Using Linux Perf 3 - layout: docs.hbs 4 --- 5 6 # Using Linux Perf
··· 1 --- 2 + title: Using Linux Perf 3 + layout: learn.hbs 4 --- 5 6 # Using Linux Perf
+7 -7
pages/en/guides/dont-block-the-event-loop.md
··· 116 117 Example 1: A constant-time callback. 118 119 - ```javascript 120 app.get('/constant-time', (req, res) => { 121 res.sendStatus(200); 122 }); ··· 124 125 Example 2: An `O(n)` callback. This callback will run quickly for small `n` and more slowly for large `n`. 126 127 - ```javascript 128 app.get('/countToN', (req, res) => { 129 let n = req.query.n; 130 ··· 139 140 Example 3: An `O(n^2)` callback. This callback will still run quickly for small `n`, but for large `n` it will run much more slowly than the previous `O(n)` example. 141 142 - ```javascript 143 app.get('/countToN2', (req, res) => { 144 let n = req.query.n; 145 ··· 191 192 Here is an example vulnerable regexp exposing its server to REDOS: 193 194 - ```javascript 195 app.get('/redos-me', (req, res) => { 196 let filePath = req.query.filePath; 197 ··· 269 270 Example: JSON blocking. We create an object `obj` of size 2^21 and `JSON.stringify` it, run `indexOf` on the string, and then JSON.parse it. The `JSON.stringify`'d string is 50MB. It takes 0.7 seconds to stringify the object, 0.03 seconds to indexOf on the 50MB string, and 1.3 seconds to parse the string. 271 272 - ```javascript 273 var obj = { a: 1 }; 274 var niter = 20; 275 ··· 314 315 Example 1: Un-partitioned average, costs `O(n)` 316 317 - ```javascript 318 for (let i = 0; i < n; i++) sum += i; 319 let avg = sum / n; 320 console.log('avg: ' + avg); ··· 322 323 Example 2: Partitioned average, each of the `n` asynchronous steps costs `O(1)`. 324 325 - ```javascript 326 function asyncAvg(n, avgCB) { 327 // Save ongoing sum in JS closure. 328 var sum = 0;
··· 116 117 Example 1: A constant-time callback. 118 119 + ```js 120 app.get('/constant-time', (req, res) => { 121 res.sendStatus(200); 122 }); ··· 124 125 Example 2: An `O(n)` callback. This callback will run quickly for small `n` and more slowly for large `n`. 126 127 + ```js 128 app.get('/countToN', (req, res) => { 129 let n = req.query.n; 130 ··· 139 140 Example 3: An `O(n^2)` callback. This callback will still run quickly for small `n`, but for large `n` it will run much more slowly than the previous `O(n)` example. 141 142 + ```js 143 app.get('/countToN2', (req, res) => { 144 let n = req.query.n; 145 ··· 191 192 Here is an example vulnerable regexp exposing its server to REDOS: 193 194 + ```js 195 app.get('/redos-me', (req, res) => { 196 let filePath = req.query.filePath; 197 ··· 269 270 Example: JSON blocking. We create an object `obj` of size 2^21 and `JSON.stringify` it, run `indexOf` on the string, and then JSON.parse it. The `JSON.stringify`'d string is 50MB. It takes 0.7 seconds to stringify the object, 0.03 seconds to indexOf on the 50MB string, and 1.3 seconds to parse the string. 271 272 + ```js 273 var obj = { a: 1 }; 274 var niter = 20; 275 ··· 314 315 Example 1: Un-partitioned average, costs `O(n)` 316 317 + ```js 318 for (let i = 0; i < n; i++) sum += i; 319 let avg = sum / n; 320 console.log('avg: ' + avg); ··· 322 323 Example 2: Partitioned average, each of the `n` asynchronous steps costs `O(1)`. 324 325 + ```js 326 function asyncAvg(n, avgCB) { 327 // Save ongoing sum in JS closure. 328 var sum = 0;
-1
pages/en/guides/index.md
··· 10 ## General 11 12 - [Easy profiling for Node.js Applications](/guides/simple-profiling/) 13 - - [Diagnostics - User Journey](/guides/diagnostics/) 14 - [Security Best Practices](/guides/security/) 15 16 ## Node.js core concepts
··· 10 ## General 11 12 - [Easy profiling for Node.js Applications](/guides/simple-profiling/) 13 - [Security Best Practices](/guides/security/) 14 15 ## Node.js core concepts
+1 -1
pages/en/guides/security/index.md
··· 426 [Slowloris]: https://en.wikipedia.org/wiki/Slowloris_(computer_security) 427 [`http.Server`]: https://nodejs.org/api/http.html#class-httpserver 428 [http docs]: https://nodejs.org/api/http.html 429 - [--inspect switch]: /guides/debugging-getting-started/ 430 [same-origin policy]: /guides/debugging-getting-started/ 431 [DNS Rebinding wiki]: https://en.wikipedia.org/wiki/DNS_rebinding 432 [files property]: https://docs.npmjs.com/cli/v8/configuring-npm/package-json#files
··· 426 [Slowloris]: https://en.wikipedia.org/wiki/Slowloris_(computer_security) 427 [`http.Server`]: https://nodejs.org/api/http.html#class-httpserver 428 [http docs]: https://nodejs.org/api/http.html 429 + [--inspect switch]: /learn/debugging-getting-started/ 430 [same-origin policy]: /guides/debugging-getting-started/ 431 [DNS Rebinding wiki]: https://en.wikipedia.org/wiki/DNS_rebinding 432 [files property]: https://docs.npmjs.com/cli/v8/configuring-npm/package-json#files
+4 -4
pages/en/guides/simple-profiling.md
··· 30 application. Our application will have two handlers, one for adding new users to 31 our system: 32 33 - ```javascript 34 app.get('/newUser', (req, res) => { 35 let username = req.query.username || ''; 36 const password = req.query.password || ''; ··· 52 53 and another for validating user authentication attempts: 54 55 - ```javascript 56 app.get('/auth', (req, res) => { 57 let username = req.query.username || ''; 58 const password = req.query.password || ''; ··· 217 To remedy this issue, you make a small modification to the above handlers to use 218 the asynchronous version of the pbkdf2 function: 219 220 - ```javascript 221 app.get('/auth', (req, res) => { 222 let username = req.query.username || ''; 223 const password = req.query.password || ''; ··· 287 288 [profiler inside V8]: https://v8.dev/docs/profile 289 [benefits of asynchronous programming]: https://nodesource.com/blog/why-asynchronous 290 - [diagnostics flamegraph]: /guides/diagnostics-flamegraph/
··· 30 application. Our application will have two handlers, one for adding new users to 31 our system: 32 33 + ```js 34 app.get('/newUser', (req, res) => { 35 let username = req.query.username || ''; 36 const password = req.query.password || ''; ··· 52 53 and another for validating user authentication attempts: 54 55 + ```js 56 app.get('/auth', (req, res) => { 57 let username = req.query.username || ''; 58 const password = req.query.password || ''; ··· 217 To remedy this issue, you make a small modification to the above handlers to use 218 the asynchronous version of the pbkdf2 function: 219 220 + ```js 221 app.get('/auth', (req, res) => { 222 let username = req.query.username || ''; 223 const password = req.query.password || ''; ··· 287 288 [profiler inside V8]: https://v8.dev/docs/profile 289 [benefits of asynchronous programming]: https://nodesource.com/blog/why-asynchronous 290 + [diagnostics flamegraph]: /learn/diagnostics/flame-graphs
+1 -1
pages/en/learn/diagnostics/flame-graphs.md
··· 39 ``` 40 41 4. Disregard warnings unless they're saying you can't run perf due to missing packages; you may get some warnings about not being able to access kernel module samples which you're not after anyway. 42 - 5. Run `perf script > perfs.out` to generate the data file you'll visualize in a moment. It's useful to [apply some cleanup](#filtering-out-node-js-internal-functions) for a more readable graph 43 6. Install stackvis if not yet installed `npm i -g stackvis` 44 7. Run `stackvis perf < perfs.out > flamegraph.htm` 45
··· 39 ``` 40 41 4. Disregard warnings unless they're saying you can't run perf due to missing packages; you may get some warnings about not being able to access kernel module samples which you're not after anyway. 42 + 5. Run `perf script > perfs.out` to generate the data file you'll visualize in a moment. It's useful to [apply some cleanup](#filtering-out-nodejs-internal-functions) for a more readable graph 43 6. Install stackvis if not yet installed `npm i -g stackvis` 44 7. Run `stackvis perf < perfs.out > flamegraph.htm` 45
+16
pages/en/learn/diagnostics/user-journey.md
···
··· 1 + --- 2 + title: User Journey 3 + layout: learn.hbs 4 + --- 5 + 6 + # User Journey 7 + 8 + These diagnostics guides were created by the [Diagnostics Working Group][] with the 9 + objective of providing guidance when diagnosing an issue in a user's 10 + application. 11 + 12 + The documentation project is organized based on user journey. Those journeys 13 + are a coherent set of step-by-step procedures that a user can follow to 14 + root-cause their issues. 15 + 16 + [Diagnostics Working Group]: https://github.com/nodejs/diagnostics
+16
redirects.json
··· 85 "destination": "https://openjsf.org/certification" 86 }, 87 { 88 "source": "/about", 89 "destination": "/en/about" 90 }, ··· 179 { 180 "source": "/:locale/docs/es6", 181 "destination": "/:locale/learn/getting-started/ecmascript-2015-es6-and-beyond" 182 }, 183 { 184 "source": "/:locale/docs",
··· 85 "destination": "https://openjsf.org/certification" 86 }, 87 { 88 + "source": "/guides", 89 + "destination": "/en/guides" 90 + }, 91 + { 92 "source": "/about", 93 "destination": "/en/about" 94 }, ··· 183 { 184 "source": "/:locale/docs/es6", 185 "destination": "/:locale/learn/getting-started/ecmascript-2015-es6-and-beyond" 186 + }, 187 + { 188 + "source": "/:locale/docs/guides/diagnostics-flamegraph", 189 + "destination": "/:locale/learn/diagnostics/flame-graphs" 190 + }, 191 + { 192 + "source": "/:locale/docs/guides/diagnostics", 193 + "destination": "/:locale/learn/diagnostics/user-journey" 194 + }, 195 + { 196 + "source": "/:locale/docs/guides/diagnostics/:path*", 197 + "destination": "/:locale/learn/diagnostics/:path*" 198 }, 199 { 200 "source": "/:locale/docs",