Welcome! Log In Create A New Profile

Advanced

Improving Config Validation Testing

June 29, 2010 10:48AM
Hey Folks,

I am wondering if there is anything in the pipeline that may ease config
validation testing. The use-case I am currently working on is testing the
validity of config for a certain module. If for a particular location a
module is active, than a certain other directives should be present, and if
they are present it should be possible to test for some other predicates at
runtime (for example files on the file-system, where filenames are specified
as directives for the module).

Nginx's out-of-the-box configuration is quite elegant, and it is hard to
write incorrect config files. And most common settings have default values.
However in my case I require more validation.

I have hacked together some code to test weather all requisite directives
have been set (in contrast to checking them one by one, and returning a
single error at a time). If one or more aren't, the code builds and returns
a formatted list of missing directives.

I'm just wondering if there is room for modelling such dependencies directly
in the "ngx_comman_t array" provided when creating a module, and perhaps for
a general purpose delegate mechanism that would allow other predicates to be
evaluated at runtime.

Regards

Hassan
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Improving Config Validation Testing

hassan.syed 3287 June 29, 2010 10:48AM

Re: Improving Config Validation Testing

Maxim Dounin 1091 June 29, 2010 11:38AM

RE: Improving Config Validation Testing

hassan.syed 1619 June 30, 2010 12:18PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 198
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