kubernetes-probes
Advanced tools
Comparing version 0.1.2 to 0.1.3
{ | ||
"name": "kubernetes-probes", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"description": "Listener for health probes from kubernetes.", | ||
@@ -5,0 +5,0 @@ "private": false, |
@@ -6,10 +6,11 @@ # kubernetes-probes | ||
You define one or more functions for each aspect of readiness or liveness. | ||
When probed (readiness or liveness), kubernetes-probes calls the appropriate one or more defined functions. | ||
When probed (readiness or liveness), _kubernetes-probes_ calls the appropriate one or more defined functions. | ||
Use of this library infers your app is implementing both (all) probes. | ||
If kubernetes-probes gets a probe and there are no functions defined for that type of probe, the response will be negative, i.e., a status code of 200. | ||
If _kubernetes-probes_ gets a probe and there are no functions defined for that type of probe, | ||
the response will be negative, i.e., a status code of 400. | ||
This will indicate to kubernetes that the app is not ready/lively. | ||
## Usage | ||
In this examplet here is one liveness function and two readiness functions. | ||
In this example here is one liveness function and two readiness functions. | ||
@@ -46,6 +47,6 @@ ```javascript | ||
* `alive` - [REQUIRED] - function(cb). | ||
Called by kubernetes-probes when kubernetes requests a liveness probe. | ||
If this function is not defined, kubernetes-probes response will be "liveness function undefined." with status 400. | ||
Called by _kubernetes-probes_ when kubernetes requests a liveness probe. | ||
If this function is not defined, _kubernetes-probes_ response will be "liveness function undefined." with status 400. | ||
* `cb` - [REQUIRED] - function(isAlive, message). | ||
Called to return liveness state to kubernetes-probes. | ||
Called to return liveness state to _kubernetes-probes_. | ||
* `isAlive` - [REQUIRED] - boolean. | ||
@@ -62,6 +63,6 @@ TRUE indicates alive, response status is 200. | ||
* `ready` - [REQUIRED] - function(cb). | ||
Called by kubernetes-probes when kubernetes requests a readiness probe. | ||
If this function is not defined, kubernetes-probes response will be "readiness function undefined." with status 400. | ||
Called by _kubernetes-probes_ when kubernetes requests a readiness probe. | ||
If this function is not defined, _kubernetes-probes_ response will be "readiness function undefined." with status 400. | ||
* `cb` - [REQUIRED] - function(isReady, message). | ||
Called to return liveness state to kubernetes-probes. | ||
Called to return liveness state to _kubernetes-probes_. | ||
* `isReady` - [REQUIRED] - boolean. | ||
@@ -78,4 +79,4 @@ TRUE indicates ready, response status is 200. | ||
* `port` - [REQUIRED] - integer. | ||
kubernetes-probes will start listening on this port. | ||
_kubernetes-probes_ will start listening on this port. | ||
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 3 instances in 1 package
79
1
28541
10