Your issue may already be reported!
Please search on the issue tracker before creating one.
I'm using https://github.com/politinn/pm2-prometheus-exporter to get basic stats about my running apps, however the unstable_restarts value is returning incorrectly. It seems this pulls from pm2_env.unstable_restarts on each response from running the list command
const pm2 = require('pm2');
pm2.list([], (err, resp) => {
list.forEach(p => {
console.log(p.pm2_env.unstable_restarts);
})
});
Please run the following command (available on PM2 >= 2.6)
$ pm2 report
unstable_restarts is used as internal variable that doesn't count how much restart has been made, the one you are looking for is restart_time
Most helpful comment
unstable_restartsis used as internal variable that doesn't count how much restart has been made, the one you are looking for isrestart_time