diff options
author | Maxim Dounin <mdounin@mdounin.ru> | 2014-09-11 20:08:52 +0400 |
---|---|---|
committer | Maxim Dounin <mdounin@mdounin.ru> | 2014-09-11 20:08:52 +0400 |
commit | 3a235bf52e6cfb02e42c76f1ff66a93fcfff54e7 (patch) | |
tree | 55ffbbe8d312c9279ba1341fd709c8d8bf900eb3 /src/http/modules/ngx_http_uwsgi_module.c | |
parent | d7d26feba1f637dc8778acdbc41c39a820301681 (diff) | |
download | nginx-3a235bf52e6cfb02e42c76f1ff66a93fcfff54e7.tar.gz nginx-3a235bf52e6cfb02e42c76f1ff66a93fcfff54e7.zip |
Added warning about unset cache keys.
In fastcgi, scgi and uwsgi modules there are no default cache keys, and
using a cache without a cache key set is likely meaningless.
Diffstat (limited to 'src/http/modules/ngx_http_uwsgi_module.c')
-rw-r--r-- | src/http/modules/ngx_http_uwsgi_module.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/http/modules/ngx_http_uwsgi_module.c b/src/http/modules/ngx_http_uwsgi_module.c index 3956036a9..0185cbac7 100644 --- a/src/http/modules/ngx_http_uwsgi_module.c +++ b/src/http/modules/ngx_http_uwsgi_module.c @@ -1524,6 +1524,11 @@ ngx_http_uwsgi_merge_loc_conf(ngx_conf_t *cf, void *parent, void *child) conf->cache_key = prev->cache_key; } + if (conf->upstream.cache && conf->cache_key.value.data == NULL) { + ngx_conf_log_error(NGX_LOG_WARN, cf, 0, + "no \"uwsgi_cache_key\" for \"uwsgi_cache\""); + } + ngx_conf_merge_value(conf->upstream.cache_lock, prev->upstream.cache_lock, 0); |