From eebdcddd2d74621dc8c4660f7e3c9c9e25830bd4 Mon Sep 17 00:00:00 2001 From: Yuan-Ming Hsu <48866415+technic960183@users.noreply.github.com> Date: Fri, 29 Nov 2024 14:26:44 +0800 Subject: [PATCH] report: fix typos in report keys and bump the version Replace "kbytes" with "bytes" in `PrintSystemInformation()` in `src/node_report.cc`, as RLIMIT_DATA, RLIMIT_RSS, and RLIMIT_AS are given in bytes. The report version is bumped from 4 to 5. Refs: https://www.ibm.com/docs/en/aix/7.3?topic=k-kgetrlimit64-kernel-service --- doc/api/report.md | 43 +++++++++++++++++++++++++++++++++++++++---- src/node_report.cc | 8 ++++---- test/common/report.js | 8 ++++---- 3 files changed, 47 insertions(+), 12 deletions(-) diff --git a/doc/api/report.md b/doc/api/report.md index c74dc7e4c0880b..4895dde2b52077 100644 --- a/doc/api/report.md +++ b/doc/api/report.md @@ -35,7 +35,7 @@ is provided below for reference. ```json { "header": { - "reportVersion": 4, + "reportVersion": 5, "event": "exception", "trigger": "Exception", "filename": "report.20181221.005011.8974.0.001.json", @@ -392,7 +392,7 @@ is provided below for reference. "soft": "", "hard": "unlimited" }, - "data_seg_size_kbytes": { + "data_seg_size_bytes": { "soft": "unlimited", "hard": "unlimited" }, @@ -404,7 +404,7 @@ is provided below for reference. "soft": "unlimited", "hard": 65536 }, - "max_memory_size_kbytes": { + "max_memory_size_bytes": { "soft": "unlimited", "hard": "unlimited" }, @@ -424,7 +424,7 @@ is provided below for reference. "soft": "unlimited", "hard": 4127290 }, - "virtual_memory_kbytes": { + "virtual_memory_bytes": { "soft": "unlimited", "hard": "unlimited" } @@ -588,6 +588,41 @@ Report version definitions are consistent across LTS releases. ### Version history +#### Version 5 + + + +Replace the keys `data_seg_size_kbytes`, `max_memory_size_kbytes`, and `virtual_memory_kbytes` +with `data_seg_size_bytes`, `max_memory_size_bytes`, and `virtual_memory_bytes` +respectively in the `userLimits` section, as these values are given in bytes. + +```json +{ + "userLimits": { + // Skip some keys ... + "data_seg_size_bytes": { // replacing data_seg_size_kbytes + "soft": "unlimited", + "hard": "unlimited" + }, + // ... + "max_memory_size_bytes": { // replacing max_memory_size_kbytes + "soft": "unlimited", + "hard": "unlimited" + }, + // ... + "virtual_memory_bytes": { // replacing virtual_memory_kbytes + "soft": "unlimited", + "hard": "unlimited" + } + } +} +``` + #### Version 4