pm2-perfmonitor 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -14
- package/package.json +8 -4
package/README.md
CHANGED
|
@@ -1,28 +1,31 @@
|
|
|
1
1
|
# pm2-perfmonitor
|
|
2
2
|
|
|
3
|
-
A pm2 module for performance monitor
|
|
3
|
+
A pm2 module for performance monitor.
|
|
4
4
|
|
|
5
5
|
# Features
|
|
6
6
|
|
|
7
|
-
- Automatically detect zombie processes and restart it.
|
|
7
|
+
- Automatically detect **zombie** processes and restart it.
|
|
8
|
+
- Monitor the number of zombie process restarts (pm2 monit).
|
|
8
9
|
|
|
9
|
-
#
|
|
10
|
+
# Installation
|
|
10
11
|
|
|
11
12
|
```bash
|
|
12
13
|
$ pm2 install pm2-perfmonitor
|
|
13
14
|
```
|
|
14
15
|
|
|
16
|
+
> NOTE: the command is `pm2 install` NOT `npm install`
|
|
17
|
+
|
|
15
18
|
# Configure
|
|
16
19
|
|
|
17
|
-
| Property | Default Value |
|
|
18
|
-
| :-----------------------------: | :-----------: |
|
|
19
|
-
| `enabled` | `true` |
|
|
20
|
-
| `excludeApps` | - |
|
|
21
|
-
| `includeApps` | - |
|
|
22
|
-
| `workerInterval` | `60000` |
|
|
23
|
-
| `zombieDetection` | `true` |
|
|
24
|
-
| `zombieMaxHits` | `10` |
|
|
25
|
-
| `autoRestartWhenZombieDetected` | `true` |
|
|
20
|
+
| Property | Default Value | Description |
|
|
21
|
+
| :-----------------------------: | :-----------: | :----------------------------------------------------------------------: |
|
|
22
|
+
| `enabled` | `true` | Specify whether to enable this module |
|
|
23
|
+
| `excludeApps` | - | Specify the application name that needs to be excluded from guardianship |
|
|
24
|
+
| `includeApps` | - | Specify the application name that needs to be guarded |
|
|
25
|
+
| `workerInterval` | `60000` | Timed task execution interval (ms) |
|
|
26
|
+
| `zombieDetection` | `true` | Specify whether to enable zombie process protection |
|
|
27
|
+
| `zombieMaxHits` | `10` | Specify the maximum occurrence frequency of zombie status |
|
|
28
|
+
| `autoRestartWhenZombieDetected` | `true` | Specify whether to automatically restart zombie processes |
|
|
26
29
|
|
|
27
30
|
# How to set these values ?
|
|
28
31
|
|
|
@@ -30,5 +33,5 @@ After having installed the module you have to type : `pm2 set pm2-perfmonitor:<p
|
|
|
30
33
|
|
|
31
34
|
**e.g:**
|
|
32
35
|
|
|
33
|
-
- `pm2 set pm2-perfmonitor:includeApps myNuxtApp1, myNextApp2`
|
|
34
|
-
- `pm2 set pm2-perfmonitor:workerInterval 120000` (2
|
|
36
|
+
- `pm2 set pm2-perfmonitor:includeApps myNuxtApp1, myNextApp2` (Only detect applications named `myNuxtApp1` and `myNextApp2`)
|
|
37
|
+
- `pm2 set pm2-perfmonitor:workerInterval 120000` (Check every `2` minutes)
|
package/package.json
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pm2-perfmonitor",
|
|
3
|
-
"version": "1.1.
|
|
4
|
-
"description": "A pm2 module for performance monitoring",
|
|
5
|
-
"author":
|
|
3
|
+
"version": "1.1.2",
|
|
4
|
+
"description": "A pm2 module for performance monitoring. Automatically detect zombie processes and restart it",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "elenh",
|
|
7
|
+
"email": "yisiwings@163.com"
|
|
8
|
+
},
|
|
6
9
|
"license": "MIT",
|
|
7
10
|
"main": "lib/app.js",
|
|
8
11
|
"files": [
|
|
@@ -23,7 +26,8 @@
|
|
|
23
26
|
},
|
|
24
27
|
"keywords": [
|
|
25
28
|
"pm2",
|
|
26
|
-
"monitor"
|
|
29
|
+
"monitor",
|
|
30
|
+
"zombie process"
|
|
27
31
|
],
|
|
28
32
|
"apps": [
|
|
29
33
|
{
|