Order of directive call during request handling

2014-06-15 Thread Adarsh Pugalia
I am not able to get the order in which the directive handlers are called when a request comes. I have a directive to connect to the database and the other to do put operation. In the conf file, i write the connect directive first, but when request comes, the connect directive handler is not called

Life of objects allocated using the request pool?

2014-06-10 Thread Adarsh Pugalia
What is the life of objects allocated using the request pool? If I allocate memory from the r->pool in a request handler, what would be the life of the object? Will the objects be freed if the request is over of will it sustain over multiple requests? ___

How do i free memory when my master process ends?

2014-06-02 Thread Adarsh Pugalia
I am allocating memory using malloc for some of my variables in my module. I know i can call an exit master process, but how do i access my variables in that function. I tried finding some examples, but didnt find any. Can anyone guide me through this. __

Server context Vs Location context

2014-05-30 Thread Adarsh Pugalia
Is there any way to check in a command's set function if the command was invoked i.e. the command was called from server context or location context. For example, if I write a command that can be used both in server context and location context, is there a way to differentiate from where it was cal

Passing arguments from the conf file to the module

2014-05-26 Thread Adarsh Pugalia
I have a command 'pass' that needs to pass two arguments to its handler. I know that in the conf file, i just need to write "pass arg1 arg2". But how do i access these arguments in the handler? Please guide me through this. Thanks. ___ nginx mailing list

Reuse of resources.

2014-05-21 Thread Adarsh Pugalia
Hi, I am just beginning with nginx and had a problem. Is there any way to reuse resources allocated, across different modules, or multiple invocations of the same module? For example, suppose I initialize a variable in module1, can I reuse that variable somehow in module2 or, may be reuse that var

Can I resuse persistent connection established in server configuration in different location configurations ?

2014-05-19 Thread Adarsh Pugalia
Hi, I am new to nginx. I would like to know if its possible to reuse persistent connections in different location modules. Suppose I establish a connection through and object through my server configuration module. Can i use this object in my different location modules? If yes, then how? Thanks. _