Welcome! Log In Create A New Profile

Advanced

Re: Inconsistent variable caching (in SSI or in nginScript)

Anton Yuzhaninov
October 10, 2017 10:24AM
On 10/09/17 22:15, Anton Yuzhaninov wrote:
>
> I've encountered a bug (or unexpected and not well documented feature)
> in SSI (ngx_http_ssi_module) or in nginScript (ngx_http_js_module).
>
> If a variable, which set via js_set is used only in SSI it is not cached
> and nginScript function called several times for one HTTP request.

This problem is not related to nginScript.

More simple test case:

log_format unused '$request_id'; # when this line is commented
variable is not cached

server {
listen 8082;

location / {
ssi on;
ssi_types text/plain;
default_type text/plain;
return 200 '<!--# echo var="request_id" -->\n<!--# echo
var="request_id" -->\n';
}
}

If $request_id is used only in SSI two different $request_id values are
shown. If $request_id used anywhere in the config file - variable value
is cached and two same values are show.
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Inconsistent variable caching (in SSI or in nginScript)

Anton Yuzhaninov October 09, 2017 10:18PM

Re: Inconsistent variable caching (in SSI or in nginScript)

Anton Yuzhaninov October 10, 2017 10:24AM

Re: Inconsistent variable caching (in SSI or in nginScript)

Maxim Dounin October 10, 2017 10:42AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 192
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready