Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cubicdaiya/ngx_bumpylife
ngx_bumpylife sets the randomized limit of requests to be processed for each worker process.
https://github.com/cubicdaiya/ngx_bumpylife
nginx
Last synced: 28 days ago
JSON representation
ngx_bumpylife sets the randomized limit of requests to be processed for each worker process.
- Host: GitHub
- URL: https://github.com/cubicdaiya/ngx_bumpylife
- Owner: cubicdaiya
- License: mit
- Created: 2015-11-07T20:02:50.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2015-12-31T12:13:48.000Z (about 9 years ago)
- Last Synced: 2024-10-27T11:11:21.911Z (3 months ago)
- Topics: nginx
- Language: C
- Size: 6.84 KB
- Stars: 5
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ngx_bumpylife
`ngx_bumpylife` sets the randomized limit of requests to be processed for each worker process.
It is inspired by [`ap-mod_bumpy_life`](https://github.com/hirose31/ap-mod_bumpy_life).# Status
Early development phase
# Directives
## bumpylife
|Syntax |bumpylife on | off |
|-------|--------------------|
|Default|off |
|Context|http |Enables or disables `ngx_bumpylife`.
## bumpylife_min
|Syntax |bumpylife number |
|-------|-----------------|
|Default|0 |
|Context|http |Sets the minimun value for the limit of requests to be processed.
## bumpylife_max
|Syntax |bumpylife number |
|-------|-----------------|
|Default|0 |
|Context|http |Sets the max value for the limit of requests to be processed.
# Behavior
If `ngx_bumpylife` is enabled, each worker process increments own counter and
sets `ngx_http_bumpylife_target_pid` in shared memory own pid when the number of requests to be processed overs the limit.
Moreover, checks the variable `ngx_http_bumpylife_target_pid` in shared memory and
sends `SIGQUIT` the process which pid is `ngx_http_bumpylife_target_pid`.
The limit of requests to be processed is randomized in the `bumpylife_min` to `bumpylife_max` range.And `ngx_bumpylife` does not work in the cases below.
* `bumpylife_min` or `bumpylife_max` is zero.
* `bumpylife_min` is higher than `bumpylife_max`.# Quick Start
```nginx
http {
bumpylife on;
bumpylife_min 500;
bumpylife_max 800;
...
}
```# License
See [LICENSE](https://github.com/cubicdaiya/ngx_bumpylife/blob/master/LICENSE).