Skip to content

Instantly share code, notes, and snippets.

@smly
Last active December 21, 2015 15:29
Show Gist options
  • Select an option

  • Save smly/6327248 to your computer and use it in GitHub Desktop.

Select an option

Save smly/6327248 to your computer and use it in GitHub Desktop.
In OpenRTB, "No-Bids" on all impressions are indicated as HTTP 204 response. It would be useful to handle 204 in limit_req_status/limit_conn_status directives. (ref: http://www.iab.net/media/file/OpenRTB-API-Specification-Version-2-1-FINAL.pdf)
diff --git a/src/http/modules/ngx_http_limit_conn_module.c b/src/http/modules/ngx_http_limit_conn_module.c
index 7f0eea7..0d29f6b 100644
--- a/src/http/modules/ngx_http_limit_conn_module.c
+++ b/src/http/modules/ngx_http_limit_conn_module.c
@@ -76,7 +76,7 @@ static ngx_conf_enum_t ngx_http_limit_conn_log_levels[] = {
static ngx_conf_num_bounds_t ngx_http_limit_conn_status_bounds = {
- ngx_conf_check_num_bounds, 400, 599
+ ngx_conf_check_num_bounds, 201, 599
};
diff --git a/src/http/modules/ngx_http_limit_req_module.c b/src/http/modules/ngx_http_limit_req_module.c
index 90434c9..f1899ef 100644
--- a/src/http/modules/ngx_http_limit_req_module.c
+++ b/src/http/modules/ngx_http_limit_req_module.c
@@ -86,7 +86,7 @@ static ngx_conf_enum_t ngx_http_limit_req_log_levels[] = {
static ngx_conf_num_bounds_t ngx_http_limit_req_status_bounds = {
- ngx_conf_check_num_bounds, 400, 599
+ ngx_conf_check_num_bounds, 201, 599
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment