From e89f1cf7ae9f6e5ac7bc037bd9a1ac892d433cd0 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Fri, 14 Sep 2018 11:10:43 -0700 Subject: [PATCH 1/2] update metalsmith-markdown This eliminates a warning from `npm audit`. It's a semver major update, so we should look at output carefully, but all tests pass, so that's something... --- package-lock.json | 30 +++++++++++++++++++----------- package.json | 2 +- 2 files changed, 20 insertions(+), 12 deletions(-) diff --git a/package-lock.json b/package-lock.json index 20cc6980805dd..23f1425dadb6a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3907,23 +3907,31 @@ } }, "metalsmith-markdown": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/metalsmith-markdown/-/metalsmith-markdown-0.2.2.tgz", - "integrity": "sha512-2WMtfd2xhBagmoyRZXg04EHd/jmWnK21aGOvEZG5/eDEBTn9zGtkeptZrl+fQV+CNwhWtoggn1s9d+yi0+JLqQ==", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/metalsmith-markdown/-/metalsmith-markdown-1.0.1.tgz", + "integrity": "sha512-BsIvWg8F60ZH9kQ0n3heNexaOUpdxVPf4rJ8Ecsw4HT3rSpUt8xqK6dK3RsFP5bdgLiTDHvCF6IOqdte76H2XA==", "requires": { - "debug": "~0.7.4", - "marked": "~0.3.9" + "debug": "^4.0.1", + "marked": "~0.4.0" }, "dependencies": { "debug": { - "version": "0.7.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-0.7.4.tgz", - "integrity": "sha1-BuHqgILCyxTjmAbiLi9vdX+Srzk=" + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.0.1.tgz", + "integrity": "sha512-K23FHJ/Mt404FSlp6gSZCevIbTMLX0j3fmHhUEhQ3Wq0FMODW3+cUSoLdy1Gx4polAf4t/lphhmHH35BB8cLYw==", + "requires": { + "ms": "^2.1.1" + } }, "marked": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/marked/-/marked-0.3.19.tgz", - "integrity": "sha512-ea2eGWOqNxPcXv8dyERdSr/6FmzvWwzjMxpfGB/sbMccXoct+xY+YukPD+QTUZwyvK7BZwcr4m21WBOW41pAkg==" + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-0.4.0.tgz", + "integrity": "sha512-tMsdNBgOsrUophCAFQl0XPe6Zqk/uy9gnue+jIIKhykO51hxyu6uNx7zBPy0+y/WKYVZZMspV9YeXLNdKk+iYw==" + }, + "ms": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", + "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" } } }, diff --git a/package.json b/package.json index 6a6a7e9c9164b..ff42af4717739 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "metalsmith-discover-partials": "^0.1.2", "metalsmith-feed": "1.0.0", "metalsmith-layouts": "2.1.0", - "metalsmith-markdown": "0.2.2", + "metalsmith-markdown": "^1.0.1", "metalsmith-metadata": "0.0.4", "metalsmith-permalinks": "^1.0.0", "metalsmith-prism": "3.1.1", From 92e66aaf0bc830f5f7416f50b0a3cd1e626578f7 Mon Sep 17 00:00:00 2001 From: Frederic Hemberger Date: Sun, 16 Sep 2018 12:35:20 +0200 Subject: [PATCH 2/2] Fix rendering issues in #1810 --- locale/en/about/resources.md | 16 ++++---- locale/en/blog/npm/2013-outage-postmortem.md | 25 ++++++------ ...ng-node-js-dependencies-with-shrinkwrap.md | 10 +++-- locale/en/docs/guides/simple-profiling.md | 8 ++-- locale/ko/about/resources.md | 40 +++++++++---------- locale/ko/docs/guides/simple-profiling.md | 8 ++-- locale/uk/about/resources.md | 16 ++++---- locale/uk/docs/guides/simple-profiling.md | 8 ++-- locale/zh-cn/about/resources.md | 16 ++++---- .../docs/guides/debugging-getting-started.md | 2 +- locale/zh-cn/docs/guides/simple-profiling.md | 2 +- 11 files changed, 78 insertions(+), 73 deletions(-) diff --git a/locale/en/about/resources.md b/locale/en/about/resources.md index 93177b4c1a8c4..1686722289027 100644 --- a/locale/en/about/resources.md +++ b/locale/en/about/resources.md @@ -13,19 +13,19 @@ title: Logos and Graphics - - + + - - + + - - + + - - + +
[![Node.js on light background](/static/images/logos/nodejs-new-pantone-black.png)](/static/images/logos/nodejs-new-pantone-black.ai)[![Node.js on dark background](/static/images/logos/nodejs-new-pantone-white.png)](/static/images/logos/nodejs-new-pantone-white.ai)Node.js on light backgroundNode.js on dark background
[Node.js standard AI](/static/images/logos/nodejs-new-pantone-black.ai)[Node.js reversed AI](/static/images/logos/nodejs-new-pantone-white.ai)Node.js standard AINode.js reversed AI
[![Node.js on light background](/static/images/logos/nodejs-new-black.png)](/static/images/logos/nodejs-new-black.ai)[![Node.js on dark background](/static/images/logos/nodejs-new-white.png)](/static/images/logos/nodejs-new-white.ai)Node.js on light backgroundNode.js on dark background
[Node.js standard with less color AI](/static/images/logos/nodejs-new-black.ai)[Node.js reversed with less color AI](/static/images/logos/nodejs-new-white.ai)Node.js standard with less color AINode.js reversed with less color AI
diff --git a/locale/en/blog/npm/2013-outage-postmortem.md b/locale/en/blog/npm/2013-outage-postmortem.md index afe9dda9ea85c..01c2cb5238d4c 100644 --- a/locale/en/blog/npm/2013-outage-postmortem.md +++ b/locale/en/blog/npm/2013-outage-postmortem.md @@ -28,10 +28,10 @@ There are two distinct components that make up npmjs.org operated by different p Here is a high-level summary of the _old architecture:_ -old npm architecture -
- _Diagram 1. Old npm architecture_ -
+
+ old npm architecture +
Diagram 1. Old npm architecture
+
## What went wrong and how was it fixed? @@ -44,10 +44,10 @@ The incident on November 4th was ultimately resolved by a reboot and resize of t When neither of these yielded a solution Jason Smith and I decided to move to a multi-master architecture with continuous replication illustrated below: -current npm architecture -
- _Diagram 2. Current npm architecture -- Red-lines denote continuous replication_ -
+
+ current npm architecture +
Diagram 2. Current npm architecture -- Red-lines denote continuous replication
+
This _should_ have been the end of our story but unfortunately our supervision logic did not function properly to restart the secondary master on the morning of November 15th. During this time we [moved briefly][ops-single-server] back to a single master architecture. Since then the secondary master has been closely monitored by the entire Nodejitsu operations team to ensure it's continued stability. @@ -62,10 +62,11 @@ The public npm registry simply cannot go down. **Ever.** We gained a lot of oper When these new infrastructure components are in-place The npm Registry will look like this: -planned npm architecture -
- _Diagram 3. Planned npm architecture -- Red-lines denote continuous replication_ -
+
+ planned npm architecture +
+ Diagram 3. Planned npm architecture -- Red-lines denote continuous replication
+
## You are npm! And we need your help! diff --git a/locale/en/blog/npm/managing-node-js-dependencies-with-shrinkwrap.md b/locale/en/blog/npm/managing-node-js-dependencies-with-shrinkwrap.md index 939c48bf3ab40..7244576e14c7c 100644 --- a/locale/en/blog/npm/managing-node-js-dependencies-with-shrinkwrap.md +++ b/locale/en/blog/npm/managing-node-js-dependencies-with-shrinkwrap.md @@ -27,16 +27,20 @@ Photo by Luc Viatour (flickr)

That brings us to npm shrinkwrap[1]:

-
NAME
+
+```
+NAME
        npm-shrinkwrap -- Lock down dependency versions
 
 SYNOPSIS
        npm shrinkwrap
 
 DESCRIPTION
-       This  command  locks down the versions of a package's dependencies so
+       This  command  locks down the versions of a package's dependencies so
        that you can control exactly which versions of each  dependency  will
-       be used when your package is installed.
+ be used when your package is installed. +``` +

Let's consider package A:

diff --git a/locale/en/docs/guides/simple-profiling.md b/locale/en/docs/guides/simple-profiling.md index 5bf106b2204ce..d343242a5a757 100644 --- a/locale/en/docs/guides/simple-profiling.md +++ b/locale/en/docs/guides/simple-profiling.md @@ -196,15 +196,15 @@ Parsing this section takes a little more work than the raw tick counts above. Within each of the "call stacks" above, the percentage in the parent column tells you the percentage of samples for which the function in the row above was called by the function in the current row. For example, in the middle "call -stack" above for _sha1_block_data_order, we see that _sha1_block_data_order occurred +stack" above for _sha1_block_data_order, we see that `_sha1_block_data_order` occurred in 11.9% of samples, which we knew from the raw counts above. However, here, we can also tell that it was always called by the pbkdf2 function inside the -Node.js crypto module. We see that similarly, _malloc_zone_malloc was called +Node.js crypto module. We see that similarly, `_malloc_zone_malloc` was called almost exclusively by the same pbkdf2 function. Thus, using the information in this view, we can tell that our hash computation from the user's password accounts not only for the 51.8% from above but also for all CPU time in the top -3 most sampled functions since the calls to _sha1_block_data_order and -_malloc_zone_malloc were made on behalf of the pbkdf2 function. +3 most sampled functions since the calls to `_sha1_block_data_order` and +`_malloc_zone_malloc` were made on behalf of the pbkdf2 function. At this point, it is very clear that the password based hash generation should be the target of our optimization. Thankfully, you've fully internalized the diff --git a/locale/ko/about/resources.md b/locale/ko/about/resources.md index cd3f1b600896c..8a14cc5e5a798 100644 --- a/locale/ko/about/resources.md +++ b/locale/ko/about/resources.md @@ -8,58 +8,58 @@ title: 로고와 그래픽 ## Logo Downloads - Please review the [trademark policy](/about/trademark/) for information about permissible use of Node.js® logos and marks. + Please review the trademark policy> for information about permissible use of Node.js® logos and marks. Guidelines for the visual display of the Node.js mark are described in - the [Visual Guidelines](/static/documents/foundation-visual-guidelines.pdf). + the Visual Guidelines>. --> # 관련 자료 ## 로고 다운로드 -Node.js® 로고와 마크를 사용할 수 있는 경우에 대한 정보는 [상표 정책](/about/trademark/)을 +Node.js® 로고와 마크를 사용할 수 있는 경우에 대한 정보는 상표 정책>을 확인해보기 바랍니다. Node.js의 시각적인 가이드라인은 -[시각적 가이드라인](/static/documents/foundation-visual-guidelines.pdf)에 나와 있습니다. +시각적 가이드라인>에 나와 있습니다. - - + + - - + + - - + + - - + +
[![밝은 배경의 Node.js](/static/images/logos/nodejs-new-pantone-black.png)](/static/images/logos/nodejs-new-pantone-black.ai)[![어두운 배경의 Node.js](/static/images/logos/nodejs-new-pantone-white.png)](/static/images/logos/nodejs-new-pantone-white.ai)밝은 배경의 Node.js어두운 배경의 Node.js
[Node.js 표준 AI](/static/images/logos/nodejs-new-pantone-black.ai)[Node.js 반전 AI](/static/images/logos/nodejs-new-pantone-white.ai)Node.js 표준 AINode.js 반전 AI
[![밝은 배경의 Node.js](/static/images/logos/nodejs-new-black.png)](/static/images/logos/nodejs-new-black.ai)[![어두운 배경의 Node.js](/static/images/logos/nodejs-new-white.png)](/static/images/logos/nodejs-new-white.ai)밝은 배경의 Node.js어두운 배경의 Node.js
[적은 색상을 가진 Node.js 표준 AI](/static/images/logos/nodejs-new-black.ai)[적은 색상을 가진 Node.js 반전 AI](/static/images/logos/nodejs-new-white.ai)적은 색상을 가진 Node.js 표준 AI적은 색상을 가진 Node.js 반전 AI
diff --git a/locale/ko/docs/guides/simple-profiling.md b/locale/ko/docs/guides/simple-profiling.md index d432c321026ef..ea3afbd35cc7c 100644 --- a/locale/ko/docs/guides/simple-profiling.md +++ b/locale/ko/docs/guides/simple-profiling.md @@ -391,15 +391,15 @@ Parsing this section takes a little more work than the raw tick counts above. Within each of the "call stacks" above, the percentage in the parent column tells you the percentage of samples for which the function in the row above was called by the function in the current row. For example, in the middle "call -stack" above for _sha1_block_data_order, we see that _sha1_block_data_order occurred +stack" above for _sha1_block_data_order, we see that `_sha1_block_data_order` occurred in 11.9% of samples, which we knew from the raw counts above. However, here, we can also tell that it was always called by the pbkdf2 function inside the -Node.js crypto module. We see that similarly, _malloc_zone_malloc was called +Node.js crypto module. We see that similarly, `_malloc_zone_malloc` was called almost exclusively by the same pbkdf2 function. Thus, using the information in this view, we can tell that our hash computation from the user's password accounts not only for the 51.8% from above but also for all CPU time in the top -3 most sampled functions since the calls to _sha1_block_data_order and -_malloc_zone_malloc were made on behalf of the pbkdf2 function. +3 most sampled functions since the calls to `_sha1_block_data_order` and +`_malloc_zone_malloc` were made on behalf of the pbkdf2 function. At this point, it is very clear that the password based hash generation should be the target of our optimization. Thankfully, you've fully internalized the diff --git a/locale/uk/about/resources.md b/locale/uk/about/resources.md index d3b72fdd9e825..f4157ab4d1157 100644 --- a/locale/uk/about/resources.md +++ b/locale/uk/about/resources.md @@ -13,19 +13,19 @@ title: Лого та графіка - - + + - - + + - - + + - - + +
[![Node.js на світлому фоні](/static/images/logos/nodejs-new-pantone-black.png)](/static/images/logos/nodejs-new-pantone-black.ai)[![Node.js на темному фоні](/static/images/logos/nodejs-new-pantone-white.png)](/static/images/logos/nodejs-new-pantone-white.ai)Node.js на світлому фоніNode.js на темному фоні
[Node.js звичайний AI](/static/images/logos/nodejs-new-pantone-black.ai)[Node.js інвертований AI](/static/images/logos/nodejs-new-pantone-white.ai)Node.js звичайний AINode.js інвертований AI
[![Node.js на світлому фоні](/static/images/logos/nodejs-new-black.png)](/static/images/logos/nodejs-new-black.ai)[![Node.js на темному фоні](/static/images/logos/nodejs-new-white.png)](/static/images/logos/nodejs-new-white.ai)Node.js на світлому фоніNode.js на темному фоні
[Node.js звичайний з меншою кількістю кольорів AI](/static/images/logos/nodejs-new-black.ai)[Node.js інвертований з меншою кількістю кольорів AI](/static/images/logos/nodejs-new-white.ai)Node.js звичайний з меншою кількістю кольорів AINode.js інвертований з меншою кількістю кольорів AI
diff --git a/locale/uk/docs/guides/simple-profiling.md b/locale/uk/docs/guides/simple-profiling.md index 5bf106b2204ce..d343242a5a757 100644 --- a/locale/uk/docs/guides/simple-profiling.md +++ b/locale/uk/docs/guides/simple-profiling.md @@ -196,15 +196,15 @@ Parsing this section takes a little more work than the raw tick counts above. Within each of the "call stacks" above, the percentage in the parent column tells you the percentage of samples for which the function in the row above was called by the function in the current row. For example, in the middle "call -stack" above for _sha1_block_data_order, we see that _sha1_block_data_order occurred +stack" above for _sha1_block_data_order, we see that `_sha1_block_data_order` occurred in 11.9% of samples, which we knew from the raw counts above. However, here, we can also tell that it was always called by the pbkdf2 function inside the -Node.js crypto module. We see that similarly, _malloc_zone_malloc was called +Node.js crypto module. We see that similarly, `_malloc_zone_malloc` was called almost exclusively by the same pbkdf2 function. Thus, using the information in this view, we can tell that our hash computation from the user's password accounts not only for the 51.8% from above but also for all CPU time in the top -3 most sampled functions since the calls to _sha1_block_data_order and -_malloc_zone_malloc were made on behalf of the pbkdf2 function. +3 most sampled functions since the calls to `_sha1_block_data_order` and +`_malloc_zone_malloc` were made on behalf of the pbkdf2 function. At this point, it is very clear that the password based hash generation should be the target of our optimization. Thankfully, you've fully internalized the diff --git a/locale/zh-cn/about/resources.md b/locale/zh-cn/about/resources.md index 6dcffb4d3ecef..4c2b473d4d49b 100644 --- a/locale/zh-cn/about/resources.md +++ b/locale/zh-cn/about/resources.md @@ -12,19 +12,19 @@ title: 商标和图像 - - + + - - + + - - + + - - + +
[![Node.js 浅色背景](/static/images/logos/nodejs-new-pantone-black.png)](/static/images/logos/nodejs-new-pantone-black.ai)[![Node.js 深色背景](/static/images/logos/nodejs-new-pantone-white.png)](/static/images/logos/nodejs-new-pantone-white.ai)Node.js 浅色背景Node.js 深色背景
[Node.js 标准 AI](/static/images/logos/nodejs-new-pantone-black.ai)[Node.js 保留 AI](/static/images/logos/nodejs-new-pantone-white.ai)Node.js 标准 AINode.js 保留 AI
[![Node.js 浅色背景 ](/static/images/logos/nodejs-new-black.png)](/static/images/logos/nodejs-new-black.ai)[![Node.js 深色背景 ](/static/images/logos/nodejs-new-white.png)](/static/images/logos/nodejs-new-white.ai)Node.js 浅色背景 Node.js 深色背景
[少彩色的标准 Node.js AI](/static/images/logos/nodejs-new-black.ai)[少彩色的保留 Node.js AI](/static/images/logos/nodejs-new-white.ai)少彩色的标准 Node.js AI少彩色的保留 Node.js AI
diff --git a/locale/zh-cn/docs/guides/debugging-getting-started.md b/locale/zh-cn/docs/guides/debugging-getting-started.md index 80a87cbeb8b08..03eb1446af92b 100644 --- a/locale/zh-cn/docs/guides/debugging-getting-started.md +++ b/locale/zh-cn/docs/guides/debugging-getting-started.md @@ -178,7 +178,7 @@ ssh 管道启动,在你机器上连接到 9221 端口将被重定向到 9229 ## 遗留的调试器 -** 遗留的调试器自 Node 7.7.0 已被启用。请使用 --inspect 代替。** +**遗留的调试器自 Node 7.7.0 已被启用。请使用 --inspect 代替。** 在版本 7 以及更早的版本使用 **--debug** 或 **--debug-brk** 开关启动调试时,Node.js 侦听由中断定义的调试命令,TCP 端口上的 V8 调试协议,默认为 `5858`。任何遵守此协议的调试客户端都可以连接并调试运行这个进程,下面有一些热门的说明。 diff --git a/locale/zh-cn/docs/guides/simple-profiling.md b/locale/zh-cn/docs/guides/simple-profiling.md index 822050efdcd4a..cf85151be956b 100644 --- a/locale/zh-cn/docs/guides/simple-profiling.md +++ b/locale/zh-cn/docs/guides/simple-profiling.md @@ -156,7 +156,7 @@ node --prof-process isolate-0xnnnnnnnnnnnn-v8.log > processed.txt ``` 分析此节需要的工作量比上面的原始刻度计数多一点。 -在上面的每个“调用栈”中,父列中的百分比将告诉您在当前行中函数调用了上面行中的函数所占的样本百分比。例如,在中间“呼叫堆栈”以上为 _sha1_block_data_order,我们看到 _sha1_block_data_order 发生在 11.9% 样品,我们知道从上面的原始计数。然而,在这里我们也可以说,它总是由 Node.js 内部的 pbkdf2 函数调用加密模块。我们看到,同样 _malloc_zone_malloc 被称为几乎完全相同的 pbkdf2 功能。因此,使用中的信息这种观点,我们可以说,我们从用户的密码帐户计算的哈希不仅为上面所述的 51.8%,但也是前 3 的 CPU 时间采样函数,因为调用 _sha1_block_data_order 和_malloc_zone_malloc 是代表 pbkdf2 的功能而制作的。 +在上面的每个“调用栈”中,父列中的百分比将告诉您在当前行中函数调用了上面行中的函数所占的样本百分比。例如,在中间“呼叫堆栈”以上为 _sha1_block_data_order,我们看到 `_sha1_block_data_order` 发生在 11.9% 样品,我们知道从上面的原始计数。然而,在这里我们也可以说,它总是由 Node.js 内部的 pbkdf2 函数调用加密模块。我们看到,同样 `_malloc_zone_malloc` 被称为几乎完全相同的 pbkdf2 功能。因此,使用中的信息这种观点,我们可以说,我们从用户的密码帐户计算的哈希不仅为上面所述的 51.8%,但也是前 3 的 CPU 时间采样函数,因为调用 `_sha1_block_data_order` 和`_malloc_zone_malloc` 是代表 pbkdf2 的功能而制作的。 在这一点上,很明显,,基于密码的哈希生成应该是我们优化的目标。谢天谢地,您已经完全了解了 [异步编程的好处][],并且您认识到从用户密码生成哈希的工作正在以同步方式进行,从而绑定了事件循环。这将阻止我们在计算哈希时处理其它传入请求。