Show Nodejs heap stats only at Standalone WeKan.

Not shown at Sandstorm WeKan, because there's a bunch of machine performance data
Sandstorm doesn't expose to apps to prevent side channel attacks.

Thanks to ocdtrekkie and xet7 !

Fixes #4154
This commit is contained in:
Lauri Ojansivu 2021-11-17 00:26:40 +02:00
parent 6d719b8a98
commit 02b6df320f
2 changed files with 80 additions and 66 deletions

View file

@ -65,48 +65,49 @@ template(name='statistics')
tr
th {{_ 'OS_Cpus'}}
td {{statistics.os.cpus.length}}
tr
th {{_ 'Node_heap_total_heap_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalHeapSize}}
tr
th {{_ 'Node_heap_total_heap_size_executable'}}
td {{bytesToSize statistics.nodeHeapStats.totalHeapSizeExecutable}}
tr
th {{_ 'Node_heap_total_physical_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalPhysicalSize}}
tr
th {{_ 'Node_heap_total_available_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalAvailableSize}}
tr
th {{_ 'Node_heap_used_heap_size'}}
td {{bytesToSize statistics.nodeHeapStats.usedHeapSize}}
tr
th {{_ 'Node_heap_heap_size_limit'}}
td {{bytesToSize statistics.nodeHeapStats.heapSizeLimit}}
tr
th {{_ 'Node_heap_malloced_memory'}}
td {{bytesToSize statistics.nodeHeapStats.mallocedMemory}}
tr
th {{_ 'Node_heap_peak_malloced_memory'}}
td {{bytesToSize statistics.nodeHeapStats.peakMallocedMemory}}
tr
th {{_ 'Node_heap_does_zap_garbage'}}
td {{statistics.nodeHeapStats.doesZapGarbage}}
tr
th {{_ 'Node_heap_number_of_native_contexts'}}
td {{statistics.nodeHeapStats.numberOfNativeContexts}}
tr
th {{_ 'Node_heap_number_of_detached_contexts'}}
td {{statistics.nodeHeapStats.numberOfDetachedContexts}}
tr
th {{_ 'Node_memory_usage_rss'}}
td {{bytesToSize statistics.nodeMemoryUsage.rss}}
tr
th {{_ 'Node_memory_usage_heap_total'}}
td {{bytesToSize statistics.nodeMemoryUsage.heapTotal}}
tr
th {{_ 'Node_memory_usage_heap_used'}}
td {{bytesToSize statistics.nodeMemoryUsage.heapUsed}}
tr
th {{_ 'Node_memory_usage_external'}}
td {{bytesToSize statistics.nodeMemoryUsage.external}}
unless isSandstorm
tr
th {{_ 'Node_heap_total_heap_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalHeapSize}}
tr
th {{_ 'Node_heap_total_heap_size_executable'}}
td {{bytesToSize statistics.nodeHeapStats.totalHeapSizeExecutable}}
tr
th {{_ 'Node_heap_total_physical_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalPhysicalSize}}
tr
th {{_ 'Node_heap_total_available_size'}}
td {{bytesToSize statistics.nodeHeapStats.totalAvailableSize}}
tr
th {{_ 'Node_heap_used_heap_size'}}
td {{bytesToSize statistics.nodeHeapStats.usedHeapSize}}
tr
th {{_ 'Node_heap_heap_size_limit'}}
td {{bytesToSize statistics.nodeHeapStats.heapSizeLimit}}
tr
th {{_ 'Node_heap_malloced_memory'}}
td {{bytesToSize statistics.nodeHeapStats.mallocedMemory}}
tr
th {{_ 'Node_heap_peak_malloced_memory'}}
td {{bytesToSize statistics.nodeHeapStats.peakMallocedMemory}}
tr
th {{_ 'Node_heap_does_zap_garbage'}}
td {{statistics.nodeHeapStats.doesZapGarbage}}
tr
th {{_ 'Node_heap_number_of_native_contexts'}}
td {{statistics.nodeHeapStats.numberOfNativeContexts}}
tr
th {{_ 'Node_heap_number_of_detached_contexts'}}
td {{statistics.nodeHeapStats.numberOfDetachedContexts}}
tr
th {{_ 'Node_memory_usage_rss'}}
td {{bytesToSize statistics.nodeMemoryUsage.rss}}
tr
th {{_ 'Node_memory_usage_heap_total'}}
td {{bytesToSize statistics.nodeMemoryUsage.heapTotal}}
tr
th {{_ 'Node_memory_usage_heap_used'}}
td {{bytesToSize statistics.nodeMemoryUsage.heapUsed}}
tr
th {{_ 'Node_memory_usage_external'}}
td {{bytesToSize statistics.nodeMemoryUsage.external}}