You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by cs...@apache.org on 2017/11/17 12:02:56 UTC

[incubator-openwhisk-package-alarms] branch master updated: Add v8 heap statistics to Health endpoint (#106)

This is an automated email from the ASF dual-hosted git repository.

csantanapr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-package-alarms.git


The following commit(s) were added to refs/heads/master by this push:
     new d492983  Add v8 heap statistics to Health endpoint (#106)
d492983 is described below

commit d4929835883ae04e9ce4ab0b9b2c4fcead71f7b2
Author: Jason Peterson <ja...@us.ibm.com>
AuthorDate: Fri Nov 17 07:02:55 2017 -0500

    Add v8 heap statistics to Health endpoint (#106)
---
 provider/lib/health.js | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/provider/lib/health.js b/provider/lib/health.js
index ecfba29..bbdc01d 100644
--- a/provider/lib/health.js
+++ b/provider/lib/health.js
@@ -1,4 +1,5 @@
 var si = require('systeminformation');
+var v8 = require('v8');
 
 module.exports = function(utils) {
 
@@ -24,6 +25,8 @@ module.exports = function(utils) {
             stats.disk = results[2];
             stats.network = results[3];
             stats.apiHostLatency = results[4];
+            stats.heapStatistics = v8.getHeapStatistics();
+            stats.heapSpaceStatistics =v8.getHeapSpaceStatistics();
             res.send(stats);
         })
         .catch(error => {

-- 
To stop receiving notification emails like this one, please contact
['"commits@openwhisk.apache.org" <co...@openwhisk.apache.org>'].